gcc13-fortran
MEDIUM
maintainer FabioLolix
10 votes
base
gcc13
scanned 2026-09-23 01:39:21.955055
Why flagged
One or more source=() URLs point to a host outside the trusted allowlist (github.com, gitlab.com, codeberg.org, pypi.org, …).
Triggered rules
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:29
"git+https://sourceware.org/git/gcc.git#commit=${_commit}"
PKGBUILD
1 offending line(s) highlighted
1
# Maintainer: Fabio 'Lolix' Loli <fabio.loli@disroot.org> -> https://github.com/FabioLolix
2
# Maintainer: Chris Severance aur.severach aATt spamgourmet dott com
3
# Contributor: Pellegrino Prevete <pellegrinoprevete at gmail dot com>
4
# Contributor: elliotwutingfeng
5
# Contributor: Frederik Schwan <freswa at archlinux dot org>
6
# Contributor: Bartłomiej Piotrowski <bpiotrowski@archlinux.org>
7
# Contributor: Allan McRae <allan@archlinux.org>
8
# Contributor: Daniel Kozak <kozzi11@gmail.com>
9
10
# toolchain build order: linux-api-headers->glibc->binutils->gcc->glibc->binutils->gcc
11
# NOTE: libtool requires rebuilt with each new gcc version
12
13
set -u
14
pkgbase='gcc13'
15
pkgname=("${pkgbase}" "${pkgbase}-libs" "${pkgbase}-fortran")
16
pkgver=13.4.1+r80+gd6ebfe4
17
_majorver="${pkgver%%.*}"
18
_commit='d6ebfe490b856673c31ab2be5b311f3df370eca0'
19
pkgrel=1
20
pkgdesc="The GNU Compiler Collection (${_majorver}.x.x)"
21
arch=('x86_64')
22
url='https://gcc.gnu.org'
23
license=('GPL-3.0-with-GCC-exception' 'GFDL-1.3-or-later')
24
makedepends=('binutils' 'doxygen' 'gcc-ada' 'gcc-d' 'git' 'libisl' 'libmpc' 'python' 'zstd')
25
checkdepends=('dejagnu' 'expect' 'inetutils' 'python-pytest' 'tcl')
26
options=('!emptydirs' '!strip' '!buildflags')
27
options+=('!lto')
28
source=(
29
"git+https://sourceware.org/git/gcc.git#commit=${_commit}"
30
#"https://sourceware.org/pub/gcc/releases/gcc-${pkgver}/gcc-${pkgver}.tar.xz"
31
'c89'
32
'c99'
33
'fix-asan-allocator-aslr.patch'
34
'0000-kernel-7.1-remove-linux-scc.patch'
35
)
36
validpgpkeys=(F3691687D867B81B51CE07D9BBE43771487328A9 # bpiotrowski@archlinux.org
37
86CFFCA918CF3AF47147588051E8B148A9999C34 # foutrelis@archlinux.org
38
13975A70E63C361C73AE69EF6EEB81F8981C74C7 # richard.guenther@gmail.com
39
D3A93CAD751C2AF4F8C7AD516C35B99309B5FA62) # Jakub Jelinek <jakub@redhat.com>
40
sha256sums=('7b47ce30b7eb91793bd393d8ae639d526903860bda317bfa9e91442623d2aa2a'
41
'de48736f6e4153f03d0a5d38ceb6c6fdb7f054e8f47ddd6af0a3dbf14f27b931'
42
'2513c6d9984dd0a2058557bf00f06d8d5181734e41dcfe07be7ed86f2959622a'
43
'7a3ae47af2e888e7fed329e8ecaab47a26143ccb0edede4c397791d6d22b8043'
44
'0d89650effbd0572ece8c23761e7f736a172d57609633b60e861e8b79679e429')
45
46
if [ -n "${_snapshot:-}" ]; then
47
_basedir="gcc-${_snapshot}"
48
elif [ -n "${_commit:-}" ]; then
49
_basedir='gcc'
50
else
51
_basedir="gcc-${pkgver}"
52
fi
53
54
_fn_setlibdir() {
55
_libdir="usr/lib/gcc/${CHOST}/${pkgver%%+*}"
56
}
57
58
pkgver() {
59
local -
60
set -u
61
cd "${_basedir}"
62
echo "$(cat gcc/BASE-VER)+$(git describe --long --tags --abbrev=7 | sed 's/[^-]*-[^-]*-//;s/[^-]*-/r&/;s/-/+/g;s/_/./')"
63
}
64
65
prepare() {
66
local -
67
set -u
68
cd "${_basedir}"
69
70
# Do not run fixincludes
71
sed -e 's@\./fixinc\.sh@-c true@' -i 'gcc/Makefile.in'
72
73
# Arch Linux installs x86_64 libraries /lib
74
sed -e '/m64=/s/lib64/lib/' -i 'gcc/config/i386/t-linux64'
75
76
#ASan: move allocator base to avoid conflict with high-entropy ASLR for x86-64 Linux'
77
#patch -Np3 < "${srcdir}/fix-asan-allocator-aslr.patch" -d 'libsanitizer/'
78
79
# Apply patches
80
local _pt
81
for _pt in "${source[@]%%::*}"; do
82
_pt="${_pt##*/}"
83
case "${_pt}" in
84
*.patch)
85
set +u; msg2 "*** Applying patch ${_pt}"; set -u
86
patch --no-backup-if-mismatch -Np1 -i "${srcdir}/${_pt}"
87
;;
88
esac
89
done
90
91
rm -rf 'gcc-build'
92
mkdir 'gcc-build'
93
}
94
95
build() {
96
local -
97
set -u
98
cd "${_basedir}/gcc-build"
99
100
if [ ! -s 'Makefile' ]; then
101
# The following options are one per line, mostly sorted so they are easy to diff compare to other gcc packages.
102
local _conf=(
103
--disable-libssp
104
--disable-libstdcxx-pch
105
--disable-multilib
106
--disable-werror
107
--enable-bootstrap
108
--enable-__cxa_atexit
109
--enable-cet='auto'
110
--enable-checking='release'
111
--enable-clocale='gnu'
112
--enable-default-pie
113
--enable-default-ssp
114
--enable-gnu-indirect-function
115
--enable-gnu-unique-object
116
--enable-languages='c,c++,fortran'
117
--enable-libstdcxx-backtrace
118
--enable-linker-build-id
119
--enable-link-serialization='1'
120
--enable-lto
121
--enable-plugin
122
--enable-shared
123
--enable-threads='posix'
124
--enable-version-specific-runtime-libs
125
--infodir='/usr/share/info'
126
--libdir='/usr/lib'
127
--libexecdir='/usr/lib'
128
--mandir='/usr/share/man'
129
--program-suffix="-${_majorver}"
130
--with-bugurl="https://aur.archlinux.org/packages/${pkgname}/"
131
--with-build-config='bootstrap-lto'
132
--with-linker-hash-style='gnu'
133
--with-system-zlib
134
--prefix='/usr'
135
)
136
137
if ! :; then
138
# Credits @allanmcrae
139
# https://github.com/allanmcrae/toolchain/blob/f18604d70c5933c31b51a320978711e4e6791cf1/gcc/PKGBUILD
140
# TODO: properly deal with the build issues resulting from this
141
CFLAGS=${CFLAGS/-Werror=format-security/}
142
CXXFLAGS=${CXXFLAGS/-Werror=format-security/}
143
fi
144
145
../configure "${_conf[@]}"
146
fi
147
148
if ! :; then
149
# see https://bugs.archlinux.org/task/71777 for rationale re *FLAGS handling
150
make -O STAGE1_CFLAGS="-O2" \
151
BOOT_CFLAGS="$CFLAGS" \
152
BOOT_LDFLAGS="$LDFLAGS" \
153
LDFLAGS_FOR_TARGET="$LDFLAGS" \
154
bootstrap
155
fi
156
157
# Work-around `msgfmt: /build/gcc11/src/gcc-build/x86_64-pc-linux-gnu/libstdc++-v3/src/.libs/libstdc++.so.6: version `GLIBCXX_3.4.30' not found (required by /usr/lib/libicuuc.so.72)`
158
# The trick is borrowed from https://aur.archlinux.org/packages/gcc49
159
#LD_PRELOAD='/usr/lib/libstdc++.so' \
160
nice -n1 make -s
161
162
set +u; msg 'Compile complete'; set -u
163
164
# make documentation
165
make -s -j1 -C "${CHOST}/libstdc++-v3/doc" 'doc-man-doxygen'
166
}
167
168
check_disabled() {
169
local -
170
set -u
171
cd "${_basedir}/gcc-build"
172
173
# do not abort on error as some are "expected"
174
make -O -k check || true
175
../contrib/test_summary
176
}
177
178
package_gcc13-libs() {
179
local -
180
set -u
181
pkgdesc="Runtime libraries shipped by GCC (${_majorver}.x.x)"
182
depends=('glibc>=2.27')
183
options=('!emptydirs' '!strip')
184
185
cd "${_basedir}/gcc-build"
186
make -j1 -s -C "${CHOST}/libgcc" DESTDIR="${pkgdir}" 'install-shared'
187
local _libdir; _fn_setlibdir
188
mv "${pkgdir}/${_libdir}/../lib"/* "${pkgdir}/${_libdir}"
189
rmdir "${pkgdir}/${_libdir}/../lib"
190
rm -f "${pkgdir}/${_libdir}/libgcc_eh.a"
191
192
local _lib _libs=(
193
libasan
194
libatomic
195
libgfortran
196
libgomp
197
libitm
198
liblsan
199
libquadmath
200
libstdc++
201
libtsan
202
libubsan
203
)
204
for _lib in "${_libs[@]}"; do
205
ln -s "/usr/lib/${_lib}.so" "${pkgdir}/${_libdir}/${_lib}.so"
206
done
207
208
make -j1 -s -C "${CHOST}/libstdc++-v3/po" DESTDIR="${pkgdir}" install
209
210
rm -rf "${pkgdir}/${_libdir}/include/d/"
211
rm -f "${pkgdir}/usr/lib/libgphobos.spec"
212
213
# Install Runtime Library Exception
214
install -Dpm644 '../COPYING.RUNTIME' \
215
"${pkgdir}/usr/share/licenses/${pkgbase}-libs/RUNTIME.LIBRARY.EXCEPTION"
216
217
# remove conflicting files
218
rm -rf "${pkgdir}/usr/share/locale"
219
}
220
221
package_gcc13() {
222
local -
223
set -u
224
pkgdesc="The GNU Compiler Collection - C and C++ frontends (${_majorver}.x.x)"
225
depends=("${pkgbase}-libs=${pkgver}-${pkgrel}" 'binutils>=2.28' 'libmpc' 'zstd')
226
depends+=('libisl.so')
227
options=('!emptydirs' 'staticlibs')
228
229
cd "${_basedir}/gcc-build"
230
231
make -j1 -s -C 'gcc' DESTDIR="${pkgdir}" 'install-driver' 'install-cpp' 'install-gcc-ar' \
232
'c++.install-common' 'install-headers' 'install-plugin' 'install-lto-wrapper'
233
234
local _libdir; _fn_setlibdir
235
install -m755 -t "${pkgdir}/${_libdir}/" gcc/{cc1,cc1plus,collect2,lto1,gcov{,-tool}}
236
237
make -j1 -s -C "${CHOST}/libgcc" DESTDIR="${pkgdir}" install
238
rm -f "${pkgdir}/${_libdir}"/../lib/libgcc_s.so*
239
rmdir "${pkgdir}/${_libdir}"/../lib
240
241
make -j1 -s -C "${CHOST}/libstdc++-v3/src" DESTDIR="${pkgdir}" install
242
make -j1 -s -C "${CHOST}/libstdc++-v3/include" DESTDIR="${pkgdir}" install
243
make -j1 -s -C "${CHOST}/libstdc++-v3/libsupc++" DESTDIR="${pkgdir}" install
244
make -j1 -s -C "${CHOST}/libstdc++-v3/python" DESTDIR="${pkgdir}" install
245
rm -f "${pkgdir}/${_libdir}/"libstdc++.so*
246
247
make -j1 -s DESTDIR="${pkgdir}" 'install-fixincludes'
248
make -j1 -s -C 'gcc' DESTDIR="${pkgdir}" 'install-mkheaders'
249
250
make -j1 -s -C 'lto-plugin' DESTDIR="${pkgdir}" install
251
install -dm755 "${pkgdir}/${_libdir}/bfd-plugins/"
252
ln -s "/${_libdir}/liblto_plugin.so" \
253
"${pkgdir}/${_libdir}/bfd-plugins/"
254
255
make -j1 -s -C "${CHOST}/libgomp" DESTDIR="${pkgdir}" install-nodist_{libsubinclude,toolexeclib}HEADERS
256
make -j1 -s -C "${CHOST}/libitm" DESTDIR="${pkgdir}" 'install-nodist_toolexeclibHEADERS'
257
make -j1 -s -C "${CHOST}/libquadmath" DESTDIR="${pkgdir}" 'install-nodist_libsubincludeHEADERS'
258
make -j1 -s -C "${CHOST}/libsanitizer" DESTDIR="${pkgdir}" install-nodist_{saninclude,toolexeclib}HEADERS
259
make -j1 -s -C "${CHOST}/libsanitizer/asan" DESTDIR="${pkgdir}" 'install-nodist_toolexeclibHEADERS'
260
make -j1 -s -C "${CHOST}/libsanitizer/tsan" DESTDIR="${pkgdir}" 'install-nodist_toolexeclibHEADERS'
261
make -j1 -s -C "${CHOST}/libsanitizer/lsan" DESTDIR="${pkgdir}" 'install-nodist_toolexeclibHEADERS'
262
263
make -j1 -s -C 'libcpp' DESTDIR="${pkgdir}" install
264
make -j1 -s -C 'gcc' DESTDIR="${pkgdir}" 'install-po'
265
266
# many packages expect this symlink
267
ln -s "gcc-${_majorver}" "${pkgdir}/usr/bin/cc-${_majorver}"
268
269
# create cc-rs compatible symlinks
270
# https://github.com/rust-lang/cc-rs/blob/1.0.73/src/lib.rs#L2578-L2581
271
local _binary
272
for _binary in {c++,g++,gcc,gcc-ar,gcc-nm,gcc-ranlib}; do
273
ln -s "/usr/bin/${_binary}-${_majorver}" "${pkgdir}/usr/bin/x86_64-linux-gnu-${_binary}-${_majorver}"
274
done
275
276
# POSIX conformance launcher scripts for c89 and c99
277
install -Dm755 "${srcdir}/c89" "${pkgdir}/usr/bin/c89-${_majorver}"
278
install -Dm755 "${srcdir}/c99" "${pkgdir}/usr/bin/c99-${_majorver}"
279
280
# byte-compile python libraries
281
python -m 'compileall' "${pkgdir}/usr/share/gcc-${pkgver%%+*}/"
282
python -O -m 'compileall' "${pkgdir}/usr/share/gcc-${pkgver%%+*}/"
283
284
# Install Runtime Library Exception
285
install -d "${pkgdir}/usr/share/licenses/${pkgname}/"
286
ln -s "/usr/share/licenses/${pkgbase}-libs/RUNTIME.LIBRARY.EXCEPTION" \
287
"${pkgdir}/usr/share/licenses/${pkgname}/"
288
289
# Remove conflicting files
290
rm -rf "${pkgdir}/usr/share/locale"
291
}
292
293
package_gcc13-fortran() {
294
local -
295
set -u
296
pkgdesc="Fortran front-end for GCC (${_majorver}.x.x)"
297
depends=("${pkgbase}=${pkgver}-${pkgrel}")
298
depends+=('libisl.so')
299
300
cd "${_basedir}/gcc-build"
301
make -j1 -s -C "${CHOST}/libgfortran" DESTDIR="${pkgdir}" 'install-cafexeclibLTLIBRARIES' \
302
install-{toolexeclibDATA,nodist_fincludeHEADERS,gfor_cHEADERS}
303
make -j1 -s -C "${CHOST}/libgomp" DESTDIR="${pkgdir}" 'install-nodist_fincludeHEADERS'
304
make -j1 -s -C 'gcc' DESTDIR="${pkgdir}" 'fortran.install-common'
305
local _libdir; _fn_setlibdir
306
install -Dm755 'gcc/f951' "${pkgdir}/${_libdir}/f951"
307
308
ln -s "gfortran-${_majorver}" "${pkgdir}/usr/bin/f95-${_majorver}"
309
310
# Install Runtime Library Exception
311
install -d "${pkgdir}/usr/share/licenses/${pkgname}/"
312
ln -s "/usr/share/licenses/${pkgbase}-libs/RUNTIME.LIBRARY.EXCEPTION" \
313
"${pkgdir}/usr/share/licenses/${pkgname}/"
314
}
315
set +u
316
Changes since previous scan
--- PKGBUILD @ 2026-06-19 19:07+++ PKGBUILD @ 2026-09-23 01:39@@ -1,6 +1,7 @@-# Maintainer: Sven-Hendrik Haase <svenstaro@archlinux.org>-# Maintainer: Torsten Keßler <tpkessler@archlinux.org>-# Contributor: Giancarlo Razzolini <grazzolini@archlinux.org>+# Maintainer: Fabio 'Lolix' Loli <fabio.loli@disroot.org> -> https://github.com/FabioLolix+# Maintainer: Chris Severance aur.severach aATt spamgourmet dott com+# Contributor: Pellegrino Prevete <pellegrinoprevete at gmail dot com>+# Contributor: elliotwutingfeng # Contributor: Frederik Schwan <freswa at archlinux dot org> # Contributor: Bartłomiej Piotrowski <bpiotrowski@archlinux.org> # Contributor: Allan McRae <allan@archlinux.org>@@ -9,39 +10,28 @@ # toolchain build order: linux-api-headers->glibc->binutils->gcc->glibc->binutils->gcc # NOTE: libtool requires rebuilt with each new gcc version -pkgname=(gcc13 gcc13-libs gcc13-fortran)+set -u+pkgbase='gcc13'+pkgname=("${pkgbase}" "${pkgbase}-libs" "${pkgbase}-fortran") pkgver=13.4.1+r80+gd6ebfe4-_majorver=${pkgver%%.*}-_commit=d6ebfe490b856673c31ab2be5b311f3df370eca0+_majorver="${pkgver%%.*}"+_commit='d6ebfe490b856673c31ab2be5b311f3df370eca0' pkgrel=1-pkgdesc='The GNU Compiler Collection'-arch=(x86_64)-license=(GPL-3.0-with-GCC-exception GFDL-1.3-or-later)+pkgdesc="The GNU Compiler Collection (${_majorver}.x.x)"+arch=('x86_64') url='https://gcc.gnu.org'-makedepends=(- binutils- doxygen- gcc-ada- gcc-d- git- libisl- libmpc- python- zstd-)-checkdepends=(- dejagnu- expect- inetutils- python-pytest- tcl-)-options=(!emptydirs !lto)-_libdir=usr/lib/gcc/$CHOST/${pkgver%%+*}-source=(git+https://sourceware.org/git/gcc.git#commit=${_commit}- #https://sourceware.org/pub/gcc/releases/gcc-${pkgver}/gcc-${pkgver}.tar.xz- c89 c99- fix-asan-allocator-aslr.patch+license=('GPL-3.0-with-GCC-exception' 'GFDL-1.3-or-later')+makedepends=('binutils' 'doxygen' 'gcc-ada' 'gcc-d' 'git' 'libisl' 'libmpc' 'python' 'zstd')+checkdepends=('dejagnu' 'expect' 'inetutils' 'python-pytest' 'tcl')+options=('!emptydirs' '!strip' '!buildflags')+options+=('!lto')+source=(+ "git+https://sourceware.org/git/gcc.git#commit=${_commit}"+ #"https://sourceware.org/pub/gcc/releases/gcc-${pkgver}/gcc-${pkgver}.tar.xz"+ 'c89'+ 'c99'+ 'fix-asan-allocator-aslr.patch'+ '0000-kernel-7.1-remove-linux-scc.patch' ) validpgpkeys=(F3691687D867B81B51CE07D9BBE43771487328A9 # bpiotrowski@archlinux.org 86CFFCA918CF3AF47147588051E8B148A9999C34 # foutrelis@archlinux.org@@ -50,215 +40,277 @@ sha256sums=('7b47ce30b7eb91793bd393d8ae639d526903860bda317bfa9e91442623d2aa2a' 'de48736f6e4153f03d0a5d38ceb6c6fdb7f054e8f47ddd6af0a3dbf14f27b931' '2513c6d9984dd0a2058557bf00f06d8d5181734e41dcfe07be7ed86f2959622a'- '5ede1f5fec5b664428412a0849b28895be1c8d8982d3c0d246a4e95fd4730d65')+ '7a3ae47af2e888e7fed329e8ecaab47a26143ccb0edede4c397791d6d22b8043'+ '0d89650effbd0572ece8c23761e7f736a172d57609633b60e861e8b79679e429')++if [ -n "${_snapshot:-}" ]; then+ _basedir="gcc-${_snapshot}"+elif [ -n "${_commit:-}" ]; then+ _basedir='gcc'+else+ _basedir="gcc-${pkgver}"+fi++_fn_setlibdir() {+ _libdir="usr/lib/gcc/${CHOST}/${pkgver%%+*}"+} pkgver() {- cd gcc+ local -+ set -u+ cd "${_basedir}" echo "$(cat gcc/BASE-VER)+$(git describe --long --tags --abbrev=7 | sed 's/[^-]*-[^-]*-//;s/[^-]*-/r&/;s/-/+/g;s/_/./')" } prepare() {- [[ ! -d gcc ]] && ln -s gcc-${pkgver/+/-} gcc- cd gcc+ local -+ set -u+ cd "${_basedir}" # Do not run fixincludes- sed -i 's@\./fixinc\.sh@-c true@' gcc/Makefile.in+ sed -e 's@\./fixinc\.sh@-c true@' -i 'gcc/Makefile.in' # Arch Linux installs x86_64 libraries /lib- sed -i '/m64=/s/lib64/lib/' gcc/config/i386/t-linux64+ sed -e '/m64=/s/lib64/lib/' -i 'gcc/config/i386/t-linux64' #ASan: move allocator base to avoid conflict with high-entropy ASLR for x86-64 Linux'- patch -Np3 < "$srcdir/fix-asan-allocator-aslr.patch" -d libsanitizer/-- mkdir -p "$srcdir/gcc-build"+ #patch -Np3 < "${srcdir}/fix-asan-allocator-aslr.patch" -d 'libsanitizer/'++ # Apply patches+ local _pt+ for _pt in "${source[@]%%::*}"; do+ _pt="${_pt##*/}"+ case "${_pt}" in+ *.patch)+ set +u; msg2 "*** Applying patch ${_pt}"; set -u+ patch --no-backup-if-mismatch -Np1 -i "${srcdir}/${_pt}"+ ;;+ esac+ done++ rm -rf 'gcc-build'+ mkdir 'gcc-build' } build() {- local _confflags=(- --prefix=/usr- --libdir=/usr/lib- --libexecdir=/usr/lib- --mandir=/usr/share/man- --infodir=/usr/share/info- --with-bugurl=https://gitlab.archlinux.org/archlinux/packaging/packages/gcc13/-/issues- --with-build-config=bootstrap-lto- --with-linker-hash-style=gnu- --with-system-zlib+ local -+ set -u+ cd "${_basedir}/gcc-build"++ if [ ! -s 'Makefile' ]; then+ # The following options are one per line, mostly sorted so they are easy to diff compare to other gcc packages.+ local _conf=(+ --disable-libssp+ --disable-libstdcxx-pch+ --disable-multilib+ --disable-werror+ --enable-bootstrap --enable-__cxa_atexit- --enable-cet=auto- --enable-checking=release- --enable-clocale=gnu+ --enable-cet='auto'+ --enable-checking='release'+ --enable-clocale='gnu' --enable-default-pie --enable-default-ssp --enable-gnu-indirect-function --enable-gnu-unique-object+ --enable-languages='c,c++,fortran' --enable-libstdcxx-backtrace- --enable-link-serialization=1 --enable-linker-build-id+ --enable-link-serialization='1' --enable-lto- --disable-multilib --enable-plugin --enable-shared- --enable-threads=posix- --disable-libssp- --disable-libstdcxx-pch- --disable-werror- --program-suffix=-13+ --enable-threads='posix' --enable-version-specific-runtime-libs- )-- cd gcc-build-+ --infodir='/usr/share/info'+ --libdir='/usr/lib'+ --libexecdir='/usr/lib'+ --mandir='/usr/share/man'+ --program-suffix="-${_majorver}"+ --with-bugurl="https://aur.archlinux.org/packages/${pkgname}/"+ --with-build-config='bootstrap-lto'+ --with-linker-hash-style='gnu'+ --with-system-zlib+ --prefix='/usr'+ )++if ! :; then # Credits @allanmcrae # https://github.com/allanmcrae/toolchain/blob/f18604d70c5933c31b51a320978711e4e6791cf1/gcc/PKGBUILD # TODO: properly deal with the build issues resulting from this CFLAGS=${CFLAGS/-Werror=format-security/} CXXFLAGS=${CXXFLAGS/-Werror=format-security/}-- "$srcdir/gcc/configure" \- --enable-languages=c,c++,fortran \- --enable-bootstrap \- "${_confflags[@]:?_confflags unset}"-+fi++ ../configure "${_conf[@]}"+ fi++if ! :; then # see https://bugs.archlinux.org/task/71777 for rationale re *FLAGS handling make -O STAGE1_CFLAGS="-O2" \ BOOT_CFLAGS="$CFLAGS" \ BOOT_LDFLAGS="$LDFLAGS" \ LDFLAGS_FOR_TARGET="$LDFLAGS" \ bootstrap+fi++ # Work-around `msgfmt: /build/gcc11/src/gcc-build/x86_64-pc-linux-gnu/libstdc++-v3/src/.libs/libstdc++.so.6: version `GLIBCXX_3.4.30' not found (required by /usr/lib/libicuuc.so.72)`+ # The trick is borrowed from https://aur.archlinux.org/packages/gcc49+ #LD_PRELOAD='/usr/lib/libstdc++.so' \ + nice -n1 make -s++ set +u; msg 'Compile complete'; set -u # make documentation- make -O -C $CHOST/libstdc++-v3/doc doc-man-doxygen-}--check() {- cd gcc-build+ make -s -j1 -C "${CHOST}/libstdc++-v3/doc" 'doc-man-doxygen'+}++check_disabled() {+ local -+ set -u+ cd "${_basedir}/gcc-build" # do not abort on error as some are "expected" make -O -k check || true- "$srcdir/gcc/contrib/test_summary"+ ../contrib/test_summary } package_gcc13-libs() {- pkgdesc='Runtime libraries shipped by GCC (13.x.x)'+ local -+ set -u+ pkgdesc="Runtime libraries shipped by GCC (${_majorver}.x.x)" depends=('glibc>=2.27')- options=(!emptydirs !strip)-- cd gcc-build- make -C $CHOST/libgcc DESTDIR="$pkgdir" install-shared- mv "${pkgdir}/${_libdir}"/../lib/* "${pkgdir}/${_libdir}"- rmdir "${pkgdir}/${_libdir}"/../lib- rm -f "$pkgdir/$_libdir/libgcc_eh.a"-- for lib in libasan.so \- libatomic.so \- libgfortran.so \- libgomp.so \- libitm.so \- liblsan.so \- libquadmath.so \- libstdc++.so \- libtsan.so \- libubsan.so; do- ln -s /usr/lib/$lib "$pkgdir/$_libdir/$lib"+ options=('!emptydirs' '!strip')++ cd "${_basedir}/gcc-build"+ make -j1 -s -C "${CHOST}/libgcc" DESTDIR="${pkgdir}" 'install-shared'+ local _libdir; _fn_setlibdir+ mv "${pkgdir}/${_libdir}/../lib"/* "${pkgdir}/${_libdir}"+ rmdir "${pkgdir}/${_libdir}/../lib"+ rm -f "${pkgdir}/${_libdir}/libgcc_eh.a"++ local _lib _libs=(+ libasan+ libatomic+ libgfortran+ libgomp+ libitm+ liblsan+ libquadmath+ libstdc+++ libtsan+ libubsan+ )+ for _lib in "${_libs[@]}"; do+ ln -s "/usr/lib/${_lib}.so" "${pkgdir}/${_libdir}/${_lib}.so" done - make -C $CHOST/libstdc++-v3/po DESTDIR="$pkgdir" install-- rm -rf "$pkgdir"/$_libdir/include/d/- rm -f "$pkgdir"/usr/lib/libgphobos.spec+ make -j1 -s -C "${CHOST}/libstdc++-v3/po" DESTDIR="${pkgdir}" install++ rm -rf "${pkgdir}/${_libdir}/include/d/"+ rm -f "${pkgdir}/usr/lib/libgphobos.spec" # Install Runtime Library Exception- install -Dm644 "$srcdir/gcc/COPYING.RUNTIME" \- "$pkgdir/usr/share/licenses/gcc13-libs/RUNTIME.LIBRARY.EXCEPTION"+ install -Dpm644 '../COPYING.RUNTIME' \+ "${pkgdir}/usr/share/licenses/${pkgbase}-libs/RUNTIME.LIBRARY.EXCEPTION" # remove conflicting files- rm -rf "${pkgdir}"/usr/share/locale+ rm -rf "${pkgdir}/usr/share/locale" } package_gcc13() {- pkgdesc="The GNU Compiler Collection - C and C++ frontends (13.x.x)"- depends=("gcc13-libs" 'binutils>=2.28' libmpc zstd libisl.so)- options=(!emptydirs staticlibs)-- cd gcc-build-- make -C gcc DESTDIR="$pkgdir" install-driver install-cpp install-gcc-ar \- c++.install-common install-headers install-plugin install-lto-wrapper-- install -m755 -t "$pkgdir/${_libdir}/" gcc/{cc1,cc1plus,collect2,lto1,gcov{,-tool}}-- make -C $CHOST/libgcc DESTDIR="$pkgdir" install+ local -+ set -u+ pkgdesc="The GNU Compiler Collection - C and C++ frontends (${_majorver}.x.x)"+ depends=("${pkgbase}-libs=${pkgver}-${pkgrel}" 'binutils>=2.28' 'libmpc' 'zstd')+ depends+=('libisl.so')+ options=('!emptydirs' 'staticlibs')++ cd "${_basedir}/gcc-build"++ make -j1 -s -C 'gcc' DESTDIR="${pkgdir}" 'install-driver' 'install-cpp' 'install-gcc-ar' \+ 'c++.install-common' 'install-headers' 'install-plugin' 'install-lto-wrapper'++ local _libdir; _fn_setlibdir+ install -m755 -t "${pkgdir}/${_libdir}/" gcc/{cc1,cc1plus,collect2,lto1,gcov{,-tool}}++ make -j1 -s -C "${CHOST}/libgcc" DESTDIR="${pkgdir}" install rm -f "${pkgdir}/${_libdir}"/../lib/libgcc_s.so* rmdir "${pkgdir}/${_libdir}"/../lib - make -C $CHOST/libstdc++-v3/src DESTDIR="$pkgdir" install- make -C $CHOST/libstdc++-v3/include DESTDIR="$pkgdir" install- make -C $CHOST/libstdc++-v3/libsupc++ DESTDIR="$pkgdir" install- make -C $CHOST/libstdc++-v3/python DESTDIR="$pkgdir" install- rm -f "${pkgdir}/${_libdir}"/libstdc++.so*-- make DESTDIR="$pkgdir" install-fixincludes- make -C gcc DESTDIR="$pkgdir" install-mkheaders-- make -C lto-plugin DESTDIR="$pkgdir" install- install -dm755 "$pkgdir"/${_libdir}/bfd-plugins/- ln -s /${_libdir}/liblto_plugin.so \- "$pkgdir/${_libdir}/bfd-plugins/"-- make -C $CHOST/libgomp DESTDIR="$pkgdir" install-nodist_{libsubinclude,toolexeclib}HEADERS- make -C $CHOST/libitm DESTDIR="$pkgdir" install-nodist_toolexeclibHEADERS- make -C $CHOST/libquadmath DESTDIR="$pkgdir" install-nodist_libsubincludeHEADERS- make -C $CHOST/libsanitizer DESTDIR="$pkgdir" install-nodist_{saninclude,toolexeclib}HEADERS- make -C $CHOST/libsanitizer/asan DESTDIR="$pkgdir" install-nodist_toolexeclibHEADERS- make -C $CHOST/libsanitizer/tsan DESTDIR="$pkgdir" install-nodist_toolexeclibHEADERS- make -C $CHOST/libsanitizer/lsan DESTDIR="$pkgdir" install-nodist_toolexeclibHEADERS-- make -C libcpp DESTDIR="$pkgdir" install- make -C gcc DESTDIR="$pkgdir" install-po+ make -j1 -s -C "${CHOST}/libstdc++-v3/src" DESTDIR="${pkgdir}" install+ make -j1 -s -C "${CHOST}/libstdc++-v3/include" DESTDIR="${pkgdir}" install+ make -j1 -s -C "${CHOST}/libstdc++-v3/libsupc++" DESTDIR="${pkgdir}" install+ make -j1 -s -C "${CHOST}/libstdc++-v3/python" DESTDIR="${pkgdir}" install+ rm -f "${pkgdir}/${_libdir}/"libstdc++.so*++ make -j1 -s DESTDIR="${pkgdir}" 'install-fixincludes'+ make -j1 -s -C 'gcc' DESTDIR="${pkgdir}" 'install-mkheaders'++ make -j1 -s -C 'lto-plugin' DESTDIR="${pkgdir}" install+ install -dm755 "${pkgdir}/${_libdir}/bfd-plugins/"+ ln -s "/${_libdir}/liblto_plugin.so" \+ "${pkgdir}/${_libdir}/bfd-plugins/"++ make -j1 -s -C "${CHOST}/libgomp" DESTDIR="${pkgdir}" install-nodist_{libsubinclude,toolexeclib}HEADERS+ make -j1 -s -C "${CHOST}/libitm" DESTDIR="${pkgdir}" 'install-nodist_toolexeclibHEADERS'+ make -j1 -s -C "${CHOST}/libquadmath" DESTDIR="${pkgdir}" 'install-nodist_libsubincludeHEADERS'+ make -j1 -s -C "${CHOST}/libsanitizer" DESTDIR="${pkgdir}" install-nodist_{saninclude,toolexeclib}HEADERS+ make -j1 -s -C "${CHOST}/libsanitizer/asan" DESTDIR="${pkgdir}" 'install-nodist_toolexeclibHEADERS'+ make -j1 -s -C "${CHOST}/libsanitizer/tsan" DESTDIR="${pkgdir}" 'install-nodist_toolexeclibHEADERS'+ make -j1 -s -C "${CHOST}/libsanitizer/lsan" DESTDIR="${pkgdir}" 'install-nodist_toolexeclibHEADERS'++ make -j1 -s -C 'libcpp' DESTDIR="${pkgdir}" install+ make -j1 -s -C 'gcc' DESTDIR="${pkgdir}" 'install-po' # many packages expect this symlink- ln -s gcc-13 "$pkgdir"/usr/bin/cc-13+ ln -s "gcc-${_majorver}" "${pkgdir}/usr/bin/cc-${_majorver}" # create cc-rs compatible symlinks # https://github.com/rust-lang/cc-rs/blob/1.0.73/src/lib.rs#L2578-L2581- for binary in {c++,g++,gcc,gcc-ar,gcc-nm,gcc-ranlib}; do- ln -s /usr/bin/${binary} "${pkgdir}"/usr/bin/x86_64-linux-gnu-${binary}-13+ local _binary+ for _binary in {c++,g++,gcc,gcc-ar,gcc-nm,gcc-ranlib}; do+ ln -s "/usr/bin/${_binary}-${_majorver}" "${pkgdir}/usr/bin/x86_64-linux-gnu-${_binary}-${_majorver}" done # POSIX conformance launcher scripts for c89 and c99- install -Dm755 "$srcdir/c89" "$pkgdir/usr/bin/c89-13"- install -Dm755 "$srcdir/c99" "$pkgdir/usr/bin/c99-13"+ install -Dm755 "${srcdir}/c89" "${pkgdir}/usr/bin/c89-${_majorver}"+ install -Dm755 "${srcdir}/c99" "${pkgdir}/usr/bin/c99-${_majorver}" # byte-compile python libraries- python -m compileall "$pkgdir/usr/share/gcc-${pkgver%%+*}/"- python -O -m compileall "$pkgdir/usr/share/gcc-${pkgver%%+*}/"+ python -m 'compileall' "${pkgdir}/usr/share/gcc-${pkgver%%+*}/"+ python -O -m 'compileall' "${pkgdir}/usr/share/gcc-${pkgver%%+*}/" # Install Runtime Library Exception- install -d "$pkgdir/usr/share/licenses/$pkgname/"- ln -s /usr/share/licenses/gcc-libs/RUNTIME.LIBRARY.EXCEPTION \- "$pkgdir/usr/share/licenses/$pkgname/"-- # remove conflicting files- rm -rf "${pkgdir}"/usr/share/locale+ install -d "${pkgdir}/usr/share/licenses/${pkgname}/"+ ln -s "/usr/share/licenses/${pkgbase}-libs/RUNTIME.LIBRARY.EXCEPTION" \+ "${pkgdir}/usr/share/licenses/${pkgname}/"++ # Remove conflicting files+ rm -rf "${pkgdir}/usr/share/locale" } package_gcc13-fortran() {- pkgdesc='Fortran front-end for GCC (13.x.x)'- depends=("gcc13" libisl.so)-- cd gcc-build- make -C $CHOST/libgfortran DESTDIR="$pkgdir" install-cafexeclibLTLIBRARIES \+ local -+ set -u+ pkgdesc="Fortran front-end for GCC (${_majorver}.x.x)"+ depends=("${pkgbase}=${pkgver}-${pkgrel}")+ depends+=('libisl.so')++ cd "${_basedir}/gcc-build"+ make -j1 -s -C "${CHOST}/libgfortran" DESTDIR="${pkgdir}" 'install-cafexeclibLTLIBRARIES' \ install-{toolexeclibDATA,nodist_fincludeHEADERS,gfor_cHEADERS}- make -C $CHOST/libgomp DESTDIR="$pkgdir" install-nodist_fincludeHEADERS- make -C gcc DESTDIR="$pkgdir" fortran.install-common- install -Dm755 gcc/f951 "$pkgdir/${_libdir}/f951"-- ln -s gfortran-13 "$pkgdir/usr/bin/f95-13"+ make -j1 -s -C "${CHOST}/libgomp" DESTDIR="${pkgdir}" 'install-nodist_fincludeHEADERS'+ make -j1 -s -C 'gcc' DESTDIR="${pkgdir}" 'fortran.install-common'+ local _libdir; _fn_setlibdir+ install -Dm755 'gcc/f951' "${pkgdir}/${_libdir}/f951"++ ln -s "gfortran-${_majorver}" "${pkgdir}/usr/bin/f95-${_majorver}" # Install Runtime Library Exception- install -d "$pkgdir/usr/share/licenses/$pkgname/"- ln -s /usr/share/licenses/gcc-libs/RUNTIME.LIBRARY.EXCEPTION \- "$pkgdir/usr/share/licenses/$pkgname/"-}-+ install -d "${pkgdir}/usr/share/licenses/${pkgname}/"+ ln -s "/usr/share/licenses/${pkgbase}-libs/RUNTIME.LIBRARY.EXCEPTION" \+ "${pkgdir}/usr/share/licenses/${pkgname}/"+}+set +u+Scan history
| Scanned at (UTC) | Severity | Rules |
|---|---|---|
| 2026-09-23 01:39:21 | Medium | 1 |
| 2026-06-19 19:07:35 | Clean | 2 |
| 2026-06-18 16:11:54 | Medium | 1 |