# Automatically generated aport, do not edit! # Generator: pmbootstrap aportgen gcc-aarch64 # Based on: main/gcc (from Alpine) CTARGET_ARCH=aarch64 CTARGET="$(arch_to_hostspec ${CTARGET_ARCH})" LANG_D=false LANG_OBJC=false LANG_JAVA=false LANG_GO=false LANG_FORTRAN=false LANG_ADA=false options="!strip !tracedeps" # abuild doesn't try to tries to install "build-base-$CTARGET_ARCH" # when this variable matches "no*" BOOTSTRAP="nobuildbase" # abuild will only cross compile when this variable is set, but it # needs to find a valid package database in there for dependency # resolving, so we set it to /. CBUILDROOT="/" _cross_configure="--disable-bootstrap --with-sysroot=/usr/$CTARGET" pkgname=gcc-aarch64 _pkgbase=10.3.1 pkgver=10.3.1_git20210409 [ "$BOOTSTRAP" = "nolibc" ] && pkgname="gcc-pass2" [ "$CBUILD" != "$CHOST" ] && _cross="-$CARCH" || _cross="" [ "$CHOST" != "$CTARGET" ] && _target="-$CTARGET_ARCH" || _target="" pkgname=gcc-aarch64 pkgrel=0 pkgdesc="Stage2 cross-compiler for aarch64" url="https://gcc.gnu.org" arch="x86_64" license="GPL-2.0-or-later LGPL-2.1-or-later" _gccrel=$pkgver-r$pkgrel depends="isl binutils-aarch64 mpc1" makedepends_build="gcc g++ paxmark bison flex texinfo gawk zip gmp-dev mpfr-dev mpc1-dev zlib-dev" makedepends_host="linux-headers gmp-dev mpfr-dev mpc1-dev isl-dev zlib-dev musl-dev-aarch64 binutils-aarch64" subpackages="g++-aarch64:gpp" [ "$CHOST" = "$CTARGET" ] && subpackages="gcc-doc$_target" replaces="libstdc++ binutils" : "${LANG_CXX:=true}" : "${LANG_D:=true}" : "${LANG_OBJC:=true}" : "${LANG_GO:=true}" : "${LANG_FORTRAN:=true}" : "${LANG_ADA:=true}" _libgomp=true _libgcc=true _libatomic=true _libitm=true if [ "$CHOST" != "$CTARGET" ]; then if [ "$BOOTSTRAP" = nolibc ]; then LANG_CXX=false LANG_ADA=false _libgcc=false _builddir="$srcdir/build-cross-pass2" else _builddir="$srcdir/build-cross-final" fi LANG_OBJC=false LANG_GO=false LANG_FORTRAN=false LANG_D=false _libgomp=false _libatomic=false _libitm=false # reset target flags (should be set in crosscreate abuild) # fixup flags. seems gcc treats CPPFLAGS as global without # _FOR_xxx variants. wrap it in CFLAGS and CXXFLAGS. export CFLAGS="$CPPFLAGS $CFLAGS" export CXXFLAGS="$CPPFLAGS $CXXFLAGS" unset CPPFLAGS export CFLAGS_FOR_TARGET=" " export CXXFLAGS_FOR_TARGET=" " export LDFLAGS_FOR_TARGET=" " STRIP_FOR_TARGET="$CTARGET-strip" elif [ "$CBUILD" != "$CHOST" ]; then # fixup flags. seems gcc treats CPPFLAGS as global without # _FOR_xxx variants. wrap it in CFLAGS and CXXFLAGS. export CFLAGS="$CPPFLAGS $CFLAGS" export CXXFLAGS="$CPPFLAGS $CXXFLAGS" unset CPPFLAGS # reset flags and cc for build export CC_FOR_BUILD="gcc" export CXX_FOR_BUILD="g++" export CFLAGS_FOR_BUILD=" " export CXXFLAGS_FOR_BUILD=" " export LDFLAGS_FOR_BUILD=" " export CFLAGS_FOR_TARGET=" " export CXXFLAGS_FOR_TARGET=" " export LDFLAGS_FOR_TARGET=" " # Languages that do not need bootstrapping LANG_OBJC=false LANG_GO=false LANG_FORTRAN=false LANG_D=false STRIP_FOR_TARGET=${CROSS_COMPILE}strip _builddir="$srcdir/build-cross-native" else STRIP_FOR_TARGET=${CROSS_COMPILE}strip _builddir="$srcdir/build" fi # GDC hasn't been ported to PowerPC # See libphobos/configure.tgt in GCC sources for supported targets [ "$CARCH" = ppc64le ] && LANG_D=false # libitm has TEXTRELs in ARM build, so disable for now case "$CTARGET_ARCH" in arm*) _libitm=false ;; mips*) _libitm=false ;; esac # Internal libffi fails to build on MIPS at the moment, need to # investigate further. We disable LANG_GO on mips64 as it requires # the internal libffi. case "$CTARGET_ARCH" in mips*) LANG_GO=false ;; esac # Fortran uses libquadmath if toolchain has __float128 # currently on x86, x86_64 and ia64 _libquadmath=$LANG_FORTRAN case "$CTARGET_ARCH" in x86 | x86_64) _libquadmath=$LANG_FORTRAN ;; *) _libquadmath=false ;; esac # libatomic is a dependency for openvswitch $_libatomic && subpackages="$subpackages libatomic::$CTARGET_ARCH" $_libgcc && subpackages="$subpackages libgcc::$CTARGET_ARCH" $_libquadmath && subpackages="$subpackages libquadmath::$CTARGET_ARCH" if $_libgomp; then depends="$depends libgomp=$_gccrel" subpackages="$subpackages libgomp::$CTARGET_ARCH" fi _languages=c if $LANG_CXX; then _languages="$_languages,c++" fi if $LANG_D; then subpackages="$subpackages libgphobos::$CTARGET_ARCH gcc-gdc$_target:gdc" _languages="$_languages,d" makedepends_build="$makedepends_build libucontext-dev" fi if $LANG_OBJC; then subpackages="$subpackages libobjc::$CTARGET_ARCH gcc-objc$_target:objc" _languages="$_languages,objc" fi if $LANG_GO; then subpackages="$subpackages libgo::$CTARGET_ARCH gcc-go$_target:go" _languages="$_languages,go" fi if $LANG_FORTRAN; then subpackages="$subpackages libgfortran::$CTARGET_ARCH gfortran$_target:gfortran" _languages="$_languages,fortran" fi if $LANG_ADA; then subpackages="$subpackages libgnat-static:libgnatstatic:$CTARGET_ARCH libgnat::$CTARGET_ARCH gcc-gnat$_target:gnat" _languages="$_languages,ada" [ "$CBUILD" = "$CTARGET" ] && makedepends_build="$makedepends_build gcc-gnat-bootstrap" [ "$CBUILD" != "$CTARGET" ] && makedepends_build="$makedepends_build gcc-gnat gcc-gnat$_cross" fi makedepends="$makedepends_build $makedepends_host" # when using upstream releases, use this URI template # https://gcc.gnu.org/pub/gcc/releases/gcc-${_pkgbase:-$pkgver}/gcc-${_pkgbase:-$pkgver}.tar.xz # # right now, we are using a git snapshot. # # PLEASE submit all patches to gcc to https://gitlab.alpinelinux.org/kaniini/alpine-gcc-patches, # so that they can be properly tracked and easily rebased if needed. source="https://dev.alpinelinux.org/~nenolod/gcc-${pkgver}.tar.xz 0001-posix_memalign.patch 0002-gcc-poison-system-directories.patch 0003-Turn-on-Wl-z-relro-z-now-by-default.patch 0004-Turn-on-D_FORTIFY_SOURCE-2-by-default-for-C-C-ObjC-O.patch 0005-On-linux-targets-pass-as-needed-by-default-to-the-li.patch 0006-Enable-Wformat-and-Wformat-security-by-default.patch 0007-Enable-Wtrampolines-by-default.patch 0008-Disable-ssp-on-nostdlib-nodefaultlibs-and-ffreestand.patch 0009-Ensure-that-msgfmt-doesn-t-encounter-problems-during.patch 0010-Don-t-declare-asprintf-if-defined-as-a-macro.patch 0011-libiberty-copy-PIC-objects-during-build-process.patch 0012-libitm-disable-FORTIFY.patch 0013-libgcc_s.patch 0014-nopie.patch 0015-libffi-use-__linux__-instead-of-__gnu_linux__-for-mu.patch 0016-dlang-update-zlib-binding.patch 0017-dlang-fix-fcntl-on-mips-add-libucontext-dep.patch 0018-ada-fix-shared-linking.patch 0019-build-fix-CXXFLAGS_FOR_BUILD-passing.patch 0020-add-fortify-headers-paths.patch 0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch 0022-DP-Use-push-state-pop-state-for-gold-as-well-when-li.patch 0023-Pure-64-bit-MIPS.patch 0024-use-pure-64-bit-configuration-where-appropriate.patch 0025-always-build-libgcc_eh.a.patch 0026-ada-libgnarl-compatibility-for-musl.patch 0027-ada-musl-support-fixes.patch 0028-gcc-go-Use-_off_t-type-instead-of-_loff_t.patch 0029-gcc-go-Don-t-include-sys-user.h.patch 0030-gcc-go-Fix-ucontext_t-on-PPC64.patch 0031-gcc-go-Fix-handling-of-signal-34-on-musl.patch 0032-gcc-go-Use-int64-type-as-offset-argument-for-mmap.patch 0033-gcc-go-Fix-st_-a-m-c-tim-fields-in-generated-sysinfo.patch 0034-gcc-go-signal-34-is-special-on-musl-libc.patch 0035-gcc-go-Prefer-_off_t-over-_off64_t.patch 0036-gcc-go-undef-SETCONTEXT_CLOBBERS_TLS-in-proc.c.patch 0037-gcc-go-link-to-libucontext.patch 0038-gcc-go-Disable-printing-of-unaccessible-ppc64-struct.patch 0039-CRuntime_Musl-Support-v1.2.0-for-32-bits.patch 0040-configure-Add-enable-autolink-libatomic-use-in-LINK_.patch " # we build out-of-tree _gccdir="$srcdir"/gcc-$pkgver _gcclibdir="/usr/lib/gcc/$CTARGET/${_pkgbase:-$pkgver}" _gcclibexec="/usr/libexec/gcc/$CTARGET/${_pkgbase:-$pkgver}" prepare() { cd "$_gccdir" _err= for i in $source; do case "$i" in *.patch) msg "Applying $i" patch -p1 -i "$srcdir"/$i || _err="$_err $i" ;; esac done if [ -n "$_err" ]; then error "The following patches failed:" for i in $_err; do echo " $i" done return 1 fi echo ${_pkgbase:-$pkgver} > gcc/BASE-VER } build() { local _arch_configure= local _libc_configure= local _bootstrap_configure= local _symvers= cd "$_gccdir" case "$CTARGET" in aarch64-*-*-*) _arch_configure="--with-arch=armv8-a --with-abi=lp64";; armv5-*-*-*eabi) _arch_configure="--with-arch=armv5te --with-tune=arm926ej-s --with-float=soft --with-abi=aapcs-linux";; armv6-*-*-*eabihf) _arch_configure="--with-arch=armv6zk --with-tune=arm1176jzf-s --with-fpu=vfp --with-float=hard --with-abi=aapcs-linux";; armv7-*-*-*eabihf) _arch_configure="--with-arch=armv7-a --with-tune=generic-armv7-a --with-fpu=vfpv3-d16 --with-float=hard --with-abi=aapcs-linux --with-mode=thumb";; mips-*-*-*) _arch_configure="--with-arch=mips32 --with-mips-plt --with-float=soft --with-abi=32";; mips64-*-*-*) _arch_configure="--with-arch=mips3 --with-tune=mips64 --with-mips-plt --with-float=soft --with-abi=64";; mips64el-*-*-*) _arch_configure="--with-arch=mips3 --with-tune=mips64 --with-mips-plt --with-float=soft --with-abi=64";; mipsel-*-*-*) _arch_configure="--with-arch=mips32 --with-mips-plt --with-float=soft --with-abi=32";; powerpc-*-*-*) _arch_configure="--enable-secureplt --enable-decimal-float=no";; powerpc64*-*-*-*) _arch_configure="--with-abi=elfv2 --enable-secureplt --enable-decimal-float=no --enable-targets=powerpcle-linux";; i486-*-*-*) _arch_configure="--with-arch=i486 --with-tune=generic --enable-cld";; i586-*-*-*) _arch_configure="--with-arch=i586 --with-tune=generic --enable-cld";; s390x-*-*-*) _arch_configure="--with-arch=z196 --with-tune=zEC12 --with-zarch --with-long-double-128 --enable-decimal-float";; esac case "$CTARGET_ARCH" in mips*) _hash_style_configure="--with-linker-hash-style=sysv" ;; *) _hash_style_configure="--with-linker-hash-style=gnu" ;; esac case "$CTARGET_LIBC" in musl) # musl does not support mudflap, or libsanitizer # libmpx uses secure_getenv and struct _libc_fpstate not present in musl # alpine musl provides libssp_nonshared.a, so we don't need libssp either _libc_configure="--disable-libssp --disable-libmpx --disable-libmudflap --disable-libsanitizer" _symvers="--disable-symvers" export libat_cv_have_ifunc=no ;; esac case "$BOOTSTRAP" in nolibc) _bootstrap_configure="--with-newlib --disable-shared --enable-threads=no" ;; *) _bootstrap_configure="--enable-shared --enable-threads --enable-tls" ;; esac $_libgomp || _bootstrap_configure="$_bootstrap_configure --disable-libgomp" $_libatomic || _bootstrap_configure="$_bootstrap_configure --disable-libatomic" $_libitm || _bootstrap_configure="$_bootstrap_configure --disable-libitm" $_libquadmath || _arch_configure="$_arch_configure --disable-libquadmath" msg "Building the following:" echo "" echo " CBUILD=$CBUILD" echo " CHOST=$CHOST" echo " CTARGET=$CTARGET" echo " CTARGET_ARCH=$CTARGET_ARCH" echo " CTARGET_LIBC=$CTARGET_LIBC" echo " languages=$_languages" echo " arch_configure=$_arch_configure" echo " libc_configure=$_libc_configure" echo " cross_configure=$_cross_configure" echo " bootstrap_configure=$_bootstrap_configure" echo " hash_style_configure=$_hash_style_configure" echo "" export CFLAGS="$CFLAGS -O2" mkdir -p "$_builddir" cd "$_builddir" "$_gccdir"/configure --prefix=/usr \ --mandir=/usr/share/man \ --infodir=/usr/share/info \ --build=${CBUILD} \ --host=${CHOST} \ --target=${CTARGET} \ --with-pkgversion="Alpine $pkgver" \ --enable-checking=release \ --disable-fixed-point \ --disable-libstdcxx-pch \ --disable-multilib \ --disable-nls \ --disable-werror \ $_symvers \ --enable-__cxa_atexit \ --enable-default-pie \ --enable-default-ssp \ --enable-cloog-backend \ --enable-languages=$_languages \ $_arch_configure \ $_libc_configure \ $_cross_configure \ $_bootstrap_configure \ --with-system-zlib \ $_hash_style_configure make } package() { cd "$_builddir" make -j1 DESTDIR="$pkgdir" install ln -s gcc "$pkgdir"/usr/bin/cc # we dont support gcj -static # and saving 35MB is not bad. find "$pkgdir" \( -name libgtkpeer.a \ -o -name libgjsmalsa.a \ -o -name libgij.a \) \ -delete # strip debug info from some static libs find "$pkgdir" \( -name libgfortran.a -o -name libobjc.a -o -name libgomp.a \ -o -name libgphobos.a -o -name libgdruntime.a \ -o -name libmudflap.a -o -name libmudflapth.a \ -o -name libgcc.a -o -name libgcov.a -o -name libquadmath.a \ -o -name libitm.a -o -name libgo.a -o -name libcaf\*.a \ -o -name libatomic.a -o -name libasan.a -o -name libtsan.a \) \ -a -type f \ -exec ${STRIP_FOR_TARGET} -g {} + if $_libgomp; then mv "$pkgdir"/usr/lib/libgomp.spec "$pkgdir"/$_gcclibdir fi if $_libitm; then mv "$pkgdir"/usr/lib/libitm.spec "$pkgdir"/$_gcclibdir fi # remove ffi rm -f "$pkgdir"/usr/lib/libffi* "$pkgdir"/usr/share/man/man3/ffi* find "$pkgdir" -name 'ffi*.h' -delete local gdblib=${_target:+$CTARGET/}lib if [ -d "$pkgdir"/usr/$gdblib/ ]; then for i in $(find "$pkgdir"/usr/$gdblib/ -type f -maxdepth 1 -name "*-gdb.py"); do mkdir -p "$pkgdir"/usr/share/gdb/python/auto-load/usr/$gdblib mv "$i" "$pkgdir"/usr/share/gdb/python/auto-load/usr/$gdblib/ done fi # move ada runtime libs if $LANG_ADA; then for i in $(find "$pkgdir"/$_gcclibdir/adalib/ -type f -maxdepth 1 -name "libgna*.so"); do mv "$i" "$pkgdir"/usr/lib/ ln -s ../../../../${i##*/} $i done for i in $(find "$pkgdir"/$_gcclibdir/adalib/ -type f -maxdepth 1 -name "libgna*.a"); do mv "$i" "$pkgdir"/usr/lib/ ln -s ../../../../${i##*/} $i done fi if [ "$CHOST" != "$CTARGET" ]; then # cross-gcc: remove any files that would conflict with the # native gcc package rm -rf "$pkgdir"/usr/bin/cc "$pkgdir"/usr/include "${pkgdir:?}"/usr/share # libcc1 does not depend on target, don't ship it rm -rf "$pkgdir"/usr/lib/libcc1.so* # fixup gcc library symlinks to be linker scripts so # linker finds the libs from relocated sysroot for so in "$pkgdir"/usr/"$CTARGET"/lib/*.so; do if [ -h "$so" ]; then local _real=$(basename "$(readlink "$so")") rm -f "$so" echo "GROUP ($_real)" > "$so" fi done else # add c89/c99 wrapper scripts cat >"$pkgdir"/usr/bin/c89 <<'EOF' #!/bin/sh _flavor="-std=c89" for opt; do case "$opt" in -ansi|-std=c89|-std=iso9899:1990) _flavor="";; -std=*) echo "$(basename $0) called with non ANSI/ISO C option $opt" >&2 exit 1;; esac done exec gcc $_flavor ${1+"$@"} EOF cat >"$pkgdir"/usr/bin/c99 <<'EOF' #!/bin/sh _flavor="-std=c99" for opt; do case "$opt" in -std=c99|-std=iso9899:1999) _flavor="";; -std=*) echo "$(basename $0) called with non ISO C99 option $opt" >&2 exit 1;; esac done exec gcc $_flavor ${1+"$@"} EOF chmod 755 "$pkgdir"/usr/bin/c?9 # install lto plugin so regular binutils may use it mkdir -p "$pkgdir"/usr/lib/bfd-plugins ln -s /$_gcclibexec/liblto_plugin.so "$pkgdir/usr/lib/bfd-plugins/" fi } libatomic() { pkgdesc="GCC Atomic library" depends= replaces="gcc" mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/${_target:+$CTARGET/}lib/libatomic.so.* "$subpkgdir"/usr/lib/ } libcxx() { pkgdesc="GNU C++ standard runtime library" depends= if [ "$CHOST" = "$CTARGET" ]; then # verify that we are using clock_gettime rather than doing direct syscalls # so we dont break 32 bit arches due to time64. nm -D "$pkgdir"/usr/lib/libstdc++.so.* | grep clock_gettime fi mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/${_target:+$CTARGET/}lib/libstdc++.so.* "$subpkgdir"/usr/lib/ } gpp() { pkgdesc="GNU C++ standard library and compiler" depends="libstdc++=$_gccrel gcc=$_gccrel libc-dev" mkdir -p "$subpkgdir/$_gcclibexec" \ "$subpkgdir"/usr/bin \ "$subpkgdir"/usr/${_target:+$CTARGET/}include \ "$subpkgdir"/usr/${_target:+$CTARGET/}lib \ mv "$pkgdir/$_gcclibexec/cc1plus" "$subpkgdir/$_gcclibexec/" mv "$pkgdir"/usr/${_target:+$CTARGET/}lib/*++* "$subpkgdir"/usr/${_target:+$CTARGET/}lib/ mv "$pkgdir"/usr/${_target:+$CTARGET/}include/c++ "$subpkgdir"/usr/${_target:+$CTARGET/}include/ mv "$pkgdir"/usr/bin/*++ "$subpkgdir"/usr/bin/ } libobjc() { pkgdesc="GNU Objective-C runtime" replaces="objc" depends= mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/${_target:+$CTARGET/}lib/libobjc.so.* "$subpkgdir"/usr/lib/ } objc() { pkgdesc="GNU Objective-C" replaces="gcc" depends="libc-dev gcc=$_gccrel libobjc=$_gccrel" mkdir -p "$subpkgdir/$_gcclibexec" \ "$subpkgdir"/$_gcclibdir/include \ "$subpkgdir"/usr/lib mv "$pkgdir/$_gcclibexec/cc1obj" "$subpkgdir/$_gcclibexec/" mv "$pkgdir"/$_gcclibdir/include/objc "$subpkgdir"/$_gcclibdir/include/ mv "$pkgdir"/usr/lib/libobjc.so "$pkgdir"/usr/lib/libobjc.a \ "$subpkgdir"/usr/lib/ } libgcc() { pkgdesc="GNU C compiler runtime libraries" depends= mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/${_target:+$CTARGET/}lib/libgcc_s.so.* "$subpkgdir"/usr/lib/ } libgomp() { pkgdesc="GCC shared-memory parallel programming API library" depends= replaces="gcc" mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/${_target:+$CTARGET/}lib/libgomp.so.* "$subpkgdir"/usr/lib/ } libgphobos() { pkgdesc="D programming language standard library for GCC" depends= mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/lib/libgdruntime.so.* "$subpkgdir"/usr/lib/ mv "$pkgdir"/usr/lib/libgphobos.so.* "$subpkgdir"/usr/lib/ } gdc() { pkgdesc="GCC-based D language compiler" depends="gcc=$_gccrel libgphobos=$_gccrel musl-dev" depends="$depends libucontext-dev" mkdir -p "$subpkgdir/$_gcclibexec" \ "$subpkgdir"/$_gcclibdir/include/d/ \ "$subpkgdir"/usr/lib \ "$subpkgdir"/usr/bin # Copy: The installed '.d' files, the static lib, the binary itself # The shared libs are part of 'libgphobos' so one can run program # without installing the compiler mv "$pkgdir/$_gcclibexec/d21" "$subpkgdir/$_gcclibexec/" mv "$pkgdir"/$_gcclibdir/include/d/* "$subpkgdir"/$_gcclibdir/include/d/ mv "$pkgdir"/usr/lib/libgdruntime.a "$subpkgdir"/usr/lib/ mv "$pkgdir"/usr/lib/libgphobos.a "$subpkgdir"/usr/lib/ mv "$pkgdir"/usr/lib/libgphobos.spec "$subpkgdir"/usr/lib/ mv "$pkgdir"/usr/bin/$CTARGET-gdc "$subpkgdir"/usr/bin/ mv "$pkgdir"/usr/bin/gdc "$subpkgdir"/usr/bin/ } libgo() { pkgdesc="Go runtime library for GCC" depends= mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/lib/libgo.so.* "$subpkgdir"/usr/lib/ } go() { pkgdesc="Go support for GCC" depends="gcc=$_gccrel libgo=$_gccrel !go" mkdir -p "$subpkgdir"/$_gcclibexec \ "$subpkgdir"/usr/lib \ "$subpkgdir"/usr/bin mv "$pkgdir"/usr/lib/go "$subpkgdir"/usr/lib/ mv "$pkgdir"/usr/bin/*gccgo "$subpkgdir"/usr/bin/ mv "$pkgdir"/usr/bin/*go "$subpkgdir"/usr/bin mv "$pkgdir"/usr/bin/*gofmt "$subpkgdir"/usr/bin mv "$pkgdir"/$_gcclibexec/go1 "$subpkgdir"/$_gcclibexec/ mv "$pkgdir"/$_gcclibexec/cgo "$subpkgdir"/$_gcclibexec/ mv "$pkgdir"/$_gcclibexec/buildid "$subpkgdir"/$_gcclibexec/ mv "$pkgdir"/$_gcclibexec/test2json "$subpkgdir"/$_gcclibexec/ mv "$pkgdir"/$_gcclibexec/vet "$subpkgdir"/$_gcclibexec/ mv "$pkgdir"/usr/lib/libgo.a \ "$pkgdir"/usr/lib/libgo.so \ "$pkgdir"/usr/lib/libgobegin.a \ "$pkgdir"/usr/lib/libgolibbegin.a \ "$subpkgdir"/usr/lib/ } libgfortran() { pkgdesc="Fortran runtime library for GCC" depends= mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/lib/libgfortran.so.* "$subpkgdir"/usr/lib/ } libquadmath() { replaces="gcc" pkgdesc="128-bit math library for GCC" depends= mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/lib/libquadmath.so.* "$subpkgdir"/usr/lib/ } gfortran() { pkgdesc="GNU Fortran Compiler" depends="gcc=$_gccrel libgfortran=$_gccrel" $_libquadmath && depends="$depends libquadmath=$_gccrel" replaces="gcc" mkdir -p "$subpkgdir"/$_gcclibexec \ "$subpkgdir"/$_gcclibdir \ "$subpkgdir"/usr/lib \ "$subpkgdir"/usr/bin mv "$pkgdir"/usr/bin/*gfortran "$subpkgdir"/usr/bin/ mv "$pkgdir"/usr/lib/libgfortran.a \ "$pkgdir"/usr/lib/libgfortran.so \ "$subpkgdir"/usr/lib/ if $_libquadmath; then mv "$pkgdir"/usr/lib/libquadmath.a \ "$pkgdir"/usr/lib/libquadmath.so \ "$subpkgdir"/usr/lib/ fi mv "$pkgdir"/$_gcclibdir/finclude "$subpkgdir"/$_gcclibdir/ mv "$pkgdir"/$_gcclibexec/f951 "$subpkgdir"/$_gcclibexec mv "$pkgdir"/usr/lib/libgfortran.spec "$subpkgdir"/$_gcclibdir } libgnat() { pkgdesc="GNU Ada runtime shared libraries" depends= mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/lib/libgna*.so "$subpkgdir"/usr/lib/ } libgnatstatic() { pkgdesc="GNU Ada static libraries" depends= mkdir -p "$subpkgdir"/usr/lib mv "$pkgdir"/usr/lib/libgna*.a "$subpkgdir"/usr/lib/ } gnat() { pkgdesc="Ada support for GCC" depends="gcc=$_gccrel" provides="$pkgname-gnat-bootstrap" [ "$CHOST" = "$CTARGET" ] && depends="$depends libgnat=$_gccrel" mkdir -p "$subpkgdir"/$_gcclibexec \ "$subpkgdir"/$_gcclibdir \ "$subpkgdir"/usr/bin mv "$pkgdir"/$_gcclibexec/*gnat* "$subpkgdir"/$_gcclibexec/ mv "$pkgdir"/$_gcclibdir/*ada* "$subpkgdir"/$_gcclibdir/ mv "$pkgdir"/usr/bin/*gnat* "$subpkgdir"/usr/bin/ } sha512sums="175886a1df08c017c59463233745acfa650fb194e18c940eb1dad0d95ba56921c8fa7a1102f9046b49a3fd90dd9c6100413cbb6318870b05a640aa25588c4ea0 gcc-10.3.1_git20210409.tar.xz c7c4dc20966dc03372a1098af29880f480432539964a0df9c99050953ba8477bec1fda356d9542a18a037739c1e221ef8252ee85e92360811c314e677db393dd 0001-posix_memalign.patch ee0a0f510f260f3d72d9f49a7278256ad3e5091eb4ed85198f3bb415e103d407ec8d7b18c686d1a64d61374674dc82118a0bcc21234096926ab3697b1aa123b6 0002-gcc-poison-system-directories.patch f8f42b7557a39950d097e3163d69f17e1b8ffcfb9cd4137a318e150ebfe7e23b48075aaad02a0d122c0aa5b8b84681219ac185e88dbba724615bc52df2e5e645 0003-Turn-on-Wl-z-relro-z-now-by-default.patch 1f771b738d24e0168e14cebbc917ffda0d9c0a155eb6cd7bb01767649a2bb51253587c8001fa59968f2dfd26dd9aeb606075c357c9c12ee05f5b42c18646b758 0004-Turn-on-D_FORTIFY_SOURCE-2-by-default-for-C-C-ObjC-O.patch 61a7b8d22ee6e03d9ed54ed9c505fdc032035fa31e2eb4c314e832c2a532acdda91cbf69a07a52d2a038c7ae6d8536999e5754058019f38ad531336397daf804 0005-On-linux-targets-pass-as-needed-by-default-to-the-li.patch 7d4e573739859e0f76da7cf38c1dac4eca8d21a875390c45585a418e9d6c0e70022cfc2d930103cde67926b310a4592b11a8fe7e4d1eca514423c08c631fee04 0006-Enable-Wformat-and-Wformat-security-by-default.patch 5c277667aef1b3a9c9537bf7ac44f8e3eab40d2687f4b05a07810778715c4ed4db93a3ace98440fa3212bcc8d77ab33414607d68b36fd5edfded988a4cfe6945 0007-Enable-Wtrampolines-by-default.patch ba8a1521b50cbf68a49dc01a4b2f51f461c2d60e28aa4a5b64ede1de21116e06ba35ff0c54e7c48b36d0904fef47e0a15207b4d2c7248885bca3a011b22abb56 0008-Disable-ssp-on-nostdlib-nodefaultlibs-and-ffreestand.patch 19613149833edecd3e8b949da3e93e3c9187d4c85554f0ea4a19204aa02785f5e2aef8c59d2eca013c630366bd5cf781569c1070f6ac05432154e37324b49ba9 0009-Ensure-that-msgfmt-doesn-t-encounter-problems-during.patch 15d7d73a20a32f8b2ad77c358225cb12d25c6f4161ac826282c9ee2ed6a91ba9536360af0146b9bbbf4704d2f0292576b32f48af4bd8a51c989159140ba92618 0010-Don-t-declare-asprintf-if-defined-as-a-macro.patch c2a353751286da8a53eb8ed4b8c947cb0b25925a4b3de2302df7f015e219868d67a313c557f54b45a4e588a759ea9e04e4c7f46862aacf49d32f0a1284730581 0011-libiberty-copy-PIC-objects-during-build-process.patch 330c4d051d2332908b7b6d63bd852fa7ddfbd50aa51000b62ebd9ad573565b1af29f4912781bc8b8ff45176230240512915eb80d19b7ab5710835459ad0f56e5 0012-libitm-disable-FORTIFY.patch dbb2c022a5d6a374b91e8db74b853162436f44755799c6a0d5b1eff84afa4b79aa953dfd944051a9022c18b80976373451f261cc7c882356172b7ffd2a4facdf 0013-libgcc_s.patch ab229d854e0eafc5ee9bdd828312b90d09f4d288ef0ccc38b6b188f8628f9d2af11e4565a332007c3e86fbc8cdde2c700c33535395c0efdb99753f6954669ab9 0014-nopie.patch 7baee361d199e1070e9f5029f289298e35e4515e465183d723c422d53e113f3c26d806a44220aeb7de595c6f4c3a739c3665dd836395d53c9baae1b85faaf4d2 0015-libffi-use-__linux__-instead-of-__gnu_linux__-for-mu.patch 268aad733c78ad816fb8898721afcaf2a433c9dae450535519c8e974c9018b42d72c9fe8eaef65afe02d96f732bebbe9c346ed6ede147b5b34bca21e56db110b 0016-dlang-update-zlib-binding.patch 5aeeb17a2f1b6a89b6ca9a6fbddd2f3072c3d2144c0dfdb181385ac9a29bbfb904cccfac64d0fe8307763b185578e0669227ab6af17dfd664e9de6929580ebc4 0017-dlang-fix-fcntl-on-mips-add-libucontext-dep.patch eed46a26d0b8d8c84690ef6506087cda25ae8d91ab8968b9d27ba09ebd79b96f8fd013d672f41b2193fcbf5edc1a4f8e39e397eccb877ced506f98d76e6a06e2 0018-ada-fix-shared-linking.patch edd409f50beae54b111002959be6223436d62111c82be80148a83877b03f1d29218bd0dd886583decd394c077957684f4964aecb8e33cab499052e9b17e333ec 0019-build-fix-CXXFLAGS_FOR_BUILD-passing.patch 854b5a3df20180e2e390d57b2a1665b6f390b7e2ec6f84371057c900802dfe1b1cebcc5e9cdae54de5db4335b425681b06cb60c4f51964b32fdf963420c6e491 0020-add-fortify-headers-paths.patch d9bcf5414f3f7d77e0b16cc933db7b7ef20512ac5a3f9d64a80191455394e6348b654c9a9d230ca93af2789a7a334c8a10417c2833046284a9c54b76d8b02931 0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch f04db8f8a1822be5d832ecddfa66bf7faaf7086c55afa8775879625d8a42b986a70602cd7bc76fdc672808cf3932daee61123da9835a1d940cfc0a656706609d 0022-DP-Use-push-state-pop-state-for-gold-as-well-when-li.patch 0a879aa3e9693710de04e5845ae4bfaed36e35288d3c794693f141819b7572efb3cf1bb1f467bb88ec15124dba3450a34496e8b4eca3d562d90a16a6651c6af1 0023-Pure-64-bit-MIPS.patch 46724b82a9d2305a5d11029a0575637593c45e408c353147ac5d1cfc871076679f2b0c4069f1b005cf0a66bc18aa6485db84d367cff3a8bb979d1a1de91f5c03 0024-use-pure-64-bit-configuration-where-appropriate.patch 38939c2cf7de961437ce55a31a49adf43731b780a37e4a0ad3a0d982a9d9207ca8cbd30ce6d8da030e6030ce177fda36b371e1a576ebe6ef17ae9f3195836db9 0025-always-build-libgcc_eh.a.patch 5938442f0d1f562163ac4f30bfa7ac792c185c95fff25f1659a27f7d786bb62f428707d08a2d5601f9159ca0f32b29796a7aafbc180f548000a4c1d0b2af242f 0026-ada-libgnarl-compatibility-for-musl.patch d1129aaa8291d60b872cc114c13235ad409fd8287771f10c717938acc789cadd0886a10855fa70f23096701d5a7c2dff87ee2b2ad6a47d1ddab67ce5abaae15f 0027-ada-musl-support-fixes.patch 6dd92d73ce05a808b0184fbedd41305e229acc0a6879fa52e3b28f483f32b09d21f79a3c23a32574c019b5e58908385187a2ae0b35f6a7fcfa3293478ff48965 0028-gcc-go-Use-_off_t-type-instead-of-_loff_t.patch 47cddc0376a780b6f75adfcc4e2e887abeaabf0f3cb17e3583b798d9e6aa073f773ba11e59214ea8a0054635d37dcd0c054547f0eef4e45c19b04c09d8c1bee6 0029-gcc-go-Don-t-include-sys-user.h.patch af1aa70aafd9bb7416a86c407aa3227809b725748ab0a46a2437b950783545e781c3c974003b3c7e7e480fed07e9f098183737877885583b466bd6f9cebd3996 0030-gcc-go-Fix-ucontext_t-on-PPC64.patch 9cbbaa3a7eb80d6d37ec53c7963fc97dff8e2b868337636371d4258aeaae48e01892e688fcf1638766a3e15dd69da29ab8bd31ec07838c2476f7aaf5603c0eb6 0031-gcc-go-Fix-handling-of-signal-34-on-musl.patch 342498934c658e118bf9a2097e8ce49dfccd56068a4042cda3d3de2dd5c302da7ea30ba6f20d023afd5e7cef189fa6e05f941a0c5f6438bb267932d593d160c5 0032-gcc-go-Use-int64-type-as-offset-argument-for-mmap.patch 7946254594aea17a1795c7be03478bc206c612319107a5b5d50b660b3eb0a896fe2defcc09837366f8c749da655471e22742cae6cd916717adb537de2d9cb0f7 0033-gcc-go-Fix-st_-a-m-c-tim-fields-in-generated-sysinfo.patch 09c8c091163eddec1971d734e3a9c26794f0274ec97f319f469f8ecfeeb9973db51d49d0d0c748e0ccc757230bd6bdff8734e19ee8c33ed7cb5825176121f138 0034-gcc-go-signal-34-is-special-on-musl-libc.patch 2e42058f32c769a6d550c8d5f5fda29c716dec30ff6c9f055152064af7e3368322938831bbaa6a6800910c78798fdb9ac4a24acdd739e42f5c5c008ddc25f0ce 0035-gcc-go-Prefer-_off_t-over-_off64_t.patch 0a9d4958c151ce716fdf0d8b9474bda893ec46a19322805ce71b0d45f102abf07c20832afd58313ff87010e917739d75837e343b8c3668cbbfdd1cdb8ddb1446 0036-gcc-go-undef-SETCONTEXT_CLOBBERS_TLS-in-proc.c.patch 674c828e93aa84cd07894bab320e410bb35ac469d7a1312d623af898b4ba82a1a513ed3037e5f9026e881c136717012af5ff5049a7586d664961e0a02795e094 0037-gcc-go-link-to-libucontext.patch 501e01642183040992ea29d3dc30c918960a83ef386dc6c0f21863b1d4367983bde0ec6c955a8efac5fb52a53ce6dd2670dbfe8b32c72875fcbe6fe0ad92501e 0038-gcc-go-Disable-printing-of-unaccessible-ppc64-struct.patch ca264938dba3ec0086a463127e7f14932a556c6b54cb36638a3d974be83d0d67cf6707e9230dcf4d527962de1c0060a6084b2346f8d374ee5c851828138ded4c 0039-CRuntime_Musl-Support-v1.2.0-for-32-bits.patch 8e0e203f8c66a496151db561e88612f7ce9295a420f8436e43a4ca1ae330bdbe7aeecfe6616f7331cb7913f9cc9ee1f83c94f798515fb91a4037f8b276d10ece 0040-configure-Add-enable-autolink-libatomic-use-in-LINK_.patch"