petsc

maintainer MartinDiehl · 20 votes · scanned 2026-08-03 00:08:14.047287
LOW
View on AUR ↗
Why flagged The source is a tarball from the official project's own domain (anl.gov), which hosts the legitimate PETSc releases; building from this source is standard practice and not inherently risky despite the non-whitelisted host.

Triggered rules

LOW AI review downgraded a static finding llm_review

The static rules flagged this MEDIUM, but an AI model (qwen/qwen3-235b-a22b-07-25) reviewed the full PKGBUILD and judged it LOW (confidence 95%): The source is a tarball from the official project's own domain (anl.gov), which hosts the legitimate PETSc releases; building from this source is standard practice and not inherently risky despite the non-whitelisted host.

1 higher static finding superseded - not the current verdict (shown for transparency)
MEDIUM source=() URL on a non-standard host source_untrusted_domain

One or more source=() URLs point to a host outside the trusted allowlist (github.com, gitlab.com, codeberg.org, pypi.org, …).

  • PKGBUILD:30 source=(http://web.cels.anl.gov/projects/petsc/download/release-snapshots/${pkgname}-${pkgver}.tar.gz

PKGBUILD

1 offending line(s) highlighted
1# Maintainer: Martin Diehl <aur@martin-diehl.net>
2# Contributor: Andreas Bilke <abilke at cosy dot sbg dot ac dot at>
3# Contributor: Myles English <myles at rockhead dot biz>
4# Contributor: Lucas H. Gabrielli <heitzmann at gmail dot com>
5pkgver=3.25.3
6pkgrel=1
7pkgname=petsc
8pkgdesc="Portable, extensible toolkit for scientific computation"
9arch=('i686' 'x86_64')
10url="https://petsc.org"
11license=('BSD-2-Clause')
12options=(staticlibs)
13depends=('openmpi' 'lapack' 'bison' 'fftw-openmpi' 'gsl' 'hdf5-openmpi' 'hwloc' 'libjpeg-turbo' 'libyaml'
14 'pastix' 'scotch' 'suitesparse' 'superlu' 'superlu_dist' 'zfp' 'zlib'
15 'python-numpy' 'python-mpi4py')
16makedepends=('gcc' 'gcc-fortran' 'cmake' 'cython' 'python-setuptools')
17provides=('petsc4py')
18optdepends=(
19 'hypre: support for HYPRE'
20 'kokkos: support Kokkos'
21 'metis: support for METIS'
22 'mumps: support for MUMPS'
23 'parmetis: support for ParMETIS'
24 'scalapack: support for ScaLAPACK'
25 'triangle: support for Triangle'
26 'zoltan: support for zoltan'
27 )
28
29install=petsc.install
30source=(http://web.cels.anl.gov/projects/petsc/download/release-snapshots/${pkgname}-${pkgver}.tar.gz
31 test_optdepends.sh
32 setuptools.patch)
33sha512sums=('8232e6d2d8c393a2e85d8739f3aaebc655fbf8a6ae68fc0b0cd576697ccd1c6b187b62124af1fe44c9ad6f3aeb31cba656f107f53659b4e7a8b4c01eacef78cc'
34 '4dc58de1393c2920de6ca08dcab71af0b13d21391d6b46f4a48aab122f087a3f4e4deae7b72b15fde5c7d344bcf12f5b766ff7c0ba4d816b074f94091a00cb97'
35 '3b89914d70a9788d8a0ecc059283320beabd96c163302f0d3c89405afac9969d282462e1372830025f74509c925c2b9b5a80a81e62a9e48fc7dcb8adbf18fe23')
36
37PETSC_ARCH=linux-c-opt
38_install_dir=/opt/petsc/${PETSC_ARCH}
39
40build() {
41 cd ${pkgname}-${pkgver}
42 export PETSC_DIR=${PWD}
43 export PETSC_ARCH=${PETSC_ARCH}
44
45 CONFOPTS="--with-shared-libraries=1 \
46 --with-petsc4py=1 \
47 --with-mpi-ftn-module=mpi_f08 \
48 --with-cmake=0 \
49 --with-debugging=0 \
50 --with-mpi-dir=/usr \
51 --with-fftw=1 \
52 --with-gsl=1 \
53 --with-hdf5=1 --with-hdf5-fortran-bindings=1 \
54 --with-hwloc=1 \
55 --with-libjpeg=1 \
56 --with-pastix=1 \
57 --with-ptscotch=1 --with-bison=1 --with-ptscotch-lib=[libesmumps.so,libptscotch.so,libptscotcherr.so,libscotch.so,libscotcherr.so] --with-ptscotch-include=/usr/include/scotch \
58 --with-suitesparse=1 \
59 --with-superlu-lib=-lsuperlu --with-superlu-include=/usr/include/superlu \
60 --with-superlu_dist-lib=-lsuperlu_dist --with-superlu_dist-include=/usr/include/superlu_dist \
61 --with-yaml=1 \
62 --with-zfp=1 \
63 $(sh ${srcdir}/test_optdepends.sh)"
64
65 echo './configure' ${CONFOPTS}
66 echo 'CFLAGS='${CFLAGS}
67 echo 'CXXFLAGS='${CXXFLAGS}
68 echo 'FFLAGS='${FFLAGS}
69 echo 'LDFLAGS='${LDFLAGS}
70 echo 'MAKEFLAGS='${MAKEFLAGS}
71
72 ./configure --prefix=${_install_dir} ${CONFOPTS} \
73 "CFLAGS=$CFLAGS" \
74 "CXXFLAGS=$CXXFLAGS" \
75 "FFLAGS=$FFLAGS" \
76 "LDFLAGS=$LDFLAGS -lstdc++" \
77 "MAKEFLAGS=$MAKEFLAGS"
78
79 make all
80}
81
82package() {
83 cd ${pkgname}-${pkgver}
84 export PETSC_DIR=${PWD}
85 export PETSC_ARCH=${PETSC_ARCH}
86
87 make DESTDIR=${pkgdir} install
88
89 install -Dm 644 LICENSE ${pkgdir}/usr/share/licenses/$pkgname/LICENSE
90
91 mkdir -p ${pkgdir}/etc/profile.d
92 echo export PETSC_DIR=${_install_dir} > ${pkgdir}/etc/profile.d/petsc.sh
93 echo export PYTHONPATH=${_install_dir}/lib:'${PYTHONPATH}' >> ${pkgdir}/etc/profile.d/petsc.sh
94 chmod 644 ${pkgdir}/etc/profile.d/petsc.sh
95
96 # show where the shared libraries are
97 install -dm 755 ${pkgdir}/etc/ld.so.conf.d/
98 echo ${_install_dir}/lib > ${pkgdir}/etc/ld.so.conf.d/petsc.conf
99
100 # install pkgconfig settings
101 install -Dm 644 ${PETSC_ARCH}/lib/pkgconfig/PETSc.pc ${pkgdir}/usr/share/pkgconfig/PETSc.pc
102}
103

Scan history

Scanned at (UTC)SeverityRules
2026-08-03 00:08:14 LOW 2
2026-08-02 00:16:08 LOW 2
2026-08-01 00:11:18 LOW 2
2026-07-31 00:14:10 LOW 2
2026-07-30 00:17:23 LOW 2
2026-07-29 00:25:53 LOW 2
2026-07-28 00:07:28 LOW 2
2026-07-27 00:24:32 LOW 2
2026-07-26 00:07:32 LOW 2
2026-07-25 00:13:44 LOW 2
2026-07-24 00:02:28 LOW 2
2026-07-23 00:14:47 LOW 2
2026-07-22 00:29:32 LOW 2
2026-07-21 00:24:15 LOW 2
2026-07-20 00:19:49 LOW 2
2026-07-19 00:17:08 LOW 2
2026-07-18 00:14:48 LOW 2
2026-07-17 00:06:16 LOW 2
2026-07-16 00:05:41 LOW 2
2026-07-15 00:09:25 LOW 2

Report a package

Reports go to the AURWatch maintainer (one person) and are read by hand. No login required.

0 / 4000
Your suggestion