diff options
Diffstat (limited to 'sys-devel')
-rw-r--r-- | sys-devel/binutils/Manifest | 4 | ||||
-rw-r--r-- | sys-devel/binutils/binutils-2.35.1-r10.ebuild (renamed from sys-devel/binutils/binutils-2.34-r314.ebuild) | 106 | ||||
-rw-r--r-- | sys-devel/binutils/files/binutils-2.33-gcc-10.patch | 39 | ||||
-rw-r--r-- | sys-devel/gcc/Manifest | 4 | ||||
-rw-r--r-- | sys-devel/gcc/files/awk/fixlafiles.awk | 313 | ||||
-rw-r--r-- | sys-devel/gcc/files/awk/fixlafiles.awk-no_gcc_la | 334 | ||||
-rw-r--r-- | sys-devel/gcc/files/c89 | 20 | ||||
-rw-r--r-- | sys-devel/gcc/files/c99 | 21 | ||||
-rw-r--r-- | sys-devel/gcc/files/fix_libtool_files.sh | 66 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-8.3.0-ia64-bootstrap.patch | 41 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-8.3.0-norisc32.patch | 29 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-9.1.0-norisc32.patch | 53 | ||||
-rw-r--r-- | sys-devel/gcc/gcc-10.2.0-r10.ebuild (renamed from sys-devel/gcc/gcc-9.3.0-r314.ebuild) | 13 | ||||
-rw-r--r-- | sys-devel/libtool/libtool-2.4.6-r10.ebuild (renamed from sys-devel/libtool/libtool-2.4.6-r314.ebuild) | 0 |
14 files changed, 61 insertions, 982 deletions
diff --git a/sys-devel/binutils/Manifest b/sys-devel/binutils/Manifest index 7cea1217..49d69a0b 100644 --- a/sys-devel/binutils/Manifest +++ b/sys-devel/binutils/Manifest @@ -1,2 +1,2 @@ -DIST binutils-2.34-patches-1.tar.xz 20388 BLAKE2B 8828505f62259a307de445357320827e7f6bc416a7f4c72140add505f62eef3928c7daec13be158b52c2a7a1d989f539025e4be6ec27ef80ede81477a42c5042 SHA512 951dffcc30ad5706dc48e71995217655c5d96472446ab66a357f19486b57d1868143a9809887eab7ba8c42c33124f8b37d3bab6618388ea8a08b4399d348a645 -DIST binutils-2.34.tar.xz 21637796 BLAKE2B 07dd23916a7d27f71c3f160c8c16abe2bd4fce294c738c665a012a3be6a87dbe8160d0c38740524f9025e01d438e99b2a94bcf9f9f79ee214f5dd033de8aad3d SHA512 2c7976939dcf5e8c5b7374cccd39bfe803b1bec73c6abfa0eb17c24e1942574c6bdb874c66a092a82adc443182eacd8a5a8001c19a76101f0c7ba40c27de0bbd +DIST binutils-2.35.1-patches-2.tar.xz 72236 BLAKE2B 584cb3edbda28c69171ed64e941535f992150d86f25201cadd07b63daaa36bf76b07dc0aa8a4837da17d1672feb47a7b15f83efdeec5409e695965a10142147a SHA512 b704ebe82c4402f058f9c96991a89256a6b369d28f844bf020ed2c77766894d9a2ca0596cd609de7b389fa8cd52bfab674b6deb10ea2096e50aa57921be2083e +DIST binutils-2.35.1.tar.xz 22031720 BLAKE2B d3468da90b75e9b5fa7fbd64d3fdb0a4bc445e4cb7da5ae058f73a1e9d948b3e9438bc9f1b5b351db369b76a25960c9c1f58f828fd2c7646f555de45fa3c052b SHA512 94ff72708403413b70b247f3af4099ebaa882b6659249869f1ed9941a0f1912e313f08357d470f9fd2359e7f5e5b0eb86285e5eaf883fa8187789d6b1bd304eb diff --git a/sys-devel/binutils/binutils-2.34-r314.ebuild b/sys-devel/binutils/binutils-2.35.1-r10.ebuild index 805c709d..57dc7a30 100644 --- a/sys-devel/binutils/binutils-2.34-r314.ebuild +++ b/sys-devel/binutils/binutils-2.35.1-r10.ebuild @@ -8,10 +8,10 @@ inherit eutils libtool flag-o-matic gnuconfig multilib toolchain-funcs DESCRIPTION="Tools necessary to build programs" HOMEPAGE="https://sourceware.org/binutils/" LICENSE="GPL-3+" -IUSE="default-gold doc +gold multitarget +nls +plugins static-libs test" +IUSE="default-gold doc +gold multitarget +nls +plugins static-libs test vanilla" REQUIRED_USE="default-gold? ( gold )" -# Variables that can be set here: +# Variables that can be set here (ignored for live ebuilds) # PATCH_VER - the patchset version # Default: empty, no patching # PATCH_BINUTILS_VER - the binutils version in the patchset name @@ -19,41 +19,22 @@ REQUIRED_USE="default-gold? ( gold )" # PATCH_DEV - Use download URI https://dev.gentoo.org/~{PATCH_DEV}/distfiles/... # for the patchsets -PATCH_VER=1 -PATCH_DEV=slyfox - -case ${PV} in - 9999) - EGIT_REPO_URI="https://sourceware.org/git/binutils-gdb.git" - inherit git-r3 - S=${WORKDIR}/binutils - EGIT_CHECKOUT_DIR=${S} - SLOT=${PV} - ;; - *.9999) - EGIT_REPO_URI="https://sourceware.org/git/binutils-gdb.git" - inherit git-r3 - S=${WORKDIR}/binutils - EGIT_CHECKOUT_DIR=${S} - EGIT_BRANCH=$(ver_cut 1-2) - EGIT_BRANCH="binutils-${EGIT_BRANCH/./_}-branch" - SLOT=$(ver_cut 1-2) - ;; - *) - SRC_URI="mirror://gnu/binutils/binutils-${PV}.tar.xz" - SLOT=$(ver_cut 1-2) - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" - ;; -esac - -# -# The Gentoo patchset -# -PATCH_BINUTILS_VER=${PATCH_BINUTILS_VER:-${PV}} -PATCH_DEV=${PATCH_DEV:-slyfox} - -[[ -z ${PATCH_VER} ]] || SRC_URI="${SRC_URI} - https://dev.gentoo.org/~${PATCH_DEV}/distfiles/binutils-${PATCH_BINUTILS_VER}-patches-${PATCH_VER}.tar.xz" +PATCH_VER=2 +PATCH_DEV=dilfridge + +if [[ ${PV} == 9999* ]]; then + inherit git-r3 + SLOT=${PV} +else + PATCH_BINUTILS_VER=${PATCH_BINUTILS_VER:-${PV}} + PATCH_DEV=${PATCH_DEV:-slyfox} + SRC_URI="mirror://gnu/binutils/binutils-${PV}.tar.xz" + [[ -z ${PATCH_VER} ]] || SRC_URI="${SRC_URI} + https://dev.gentoo.org/~${PATCH_DEV}/distfiles/binutils-${PATCH_BINUTILS_VER}-patches-${PATCH_VER}.tar.xz" + SLOT=$(ver_cut 1-2) + # live ebuild + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" +fi # # The cross-compile logic @@ -84,31 +65,44 @@ BDEPEND=" RESTRICT="!test? ( test )" -PATCHES=( - "${FILESDIR}"/${PN}-2.33-gcc-10.patch -) - MY_BUILDDIR=${WORKDIR}/build src_unpack() { - case ${PV} in - *9999) - git-r3_src_unpack - ;; - *) - ;; - esac - default - mkdir -p "${MY_BUILDDIR}" + if [[ ${PV} == 9999* ]] ; then + EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/toolchain/binutils-patches.git" + EGIT_CHECKOUT_DIR=${WORKDIR}/patches-git + git-r3_src_unpack + mv patches-git/9999 patch || die + + EGIT_REPO_URI="https://sourceware.org/git/binutils-gdb.git" + S=${WORKDIR}/binutils + EGIT_CHECKOUT_DIR=${S} + git-r3_src_unpack + else + unpack ${P}.tar.xz + + cd "${WORKDIR}" || die + unpack binutils-${PATCH_BINUTILS_VER}-patches-${PATCH_VER}.tar.xz + fi + + cd "${WORKDIR}" || die + mkdir -p "${MY_BUILDDIR}" || die } src_prepare() { - if [[ ! -z ${PATCH_VER} ]] ; then - # Use upstream patch to enable development mode - rm -v "${WORKDIR}/patch"/0000-Gentoo-Git-is-development.patch || die + local patchsetname + if [[ ${PV} == 9999* ]] ; then + patchsetname="from git master" + else + patchsetname="${PATCH_BINUTILS_VER}-${PATCH_VER}" + fi - einfo "Applying binutils-${PATCH_BINUTILS_VER} patchset ${PATCH_VER}" - eapply "${WORKDIR}/patch"/*.patch + if [[ ! -z ${PATCH_VER} ]] || [[ ${PV} == 9999* ]] ; then + if ! use vanilla; then + einfo "Applying binutils patchset ${patchsetname}" + eapply "${WORKDIR}/patch" + einfo "Done." + fi fi # This check should probably go somewhere else, like pkg_pretend. @@ -249,6 +243,8 @@ src_configure() { --enable-relro # Newer versions (>=2.24) make this an explicit option. #497268 --enable-install-libiberty + # Available from 2.35 on + --enable-textrel-check=warning --disable-werror --with-bugurl="$(toolchain-binutils_bugurl)" --with-pkgversion="$(toolchain-binutils_pkgversion)" diff --git a/sys-devel/binutils/files/binutils-2.33-gcc-10.patch b/sys-devel/binutils/files/binutils-2.33-gcc-10.patch deleted file mode 100644 index 9e1a999b..00000000 --- a/sys-devel/binutils/files/binutils-2.33-gcc-10.patch +++ /dev/null @@ -1,39 +0,0 @@ -binutils: drop redundant 'program_name' definition - -https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commitdiff;h=0b398d69acde3377dfbbeb8a4cfe87ae8c8562fa ---- a/binutils/coffdump.c -+++ b/binutils/coffdump.c -@@ -456,8 +456,6 @@ coff_dump (struct coff_ofile *ptr) - dump_coff_section (ptr->sections + i); - } - --char * program_name; -- - static void - show_usage (FILE *file, int status) - { ---- a/binutils/srconv.c -+++ b/binutils/srconv.c -@@ -1687,8 +1687,6 @@ prescan (struct coff_ofile *otree) - } - } - --char *program_name; -- - ATTRIBUTE_NORETURN static void - show_usage (FILE *ffile, int status) - { ---- a/binutils/sysdump.c -+++ b/binutils/sysdump.c -@@ -633,8 +633,6 @@ module (void) - } - } - --char *program_name; -- - ATTRIBUTE_NORETURN static void - show_usage (FILE *ffile, int status) - { --- -2.25.0 - diff --git a/sys-devel/gcc/Manifest b/sys-devel/gcc/Manifest index d4de0ae7..a0b6c670 100644 --- a/sys-devel/gcc/Manifest +++ b/sys-devel/gcc/Manifest @@ -1,2 +1,2 @@ -DIST gcc-9.3.0-patches-2.tar.bz2 13230 BLAKE2B d37859c753864be2c4b8c98847f6e51d9c2b1c091304971c31cf680d6f2194131bac3dfd625077117ca452d6f4416e72c7892d19ccc5880eac7a6bcbe5b2a286 SHA512 c5f7c9d4350879e5ca61e97897e37e4cfea56d0c961aad8df09041e6b1fededad0d7ed89387836d0779b947bdfe7696009d5c61c73630c45f09ca1f3ec3b163c -DIST gcc-9.3.0.tar.xz 70533868 BLAKE2B 21efb1432aefad5ed9b9b395e88ef2adfda3a8ea6e3e808cd151da6e66df9fed1bafdc8b8ff055d4b2272ac786d8b7ddc4293bb6b51c55c40a261a0eda0e7cb4 SHA512 4b9e3639eef6e623747a22c37a904b4750c93b6da77cf3958d5047e9b5ebddb7eebe091cc16ca0a227c0ecbd2bf3b984b221130f269a97ee4cc18f9cf6c444de +DIST gcc-10.2.0-patches-4.tar.bz2 23266 BLAKE2B 8173474d3dea27a440b36eb80c89aabb08c37528c3ec2382839c46fc36336aff7f9cdf3dfbc66947df9286b1cfe9f479d615f77d81ab24ff68a3edf5df5b2350 SHA512 17080f358a3f231837de35188ad1a6ae554a4ca6199efae6dacf9b17706937379559d6c8de330b4237480fea6f5cffffc1158c1d5ecc36ec3a7b410546a2684b +DIST gcc-10.2.0.tar.xz 75004144 BLAKE2B 1d79397330354e61439283cac96a109bf78ffc726265442e6d3ec131f107589ab7349d6612836edd8c8512f7bcc1d901a65a0d5d925d28a5bf3ef5cc3f9787ee SHA512 42ae38928bd2e8183af445da34220964eb690b675b1892bbeb7cd5bb62be499011ec9a93397dba5e2fb681afadfc6f2767d03b9035b44ba9be807187ae6dc65e diff --git a/sys-devel/gcc/files/awk/fixlafiles.awk b/sys-devel/gcc/files/awk/fixlafiles.awk deleted file mode 100644 index aa2ecb60..00000000 --- a/sys-devel/gcc/files/awk/fixlafiles.awk +++ /dev/null @@ -1,313 +0,0 @@ -# Copyright 1999-2005 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -# -# Helper functions -# -function printn(string) { - printf("%s", string) -} -function einfo(string) { - printf(" \033[32;01m*\033[0m %s\n", string) -} -function einfon(string) { - printf(" \033[32;01m*\033[0m %s", string) -} -function ewarn(string) { - printf(" \033[33;01m*\033[0m %s\n", string) -} -function ewarnn(string) { - printf(" \033[33;01m*\033[0m %s", string) -} -function eerror(string) { - printf(" \033[31;01m*\033[0m %s\n", string) -} - -# -# assert(condition, errmsg) -# assert that a condition is true. Otherwise exit. -# -function assert(condition, string) { - if (! condition) { - printf("%s:%d: assertion failed: %s\n", - FILENAME, FNR, string) > "/dev/stderr" - _assert_exit = 1 - exit 1 - } -} - -# -# system(command, return) -# wrapper that normalizes return codes ... -# -function dosystem(command, ret) { - ret = 0 - ret = system(command) - if (ret == 0) - return 1 - else - return 0 -} - -BEGIN { - # - # Get our variables from environment - # - OLDVER = ENVIRON["OLDVER"] - OLDCHOST = ENVIRON["OLDCHOST"] - - if (OLDVER == "") { - eerror("Could not get OLDVER!"); - exit 1 - } - - # Setup some sane defaults - LIBCOUNT = 2 - HAVE_GCC34 = 0 - DIRLIST[1] = "/lib" - DIRLIST[2] = "/usr/lib" - - # - # Walk /etc/ld.so.conf to discover all our library paths - # - pipe = "cat /etc/ld.so.conf | sort 2>/dev/null" - while(((pipe) | getline ldsoconf_data) > 0) { - if (ldsoconf_data !~ /^[[:space:]]*#/) { - if (ldsoconf_data == "") continue - - # Remove any trailing comments - sub(/#.*$/, "", ldsoconf_data) - # Remove any trailing spaces - sub(/[[:space:]]+$/, "", ldsoconf_data) - - # If there's more than one path per line, split - # it up as if they were sep lines - split(ldsoconf_data, nodes, /[:,[:space:]]/) - - # Now add the rest from ld.so.conf - for (x in nodes) { - # wtf does this line do ? - sub(/=.*/, "", nodes[x]) - # Prune trailing / - sub(/\/$/, "", nodes[x]) - - if (nodes[x] == "") continue - - # - # Drop the directory if its a child directory of - # one that was already added ... - # For example, if we have: - # /usr/lib /usr/libexec /usr/lib/mozilla /usr/lib/nss - # We really just want to save /usr/lib /usr/libexec - # - CHILD = 0 - for (y in DIRLIST) { - if (nodes[x] ~ "^" DIRLIST[y] "(/|$)") { - CHILD = 1 - break - } - } - if (CHILD) continue - - DIRLIST[++LIBCOUNT] = nodes[x] - } - } - } - close(pipe) - - # - # Get line from gcc's output containing CHOST - # - pipe = "gcc -print-file-name=libgcc.a 2>/dev/null" - if ((!((pipe) | getline TMP_CHOST)) || (TMP_CHOST == "")) { - close(pipe) - - # If we fail to get the CHOST, see if we can get the CHOST - # portage thinks we are using ... - pipe = "/usr/bin/portageq envvar 'CHOST'" - assert(((pipe) | getline CHOST), "(" pipe ") | getline CHOST") - } else { - # Check pre gcc-3.4.x versions - CHOST = gensub("^.+lib/gcc-lib/([^/]+)/[0-9]+.+$", "\\1", 1, TMP_CHOST) - - if (CHOST == TMP_CHOST || CHOST == "") { - # Check gcc-3.4.x or later - CHOST = gensub("^.+lib/gcc/([^/]+)/[0-9]+.+$", "\\1", 1, TMP_CHOST); - - if (CHOST == TMP_CHOST || CHOST == "") - CHOST = "" - else - HAVE_GCC34 = 1 - } - } - close(pipe) - - if (CHOST == "") { - eerror("Could not get gcc's CHOST!") - exit 1 - } - - if (OLDCHOST != "") - if (OLDCHOST == CHOST) - OLDCHOST = "" - - GCCLIBPREFIX_OLD = "/usr/lib/gcc-lib/" - GCCLIBPREFIX_NEW = "/usr/lib/gcc/" - - if (HAVE_GCC34) - GCCLIBPREFIX = GCCLIBPREFIX_NEW - else - GCCLIBPREFIX = GCCLIBPREFIX_OLD - - GCCLIB = GCCLIBPREFIX CHOST - - if (OLDCHOST != "") { - OLDGCCLIB1 = GCCLIBPREFIX_OLD OLDCHOST - OLDGCCLIB2 = GCCLIBPREFIX_NEW OLDCHOST - } - - # Get current gcc's version - pipe = "gcc -dumpversion" - assert(((pipe) | getline NEWVER), "(" pipe ") | getline NEWVER)") - close(pipe) - - if (NEWVER == "") { - eerror("Could not get gcc's version!") - exit 1 - } - - # Nothing to do ? - if ((OLDVER == NEWVER) && (OLDCHOST == "")) - exit 0 - - # - # Ok, now let's scan for the .la files and actually fix them up - # - for (x = 1; x <= LIBCOUNT; x++) { - # Do nothing if the target dir is gcc's internal library path - if (DIRLIST[x] ~ GCCLIBPREFIX_OLD || - DIRLIST[x] ~ GCCLIBPREFIX_NEW) - continue - - einfo(" [" x "/" LIBCOUNT "] Scanning " DIRLIST[x] " ...") - - pipe = "find " DIRLIST[x] "/ -name '*.la' 2>/dev/null" - while (((pipe) | getline la_files) > 0) { - - # Do nothing if the .la file is located in gcc's internal lib path - if (la_files ~ GCCLIBPREFIX_OLD || - la_files ~ GCCLIBPREFIX_NEW) - continue - - CHANGED = 0 - CHOST_CHANGED = 0 - - # See if we need to fix the .la file - while ((getline la_data < (la_files)) > 0) { - if (OLDCHOST != "") { - if ((gsub(OLDGCCLIB1 "[/[:space:]]+", - GCCLIB, la_data) > 0) || - (gsub(OLDGCCLIB2 "[/[:space:]]+", - GCCLIB, la_data) > 0)) { - CHANGED = 1 - CHOST_CHANGED = 1 - } - } - if (OLDVER != NEWVER) { - if ((gsub(GCCLIBPREFIX_OLD CHOST "/" OLDVER "[/[:space:]]*", - GCCLIB "/" NEWVER, la_data) > 0) || - (gsub(GCCLIBPREFIX_NEW CHOST "/" OLDVER "[/[:space:]]*", - GCCLIB "/" NEWVER, la_data) > 0)) - CHANGED = 1 - } - } - close(la_files) - - # Do the actual changes in a second loop, as we can then - # verify that CHOST_CHANGED among things is correct ... - if (CHANGED) { - ewarnn(" FIXING: " la_files " ...") - - if (CHANGED) - printn("[") - - # Clear the temp file (removing rather than '>foo' is better - # out of a security point of view?) - dosystem("rm -f " la_files ".new") - - while ((getline la_data < (la_files)) > 0) { - if (OLDCHOST != "") { - tmpstr = gensub(OLDGCCLIB1 "([/[:space:]]+)", - GCCLIB "\\1", "g", la_data) - tmpstr = gensub(OLDGCCLIB2 "([/[:space:]]+)", - GCCLIB "\\1", "g", tmpstr) - - if (la_data != tmpstr) { - printn("c") - la_data = tmpstr - } - - if (CHOST_CHANGED > 0) { - # We try to be careful about CHOST changes outside - # the gcc library path (meaning we cannot match it - # via /GCCLIBPREFIX CHOST/) ... - - # Catch: - # - # dependency_libs=' -L/usr/CHOST/{bin,lib}' - # - gsub("-L/usr/" OLDCHOST "/", - "-L/usr/" CHOST "/", la_data) - # Catch: - # - # dependency_libs=' -L/usr/lib/gcc-lib/CHOST/VER/../../../../CHOST/lib' - # - la_data = gensub("(" GCCLIB "/[^[:space:]]+)/" OLDCHOST "/", - "\\1/" CHOST "/", "g", la_data) - } - } - - if (OLDVER != NEWVER) { - # Catch: - # - # dependency_libs=' -L/usr/lib/gcc/CHOST/VER' - # - tmpstr = gensub(GCCLIBPREFIX_OLD CHOST "/" OLDVER "([/[:space:]]+)", - GCCLIB "/" NEWVER "\\1", "g", la_data) - tmpstr = gensub(GCCLIBPREFIX_NEW CHOST "/" OLDVER "([/[:space:]]+)", - GCCLIB "/" NEWVER "\\1", "g", tmpstr) - - if (la_data != tmpstr) { - # Catch: - # - # dependency_libs=' -L/usr/lib/gcc-lib/../../CHOST/lib' - # - # in cases where we have gcc34 - tmpstr = gensub(GCCLIBPREFIX_OLD "(../../" CHOST "/lib)", - GCCLIBPREFIX "\\1", "g", tmpstr) - tmpstr = gensub(GCCLIBPREFIX_NEW "(../../" CHOST "/lib)", - GCCLIBPREFIX "\\1", "g", tmpstr) - printn("v") - la_data = tmpstr - } - } - - print la_data >> (la_files ".new") - } - - if (CHANGED) - print "]" - - close(la_files) - close(la_files ".new") - - assert(dosystem("mv -f " la_files ".new " la_files), - "dosystem(\"mv -f " la_files ".new " la_files "\")") - } - } - - close(pipe) - } -} - -# vim:ts=4 diff --git a/sys-devel/gcc/files/awk/fixlafiles.awk-no_gcc_la b/sys-devel/gcc/files/awk/fixlafiles.awk-no_gcc_la deleted file mode 100644 index d95a3c06..00000000 --- a/sys-devel/gcc/files/awk/fixlafiles.awk-no_gcc_la +++ /dev/null @@ -1,334 +0,0 @@ -# Copyright 1999-2005 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -# -# Helper functions -# -function printn(string) { - printf("%s", string) -} -function einfo(string) { - printf(" \033[32;01m*\033[0m %s\n", string) -} -function einfon(string) { - printf(" \033[32;01m*\033[0m %s", string) -} -function ewarn(string) { - printf(" \033[33;01m*\033[0m %s\n", string) -} -function ewarnn(string) { - printf(" \033[33;01m*\033[0m %s", string) -} -function eerror(string) { - printf(" \033[31;01m*\033[0m %s\n", string) -} - -# -# assert(condition, errmsg) -# assert that a condition is true. Otherwise exit. -# -function assert(condition, string) { - if (! condition) { - printf("%s:%d: assertion failed: %s\n", - FILENAME, FNR, string) > "/dev/stderr" - _assert_exit = 1 - exit 1 - } -} - -# -# system(command, return) -# wrapper that normalizes return codes ... -# -function dosystem(command, ret) { - ret = 0 - ret = system(command) - if (ret == 0) - return 1 - else - return 0 -} - -# -# parse_ld_conf(config_file) -# -function parse_ld_conf(conf, pipe, ldsoconf_data, CHILD, y) { - pipe = "cd /etc; cat " conf " | sort 2>/dev/null" - while(((pipe) | getline ldsoconf_data) > 0) { - if (ldsoconf_data ~ /^[[:space:]]*#/) - continue - if (ldsoconf_data == "") - continue - - # Handle the "include" keyword - if (ldsoconf_data ~ /^include /) { - sub(/^include /, "", ldsoconf_data) - parse_ld_conf(ldsoconf_data) - continue - } - - # Remove any trailing comments - sub(/#.*$/, "", ldsoconf_data) - # Remove any trailing spaces - sub(/[[:space:]]+$/, "", ldsoconf_data) - # Eat duplicate slashes - sub(/\/\//, "/", ldsoconf_data) - # Prune trailing / - sub(/\/$/, "", ldsoconf_data) - - # - # Drop the directory if its a child directory of - # one that was already added ... - # For example, if we have: - # /usr/lib /usr/libexec /usr/lib/mozilla /usr/lib/nss - # We really just want to save /usr/lib /usr/libexec - # - CHILD = 0 - for (y in DIRLIST) { - if (ldsoconf_data ~ "^" DIRLIST[y] "(/|$)") { - CHILD = 1 - break - } - } - if (CHILD) continue - - DIRLIST[++LIBCOUNT] = ldsoconf_data - } - close(pipe) -} - -BEGIN { - # - # Get our variables from environment - # - OLDVER = ENVIRON["OLDVER"] - OLDCHOST = ENVIRON["OLDCHOST"] - - if (OLDVER == "") { - eerror("Could not get OLDVER!"); - exit 1 - } - - # Setup some sane defaults - LIBCOUNT = 2 - HAVE_GCC34 = 0 - DIRLIST[1] = "/lib" - DIRLIST[2] = "/usr/lib" - - # - # Walk /etc/ld.so.conf to discover all our library paths - # - parse_ld_conf("/etc/ld.so.conf") - - # - # Get line from gcc's output containing CHOST - # - pipe = "gcc -print-file-name=libgcc.a 2>/dev/null" - if ((!((pipe) | getline TMP_CHOST)) || (TMP_CHOST == "")) { - close(pipe) - - # If we fail to get the CHOST, see if we can get the CHOST - # portage thinks we are using ... - pipe = "/usr/bin/portageq envvar 'CHOST'" - assert(((pipe) | getline CHOST), "(" pipe ") | getline CHOST") - } else { - # Check pre gcc-3.4.x versions - CHOST = gensub("^.+lib/gcc-lib/([^/]+)/[0-9]+.+$", "\\1", 1, TMP_CHOST) - - if (CHOST == TMP_CHOST || CHOST == "") { - # Check gcc-3.4.x or later - CHOST = gensub("^.+lib/gcc/([^/]+)/[0-9]+.+$", "\\1", 1, TMP_CHOST); - - if (CHOST == TMP_CHOST || CHOST == "") - CHOST = "" - else - HAVE_GCC34 = 1 - } - } - close(pipe) - - if (CHOST == "") { - eerror("Could not get gcc's CHOST!") - exit 1 - } - - if (OLDCHOST != "") - if (OLDCHOST == CHOST) - OLDCHOST = "" - - GCCLIBPREFIX_OLD = "/usr/lib/gcc-lib/" - GCCLIBPREFIX_NEW = "/usr/lib/gcc/" - - if (HAVE_GCC34) - GCCLIBPREFIX = GCCLIBPREFIX_NEW - else - GCCLIBPREFIX = GCCLIBPREFIX_OLD - - GCCLIB = GCCLIBPREFIX CHOST - - if (OLDCHOST != "") { - OLDGCCLIB1 = GCCLIBPREFIX_OLD OLDCHOST - OLDGCCLIB2 = GCCLIBPREFIX_NEW OLDCHOST - } - - # Get current gcc's version - pipe = "gcc -dumpversion" - assert(((pipe) | getline NEWVER), "(" pipe ") | getline NEWVER)") - close(pipe) - - if (NEWVER == "") { - eerror("Could not get gcc's version!") - exit 1 - } - - # Nothing to do ? - # NB: Do not check for (OLDVER == NEWVER) anymore, as we might need to - # replace libstdc++.la .... - if ((OLDVER == "") && (OLDCHOST == "")) - exit 0 - - # - # Ok, now let's scan for the .la files and actually fix them up - # - for (x = 1; x <= LIBCOUNT; x++) { - # Do nothing if the target dir is gcc's internal library path - if (DIRLIST[x] ~ GCCLIBPREFIX_OLD || - DIRLIST[x] ~ GCCLIBPREFIX_NEW) - continue - - einfo(" [" x "/" LIBCOUNT "] Scanning " DIRLIST[x] " ...") - - pipe = "find " DIRLIST[x] "/ -name '*.la' 2>/dev/null" - while (((pipe) | getline la_files) > 0) { - - # Do nothing if the .la file is located in gcc's internal lib path - if (la_files ~ GCCLIBPREFIX_OLD || - la_files ~ GCCLIBPREFIX_NEW) - continue - - CHANGED = 0 - CHOST_CHANGED = 0 - - # See if we need to fix the .la file - while ((getline la_data < (la_files)) > 0) { - if (OLDCHOST != "") { - if ((gsub(OLDGCCLIB1 "[/[:space:]]+", - GCCLIB, la_data) > 0) || - (gsub(OLDGCCLIB2 "[/[:space:]]+", - GCCLIB, la_data) > 0)) { - CHANGED = 1 - CHOST_CHANGED = 1 - } - } - if (OLDVER != NEWVER) { - if ((gsub(GCCLIBPREFIX_OLD CHOST "/" OLDVER "[/[:space:]]*", - GCCLIB "/" NEWVER, la_data) > 0) || - (gsub(GCCLIBPREFIX_NEW CHOST "/" OLDVER "[/[:space:]]*", - GCCLIB "/" NEWVER, la_data) > 0)) - CHANGED = 1 - } - # We now check if we have libstdc++.la, as we remove the - # libtool linker scripts for gcc ... - # We do this last, as we only match the new paths - if (gsub(GCCLIB "/" NEWVER "/libstdc\\+\\+\\.la", - "-lstdc++", la_data) > 0) - CHANGED = 1 - } - close(la_files) - - # Do the actual changes in a second loop, as we can then - # verify that CHOST_CHANGED among things is correct ... - if (CHANGED) { - ewarnn(" FIXING: " la_files " ...[") - - # Clear the temp file (removing rather than '>foo' is better - # out of a security point of view?) - dosystem("rm -f " la_files ".new") - - while ((getline la_data < (la_files)) > 0) { - if (OLDCHOST != "") { - tmpstr = gensub(OLDGCCLIB1 "([/[:space:]]+)", - GCCLIB "\\1", "g", la_data) - tmpstr = gensub(OLDGCCLIB2 "([/[:space:]]+)", - GCCLIB "\\1", "g", tmpstr) - - if (la_data != tmpstr) { - printn("c") - la_data = tmpstr - } - - if (CHOST_CHANGED > 0) { - # We try to be careful about CHOST changes outside - # the gcc library path (meaning we cannot match it - # via /GCCLIBPREFIX CHOST/) ... - - # Catch: - # - # dependency_libs=' -L/usr/CHOST/{bin,lib}' - # - gsub("-L/usr/" OLDCHOST "/", - "-L/usr/" CHOST "/", la_data) - # Catch: - # - # dependency_libs=' -L/usr/lib/gcc-lib/CHOST/VER/../../../../CHOST/lib' - # - la_data = gensub("(" GCCLIB "/[^[:space:]]+)/" OLDCHOST "/", - "\\1/" CHOST "/", "g", la_data) - } - } - - if (OLDVER != NEWVER) { - # Catch: - # - # dependency_libs=' -L/usr/lib/gcc/CHOST/VER' - # - tmpstr = gensub(GCCLIBPREFIX_OLD CHOST "/" OLDVER "([/[:space:]]+)", - GCCLIB "/" NEWVER "\\1", "g", la_data) - tmpstr = gensub(GCCLIBPREFIX_NEW CHOST "/" OLDVER "([/[:space:]]+)", - GCCLIB "/" NEWVER "\\1", "g", tmpstr) - - if (la_data != tmpstr) { - # Catch: - # - # dependency_libs=' -L/usr/lib/gcc-lib/../../CHOST/lib' - # - # in cases where we have gcc34 - tmpstr = gensub(GCCLIBPREFIX_OLD "(../../" CHOST "/lib)", - GCCLIBPREFIX "\\1", "g", tmpstr) - tmpstr = gensub(GCCLIBPREFIX_NEW "(../../" CHOST "/lib)", - GCCLIBPREFIX "\\1", "g", tmpstr) - printn("v") - la_data = tmpstr - } - } - - # We now check if we have libstdc++.la, as we remove the - # libtool linker scripts for gcc and any referencese in any - # libtool linker scripts. - # We do this last, as we only match the new paths - tmpstr = gensub(GCCLIB "/" NEWVER "/libstdc\\+\\+\\.la", - "-lstdc++", "g", la_data); - if (la_data != tmpstr) { - printn("l") - la_data = tmpstr - } - - print la_data >> (la_files ".new") - } - - if (CHANGED) - print "]" - - close(la_files) - close(la_files ".new") - - assert(dosystem("mv -f " la_files ".new " la_files), - "dosystem(\"mv -f " la_files ".new " la_files "\")") - } - } - - close(pipe) - } -} - -# vim:ts=4 diff --git a/sys-devel/gcc/files/c89 b/sys-devel/gcc/files/c89 deleted file mode 100644 index cee0325f..00000000 --- a/sys-devel/gcc/files/c89 +++ /dev/null @@ -1,20 +0,0 @@ -#! /bin/sh - -# Call the appropriate C compiler with options to accept ANSI/ISO C -# The following options are the same (as of gcc-2.95): -# -ansi -# -std=c89 -# -std=iso9899:1990 - -for i; do - case "$i" in - -ansi|-std=c89|-std=iso9899:1990) - ;; - -std=*) - echo >&2 "`basename $0` called with non ANSI/ISO C90 option $i" - exit 1 - ;; - esac -done - -exec gcc -std=c89 -pedantic -U_FORTIFY_SOURCE "$@" diff --git a/sys-devel/gcc/files/c99 b/sys-devel/gcc/files/c99 deleted file mode 100644 index c9542095..00000000 --- a/sys-devel/gcc/files/c99 +++ /dev/null @@ -1,21 +0,0 @@ -#! /bin/sh - -# Call the appropriate C compiler with options to accept ANSI/ISO C -# The following options are the same (as of gcc-3.3): -# -std=c99 -# -std=c9x -# -std=iso9899:1999 -# -std=iso9899:199x - -for i; do - case "$i" in - -std=c9[9x]|-std=iso9899:199[9x]) - ;; - -ansi|-std=*) - echo >&2 "`basename $0` called with non ANSI/ISO C99 option $i" - exit 1 - ;; - esac -done - -exec gcc -std=c99 -pedantic -U_FORTIFY_SOURCE ${1+"$@"} diff --git a/sys-devel/gcc/files/fix_libtool_files.sh b/sys-devel/gcc/files/fix_libtool_files.sh deleted file mode 100644 index af085e1e..00000000 --- a/sys-devel/gcc/files/fix_libtool_files.sh +++ /dev/null @@ -1,66 +0,0 @@ -#!/bin/sh -# Copyright 1999-2017 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -usage() { -cat << "USAGE_END" -Usage: fix_libtool_files.sh <old-gcc-version> [--oldarch <old-CHOST>] - - Where <old-gcc-version> is the version number of the - previous gcc version. For example, if you updated to - gcc-3.2.1, and you had gcc-3.2 installed, run: - - # fix_libtool_files.sh 3.2 - - If you updated to gcc-3.2.3, and the old CHOST was i586-pc-linux-gnu - but you now have CHOST as i686-pc-linux-gnu, run: - - # fix_libtool_files.sh 3.2 --oldarch i586-pc-linux-gnu - - Note that if only the CHOST and not the version changed, you can run - it with the current version and the '--oldarch <old-CHOST>' arguments, - and it will do the expected: - - # fix_libtool_files.sh `gcc -dumpversion` --oldarch i586-pc-linux-gnu - -USAGE_END - exit 1 -} - -case $2 in ---oldarch) [ $# -ne 3 ] && usage ;; -*) [ $# -ne 1 ] && usage ;; -esac - -ARGV1=$1 -ARGV2=$2 -ARGV3=$3 - -. /etc/profile || exit 1 - -if [ ${EUID:-0} -ne 0 -a "${EPREFIX}" = '' ] ; then - echo "${0##*/}: Must be root." - exit 1 -fi - -# make sure the files come out sane -umask 0022 - -OLDCHOST= -[ "${ARGV2}" = "--oldarch" ] && OLDCHOST=${ARGV3} - -AWKDIR="/usr/share/gcc-data" - -if [ ! -r "${AWKDIR}/fixlafiles.awk" ] ; then - echo "${0##*/}: ${AWKDIR}/fixlafiles.awk does not exist!" - exit 1 -fi - -OLDVER=${ARGV1} - -export OLDVER OLDCHOST - -echo "Scanning libtool files for hardcoded gcc library paths..." -exec gawk -f "${AWKDIR}/fixlafiles.awk" - -# vim:ts=4 diff --git a/sys-devel/gcc/files/gcc-8.3.0-ia64-bootstrap.patch b/sys-devel/gcc/files/gcc-8.3.0-ia64-bootstrap.patch deleted file mode 100644 index 0a0a25b5..00000000 --- a/sys-devel/gcc/files/gcc-8.3.0-ia64-bootstrap.patch +++ /dev/null @@ -1,41 +0,0 @@ -https://gcc.gnu.org/PR87338 - -From 1cc1dc32fcf6b47db4e6d28f55de343713f824a4 Mon Sep 17 00:00:00 2001 -From: James Clarke <jrtc27@jrtc27.com> -Date: Thu, 25 Apr 2019 15:58:55 +0200 -Subject: [PATCH] PR bootstrap/87338: Fix ia64 bootstrap comparison regression - in r257511 -To: gcc-patches@gcc.gnu.org - -By using ASM_OUTPUT_LABEL, r257511 forced the assembler to start a new -bundle when emitting an inline entry label on. Instead, use -ASM_OUTPUT_DEBUG_LABEL like for the block begin and end labels so tags are -emitted rather than labels. - -gcc/ - PR bootstrap/87338 - * dwarf2out.c (dwarf2out_inline_entry): Use ASM_OUTPUT_DEBUG_LABEL - instead of ASM_GENERATE_INTERNAL_LABEL and ASM_OUTPUT_LABEL. ---- - gcc/dwarf2out.c | 7 ++----- - 1 file changed, 2 insertions(+), 5 deletions(-) - ---- a/gcc/dwarf2out.c -+++ b/gcc/dwarf2out.c -@@ -27670,11 +27670,8 @@ dwarf2out_inline_entry (tree block) - if (cur_line_info_table) - ied->view = cur_line_info_table->view; - -- char label[MAX_ARTIFICIAL_LABEL_BYTES]; -- -- ASM_GENERATE_INTERNAL_LABEL (label, BLOCK_INLINE_ENTRY_LABEL, -- BLOCK_NUMBER (block)); -- ASM_OUTPUT_LABEL (asm_out_file, label); -+ ASM_OUTPUT_DEBUG_LABEL (asm_out_file, BLOCK_INLINE_ENTRY_LABEL, -+ BLOCK_NUMBER (block)); - } - - /* Called from finalize_size_functions for size functions so that their body --- -1.8.5.3 - diff --git a/sys-devel/gcc/files/gcc-8.3.0-norisc32.patch b/sys-devel/gcc/files/gcc-8.3.0-norisc32.patch deleted file mode 100644 index 19f4f568..00000000 --- a/sys-devel/gcc/files/gcc-8.3.0-norisc32.patch +++ /dev/null @@ -1,29 +0,0 @@ -https://gcc.gnu.org/PR90419 - -diff -ruN gcc-8.3.0.orig/gcc/config/riscv/t-linux-multilib gcc-8.3.0/gcc/config/riscv/t-linux-multilib ---- gcc-8.3.0.orig/gcc/config/riscv/t-linux-multilib 2017-02-06 22:38:37.000000000 +0100 -+++ gcc-8.3.0/gcc/config/riscv/t-linux-multilib 2019-04-28 16:37:44.377841943 +0200 -@@ -20,21 +20,9 @@ - ilp32d \ - lp64 \ - lp64d --MULTILIB_REQUIRED = march=rv32imac/mabi=ilp32 \ --march=rv32imafdc/mabi=ilp32d \ --march=rv64imac/mabi=lp64 \ -+MULTILIB_REQUIRED = march=rv64imac/mabi=lp64 \ - march=rv64imafdc/mabi=lp64d --MULTILIB_REUSE = march.rv32imac/mabi.ilp32=march.rv32ima/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32imaf/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32imafd/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32imafc/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32imafdc/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32g/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32gc/mabi.ilp32 \ --march.rv32imafdc/mabi.ilp32d=march.rv32imafd/mabi.ilp32d \ --march.rv32imafdc/mabi.ilp32d=march.rv32gc/mabi.ilp32d \ --march.rv32imafdc/mabi.ilp32d=march.rv32g/mabi.ilp32d \ --march.rv64imac/mabi.lp64=march.rv64ima/mabi.lp64 \ -+MULTILIB_REUSE = march.rv64imac/mabi.lp64=march.rv64ima/mabi.lp64 \ - march.rv64imac/mabi.lp64=march.rv64imaf/mabi.lp64 \ - march.rv64imac/mabi.lp64=march.rv64imafd/mabi.lp64 \ - march.rv64imac/mabi.lp64=march.rv64imafc/mabi.lp64 \ diff --git a/sys-devel/gcc/files/gcc-9.1.0-norisc32.patch b/sys-devel/gcc/files/gcc-9.1.0-norisc32.patch deleted file mode 100644 index ad0128a0..00000000 --- a/sys-devel/gcc/files/gcc-9.1.0-norisc32.patch +++ /dev/null @@ -1,53 +0,0 @@ -Autogenerated patch disabling the 32bit RISCV support -See https://gcc.gnu.org/PR90419 - -diff -ruN gcc-9.1.0.orig/gcc/config/riscv/t-linux-multilib gcc-9.1.0/gcc/config/riscv/t-linux-multilib ---- gcc-9.1.0.orig/gcc/config/riscv/t-linux-multilib 2017-02-06 22:38:37.000000000 +0100 -+++ gcc-9.1.0/gcc/config/riscv/t-linux-multilib 2019-05-18 23:04:54.849400774 +0200 -@@ -1,40 +1,18 @@ - # This file was generated by multilib-generator with the command: --# ./multilib-generator rv32imac-ilp32-rv32ima,rv32imaf,rv32imafd,rv32imafc,rv32imafdc- rv32imafdc-ilp32d-rv32imafd- rv64imac-lp64-rv64ima,rv64imaf,rv64imafd,rv64imafc,rv64imafdc- rv64imafdc-lp64d-rv64imafd- --MULTILIB_OPTIONS = march=rv32imac/march=rv32ima/march=rv32imaf/march=rv32imafd/march=rv32imafc/march=rv32imafdc/march=rv32g/march=rv32gc/march=rv64imac/march=rv64ima/march=rv64imaf/march=rv64imafd/march=rv64imafc/march=rv64imafdc/march=rv64g/march=rv64gc mabi=ilp32/mabi=ilp32d/mabi=lp64/mabi=lp64d --MULTILIB_DIRNAMES = rv32imac \ --rv32ima \ --rv32imaf \ --rv32imafd \ --rv32imafc \ --rv32imafdc \ --rv32g \ --rv32gc \ --rv64imac \ -+# ./multilib-generator rv64imac-lp64-rv64ima,rv64imaf,rv64imafd,rv64imafc,rv64imafdc- rv64imafdc-lp64d-rv64imafd- -+MULTILIB_OPTIONS = march=rv64imac/march=rv64ima/march=rv64imaf/march=rv64imafd/march=rv64imafc/march=rv64imafdc/march=rv64g/march=rv64gc mabi=lp64/mabi=lp64d -+MULTILIB_DIRNAMES = rv64imac \ - rv64ima \ - rv64imaf \ - rv64imafd \ - rv64imafc \ - rv64imafdc \ - rv64g \ --rv64gc ilp32 \ --ilp32d \ --lp64 \ -+rv64gc lp64 \ - lp64d --MULTILIB_REQUIRED = march=rv32imac/mabi=ilp32 \ --march=rv32imafdc/mabi=ilp32d \ --march=rv64imac/mabi=lp64 \ -+MULTILIB_REQUIRED = march=rv64imac/mabi=lp64 \ - march=rv64imafdc/mabi=lp64d --MULTILIB_REUSE = march.rv32imac/mabi.ilp32=march.rv32ima/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32imaf/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32imafd/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32imafc/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32imafdc/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32g/mabi.ilp32 \ --march.rv32imac/mabi.ilp32=march.rv32gc/mabi.ilp32 \ --march.rv32imafdc/mabi.ilp32d=march.rv32imafd/mabi.ilp32d \ --march.rv32imafdc/mabi.ilp32d=march.rv32gc/mabi.ilp32d \ --march.rv32imafdc/mabi.ilp32d=march.rv32g/mabi.ilp32d \ --march.rv64imac/mabi.lp64=march.rv64ima/mabi.lp64 \ -+MULTILIB_REUSE = march.rv64imac/mabi.lp64=march.rv64ima/mabi.lp64 \ - march.rv64imac/mabi.lp64=march.rv64imaf/mabi.lp64 \ - march.rv64imac/mabi.lp64=march.rv64imafd/mabi.lp64 \ - march.rv64imac/mabi.lp64=march.rv64imafc/mabi.lp64 \ diff --git a/sys-devel/gcc/gcc-9.3.0-r314.ebuild b/sys-devel/gcc/gcc-10.2.0-r10.ebuild index 257d96bf..9bda9722 100644 --- a/sys-devel/gcc/gcc-9.3.0-r314.ebuild +++ b/sys-devel/gcc/gcc-10.2.0-r10.ebuild @@ -3,17 +3,16 @@ EAPI="7" -PATCH_VER="2" +PATCH_VER="4" inherit toolchain KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" RDEPEND="" -DEPEND="${RDEPEND} - elibc_glibc? ( >=sys-libs/glibc-2.13 ) - >=${CATEGORY}/binutils-2.20" +BDEPEND="${CATEGORY}/binutils" -if [[ ${CATEGORY} != cross-* ]] ; then - PDEPEND="${PDEPEND} elibc_glibc? ( >=sys-libs/glibc-2.13 )" -fi +src_prepare() { + has_version '>=sys-libs/glibc-2.32-r1' && rm -v "${WORKDIR}/patch/23_all_disable-riscv32-ABIs.patch" + toolchain_src_prepare +} diff --git a/sys-devel/libtool/libtool-2.4.6-r314.ebuild b/sys-devel/libtool/libtool-2.4.6-r10.ebuild index 1e876837..1e876837 100644 --- a/sys-devel/libtool/libtool-2.4.6-r314.ebuild +++ b/sys-devel/libtool/libtool-2.4.6-r10.ebuild |