diff options
Diffstat (limited to 'sys-devel/gcc/files')
-rw-r--r-- | sys-devel/gcc/files/awk/fixlafiles.awk | 314 | ||||
-rw-r--r-- | sys-devel/gcc/files/awk/fixlafiles.awk-no_gcc_la | 335 | ||||
-rwxr-xr-x | sys-devel/gcc/files/c89 | 20 | ||||
-rwxr-xr-x | sys-devel/gcc/files/c99 | 21 | ||||
-rw-r--r-- | sys-devel/gcc/files/fix_libtool_files.sh | 68 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-4.7.3-musl-linker-path.patch | 61 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-4.7.3-powerpc-libc-stack-end.patch | 171 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-4.7.4-secure-plt.patch | 51 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-4.8.3-musl-fix-libc5-assumption.patch | 11 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-4.8.3-musl-linker-path.patch | 70 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-4.8.3-musl-res_state.patch | 12 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-4.8.3-secure-plt.patch | 43 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-configure-LANG.patch | 64 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-configure-texinfo.patch | 16 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-spec-env-r1.patch | 87 | ||||
-rw-r--r-- | sys-devel/gcc/files/gcc-spec-env.patch | 42 | ||||
-rw-r--r-- | sys-devel/gcc/files/mkinfodir | 233 |
17 files changed, 0 insertions, 1619 deletions
diff --git a/sys-devel/gcc/files/awk/fixlafiles.awk b/sys-devel/gcc/files/awk/fixlafiles.awk deleted file mode 100644 index ffade966..00000000 --- a/sys-devel/gcc/files/awk/fixlafiles.awk +++ /dev/null @@ -1,314 +0,0 @@ -# Copyright 1999-2005 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc/files/awk/fixlafiles.awk,v 1.15 2008/02/19 05:47:29 vapier Exp $ - -# -# 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 346bd16f..00000000 --- a/sys-devel/gcc/files/awk/fixlafiles.awk-no_gcc_la +++ /dev/null @@ -1,335 +0,0 @@ -# Copyright 1999-2005 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc/files/awk/fixlafiles.awk-no_gcc_la,v 1.4 2010/03/19 23:53:07 vapier Exp $ - -# -# 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 100755 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 100755 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 c55250b6..00000000 --- a/sys-devel/gcc/files/fix_libtool_files.sh +++ /dev/null @@ -1,68 +0,0 @@ -#!/bin/sh -# Copyright 1999-2012 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-devel/gcc/files/fix_libtool_files.sh,v 1.16 2012/05/18 21:28:56 vapier Exp $ - -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 -. /etc/init.d/functions.sh || exit 1 - -if [ ${EUID:-0} -ne 0 ] ; then - eerror "${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 - eerror "${0##*/}: ${AWKDIR}/fixlafiles.awk does not exist!" - exit 1 -fi - -OLDVER=${ARGV1} - -export OLDVER OLDCHOST - -einfo "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-4.7.3-musl-linker-path.patch b/sys-devel/gcc/files/gcc-4.7.3-musl-linker-path.patch deleted file mode 100644 index d4540534..00000000 --- a/sys-devel/gcc/files/gcc-4.7.3-musl-linker-path.patch +++ /dev/null @@ -1,61 +0,0 @@ -diff -Naur gcc-4.7.3.orig/gcc/config/arm/linux-eabi.h gcc-4.7.3/gcc/config/arm/linux-eabi.h ---- gcc-4.7.3.orig/gcc/config/arm/linux-eabi.h 2014-04-06 14:15:03.000000000 +0000 -+++ gcc-4.7.3/gcc/config/arm/linux-eabi.h 2014-04-06 12:12:42.000000000 +0000 -@@ -69,8 +69,8 @@ - GLIBC_DYNAMIC_LINKER_DEFAULT and TARGET_DEFAULT_FLOAT_ABI. */ - - #undef GLIBC_DYNAMIC_LINKER --#define GLIBC_DYNAMIC_LINKER_SOFT_FLOAT "/lib/ld-linux.so.3" --#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT "/lib/ld-linux-armhf.so.3" -+#define GLIBC_DYNAMIC_LINKER_SOFT_FLOAT "/lib/ld-musl-arm.so.1" -+#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT "/lib/ld-musl-armhf.so.1" - #define GLIBC_DYNAMIC_LINKER_DEFAULT GLIBC_DYNAMIC_LINKER_SOFT_FLOAT - - #define GLIBC_DYNAMIC_LINKER \ -diff -Naur gcc-4.7.3.orig/gcc/config/i386/linux64.h gcc-4.7.3/gcc/config/i386/linux64.h ---- gcc-4.7.3.orig/gcc/config/i386/linux64.h 2014-04-06 14:15:03.000000000 +0000 -+++ gcc-4.7.3/gcc/config/i386/linux64.h 2014-04-06 12:12:42.000000000 +0000 -@@ -28,6 +28,6 @@ - #define GNU_USER_LINK_EMULATION64 "elf_x86_64" - #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64" - --#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2" --#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2" -+#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-musl-i386.so.1" -+#define GLIBC_DYNAMIC_LINKER64 "/lib/ld-musl-x86_64.so.1" - #define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2" -diff -Naur gcc-4.7.3.orig/gcc/config/mips/linux.h gcc-4.7.3/gcc/config/mips/linux.h ---- gcc-4.7.3.orig/gcc/config/mips/linux.h 2011-07-19 18:00:27.000000000 +0000 -+++ gcc-4.7.3/gcc/config/mips/linux.h 2014-04-06 14:12:48.000000000 +0000 -@@ -18,4 +18,4 @@ - along with GCC; see the file COPYING3. If not see - <http://www.gnu.org/licenses/>. */ - --#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1" -+#define GLIBC_DYNAMIC_LINKER "/lib/ld-musl-mipsel.so.1" -diff -Naur gcc-4.7.3.orig/gcc/config/rs6000/linux64.h gcc-4.7.3/gcc/config/rs6000/linux64.h ---- gcc-4.7.3/gcc/config/rs6000/linux64.h 2014-10-11 18:59:07.479279989 -0200 -+++ gcc-4.7.3/gcc/config/rs6000/linux64.h 2014-10-11 18:59:45.777801191 -0200 -@@ -358,8 +358,8 @@ - #undef LINK_OS_DEFAULT_SPEC - #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)" - --#define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1" --#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld64.so.1" -+#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-musl-powerpc.so.1" -+#define GLIBC_DYNAMIC_LINKER64 "/lib/ld-musl-powerpc64.so.1" - #define UCLIBC_DYNAMIC_LINKER32 "/lib/ld-uClibc.so.0" - #define UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0" - #if DEFAULT_LIBC == LIBC_UCLIBC -diff -Naur gcc-4.7.3/gcc/config/rs6000/sysv4.h gcc-4.7.3/gcc/config/rs6000/sysv4.h ---- gcc-4.7.3/gcc/config/rs6000/sysv4.h 2014-10-11 19:00:03.079584889 -0200 -+++ gcc-4.7.3/gcc/config/rs6000/sysv4.h 2014-10-11 19:00:28.476267387 -0200 -@@ -802,7 +802,7 @@ - - #define LINK_START_LINUX_SPEC "" - --#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1" -+#define GLIBC_DYNAMIC_LINKER "/lib/ld-musl-powerpc.so.1" - #define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" - #if DEFAULT_LIBC == LIBC_UCLIBC - #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}" diff --git a/sys-devel/gcc/files/gcc-4.7.3-powerpc-libc-stack-end.patch b/sys-devel/gcc/files/gcc-4.7.3-powerpc-libc-stack-end.patch deleted file mode 100644 index 91c1b347..00000000 --- a/sys-devel/gcc/files/gcc-4.7.3-powerpc-libc-stack-end.patch +++ /dev/null @@ -1,171 +0,0 @@ -From: amodra <amodra@138bc75d-0d04-0410-961f-82ee72b054a4> -Date: Fri, 15 Feb 2013 13:53:40 +0000 (+0000) -Subject: PR target/55431 -X-Git-Tag: gcc-4_8_0-release~416 -X-Git-Url: http://repo.or.cz/w/official-gcc.git/commitdiff_plain/2a0bfd56d1b6a8ece8fb852691ea32713c7891b3 - - PR target/55431 - * config/rs6000/linux-unwind.h (ppc_linux_aux_vector): Delete. - (ppc_fallback_frame_state): Always set up save locations for fp - and altivec. Don't bother with non-callee-saved regs, r0-r13 - except for r2 on ppc64, fr0-fr13, v0-v19, vscr. - - - -git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@196077 138bc75d-0d04-0410-961f-82ee72b054a4 -diff --git a/libgcc/config/rs6000/linux-unwind.h b/libgcc/config/rs6000/linux-unwind.h -index 3a2da6e..c9273c4 100644 ---- a/libgcc/config/rs6000/linux-unwind.h -+++ b/libgcc/config/rs6000/linux-unwind.h -@@ -26,7 +26,6 @@ - #define R_CR2 70 - #define R_VR0 77 - #define R_VRSAVE 109 --#define R_VSCR 110 - - struct gcc_vregs - { -@@ -175,38 +174,6 @@ get_regs (struct _Unwind_Context *context) - } - #endif - --/* Find an entry in the process auxiliary vector. The canonical way to -- test for VMX is to look at AT_HWCAP. */ -- --static long --ppc_linux_aux_vector (long which) --{ -- /* __libc_stack_end holds the original stack passed to a process. */ -- extern long *__libc_stack_end; -- long argc; -- char **argv; -- char **envp; -- struct auxv -- { -- long a_type; -- long a_val; -- } *auxp; -- -- /* The Linux kernel puts argc first on the stack. */ -- argc = __libc_stack_end[0]; -- /* Followed by argv, NULL terminated. */ -- argv = (char **) __libc_stack_end + 1; -- /* Followed by environment string pointers, NULL terminated. */ -- envp = argv + argc + 1; -- while (*envp++) -- continue; -- /* Followed by the aux vector, zero terminated. */ -- for (auxp = (struct auxv *) envp; auxp->a_type != 0; ++auxp) -- if (auxp->a_type == which) -- return auxp->a_val; -- return 0; --} -- - /* Do code reading to identify a signal frame, and set the frame - state data appropriately. See unwind-dw2.c for the structs. */ - -@@ -216,8 +183,8 @@ static _Unwind_Reason_Code - ppc_fallback_frame_state (struct _Unwind_Context *context, - _Unwind_FrameState *fs) - { -- static long hwcap = 0; - struct gcc_regs *regs = get_regs (context); -+ struct gcc_vregs *vregs; - long new_cfa; - int i; - -@@ -229,12 +196,15 @@ ppc_fallback_frame_state (struct _Unwind_Context *context, - fs->regs.cfa_reg = STACK_POINTER_REGNUM; - fs->regs.cfa_offset = new_cfa - (long) context->cfa; - -- for (i = 0; i < 32; i++) -- if (i != STACK_POINTER_REGNUM) -- { -- fs->regs.reg[i].how = REG_SAVED_OFFSET; -- fs->regs.reg[i].loc.offset = (long) ®s->gpr[i] - new_cfa; -- } -+#ifdef __powerpc64__ -+ fs->regs.reg[2].how = REG_SAVED_OFFSET; -+ fs->regs.reg[2].loc.offset = (long) ®s->gpr[2] - new_cfa; -+#endif -+ for (i = 14; i < 32; i++) -+ { -+ fs->regs.reg[i].how = REG_SAVED_OFFSET; -+ fs->regs.reg[i].loc.offset = (long) ®s->gpr[i] - new_cfa; -+ } - - fs->regs.reg[R_CR2].how = REG_SAVED_OFFSET; - /* CR? regs are always 32-bit and PPC is big-endian, so in 64-bit -@@ -250,57 +220,35 @@ ppc_fallback_frame_state (struct _Unwind_Context *context, - fs->retaddr_column = ARG_POINTER_REGNUM; - fs->signal_frame = 1; - -- if (hwcap == 0) -+ /* If we have a FPU... */ -+ for (i = 14; i < 32; i++) - { -- hwcap = ppc_linux_aux_vector (16); -- /* These will already be set if we found AT_HWCAP. A nonzero -- value stops us looking again if for some reason we couldn't -- find AT_HWCAP. */ --#ifdef __powerpc64__ -- hwcap |= 0xc0000000; --#else -- hwcap |= 0x80000000; --#endif -+ fs->regs.reg[i + 32].how = REG_SAVED_OFFSET; -+ fs->regs.reg[i + 32].loc.offset = (long) ®s->fpr[i] - new_cfa; - } - -- /* If we have a FPU... */ -- if (hwcap & 0x08000000) -- for (i = 0; i < 32; i++) -- { -- fs->regs.reg[i + 32].how = REG_SAVED_OFFSET; -- fs->regs.reg[i + 32].loc.offset = (long) ®s->fpr[i] - new_cfa; -- } -- - /* If we have a VMX unit... */ -- if (hwcap & 0x10000000) -- { -- struct gcc_vregs *vregs; - #ifdef __powerpc64__ -- vregs = regs->vp; -+ vregs = regs->vp; - #else -- vregs = ®s->vregs; -+ vregs = ®s->vregs; - #endif -- if (regs->msr & (1 << 25)) -+ if (regs->msr & (1 << 25)) -+ { -+ for (i = 20; i < 32; i++) - { -- for (i = 0; i < 32; i++) -- { -- fs->regs.reg[i + R_VR0].how = REG_SAVED_OFFSET; -- fs->regs.reg[i + R_VR0].loc.offset -- = (long) &vregs->vr[i] - new_cfa; -- } -- -- fs->regs.reg[R_VSCR].how = REG_SAVED_OFFSET; -- fs->regs.reg[R_VSCR].loc.offset = (long) &vregs->vscr - new_cfa; -+ fs->regs.reg[i + R_VR0].how = REG_SAVED_OFFSET; -+ fs->regs.reg[i + R_VR0].loc.offset = (long) &vregs->vr[i] - new_cfa; - } -- -- fs->regs.reg[R_VRSAVE].how = REG_SAVED_OFFSET; -- fs->regs.reg[R_VRSAVE].loc.offset = (long) &vregs->vsave - new_cfa; - } - -+ fs->regs.reg[R_VRSAVE].how = REG_SAVED_OFFSET; -+ fs->regs.reg[R_VRSAVE].loc.offset = (long) &vregs->vsave - new_cfa; -+ - /* If we have SPE register high-parts... we check at compile-time to - avoid expanding the code for all other PowerPC. */ - #ifdef __SPE__ -- for (i = 0; i < 32; i++) -+ for (i = 14; i < 32; i++) - { - fs->regs.reg[i + FIRST_PSEUDO_REGISTER - 1].how = REG_SAVED_OFFSET; - fs->regs.reg[i + FIRST_PSEUDO_REGISTER - 1].loc.offset diff --git a/sys-devel/gcc/files/gcc-4.7.4-secure-plt.patch b/sys-devel/gcc/files/gcc-4.7.4-secure-plt.patch deleted file mode 100644 index 1cc395f2..00000000 --- a/sys-devel/gcc/files/gcc-4.7.4-secure-plt.patch +++ /dev/null @@ -1,51 +0,0 @@ -adapted from musl-cross gcc-patches -diff -ur a/gcc/config.gcc b/gcc/config.gcc ---- a/gcc/config.gcc 2013-10-03 02:52:23.000000000 -0200 -+++ b/gcc/config.gcc 2015-05-03 22:05:10.855150177 -0200 -@@ -2091,6 +2091,10 @@ - powerpc*-*-linux*paired*) - tm_file="${tm_file} rs6000/750cl.h" ;; - esac -+ case ${target} in -+ *-linux*-musl*) -+ enable_secureplt=yes ;; -+ esac - if test x${enable_secureplt} = xyes; then - tm_file="rs6000/secureplt.h ${tm_file}" - fi -diff -r 6097333f2ab4 gcc/config/rs6000/secureplt.h ---- a/gcc/config/rs6000/secureplt.h Tue May 20 11:06:08 2014 -0400 -+++ b/gcc/config/rs6000/secureplt.h Tue May 20 11:06:11 2014 -0400 -@@ -18,3 +18,4 @@ - <http://www.gnu.org/licenses/>. */ - - #define CC1_SECURE_PLT_DEFAULT_SPEC "-msecure-plt" -+#define LINK_SECURE_PLT_DEFAULT_SPEC "--secure-plt" ---- a/gcc/config/rs6000/sysv4.h 2012-04-30 19:39:01.000000000 -0200 -+++ b/gcc/config/rs6000/sysv4.h 2014-10-21 10:24:03.631956578 -0200 -@@ -537,6 +537,9 @@ - } \ - while (0) - #endif -+#ifndef LINK_SECURE_PLT_DEFAULT_SPEC -+#define LINK_SECURE_PLT_DEFAULT_SPEC "" -+#endif - - #undef ASM_SPEC - #define ASM_SPEC "%(asm_cpu) \ -@@ -624,6 +627,7 @@ - /* Override the default target of the linker. */ - #define LINK_TARGET_SPEC "\ - %{mlittle: --oformat elf32-powerpcle } %{mlittle-endian: --oformat elf32-powerpcle } \ -+%{!mbss-plt: %{!msecure-plt: %(link_secure_plt_default)}} \ - %{!mlittle: %{!mlittle-endian: %{!mbig: %{!mbig-endian: \ - %{mcall-i960-old: --oformat elf32-powerpcle} \ - }}}}" -@@ -938,6 +942,7 @@ - { "cc1_endian_little", CC1_ENDIAN_LITTLE_SPEC }, \ - { "cc1_endian_default", CC1_ENDIAN_DEFAULT_SPEC }, \ - { "cc1_secure_plt_default", CC1_SECURE_PLT_DEFAULT_SPEC }, \ -+ { "link_secure_plt_default", LINK_SECURE_PLT_DEFAULT_SPEC }, \ - { "cpp_os_ads", CPP_OS_ADS_SPEC }, \ - { "cpp_os_yellowknife", CPP_OS_YELLOWKNIFE_SPEC }, \ - { "cpp_os_mvme", CPP_OS_MVME_SPEC }, \ diff --git a/sys-devel/gcc/files/gcc-4.8.3-musl-fix-libc5-assumption.patch b/sys-devel/gcc/files/gcc-4.8.3-musl-fix-libc5-assumption.patch deleted file mode 100644 index 65bc45e7..00000000 --- a/sys-devel/gcc/files/gcc-4.8.3-musl-fix-libc5-assumption.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- /var/tmp/portage/sys-devel/gcc-4.8.3-r99/work/gcc-4.8.3/boehm-gc/os_dep.c 2013-03-06 15:08:58.000000000 +0000 -+++ gcc-4.8.3.new/boehm-gc/os_dep.c 2014-10-24 18:25:39.963379871 +0000 -@@ -41,7 +41,7 @@ - # else /* not 2 <= __GLIBC__ */ - /* libc5 doesn't have <sigcontext.h>: go directly with the kernel */ - /* one. Check LINUX_VERSION_CODE to see which we should reference. */ --# include <asm/sigcontext.h> -+//# include <asm/sigcontext.h> - # endif /* 2 <= __GLIBC__ */ - # endif - # endif diff --git a/sys-devel/gcc/files/gcc-4.8.3-musl-linker-path.patch b/sys-devel/gcc/files/gcc-4.8.3-musl-linker-path.patch deleted file mode 100644 index a22fb80c..00000000 --- a/sys-devel/gcc/files/gcc-4.8.3-musl-linker-path.patch +++ /dev/null @@ -1,70 +0,0 @@ -diff -ur a/gcc-4.8.3/gcc/config/arm/linux-eabi.h b/gcc-4.8.3/gcc/config/arm/linux-eabi.h ---- a/gcc-4.8.3/gcc/config/arm/linux-eabi.h 2013-01-10 21:38:27.000000000 -0100 -+++ b/gcc-4.8.3/gcc/config/arm/linux-eabi.h 2014-11-26 21:09:34.162787397 -0100 -@@ -68,8 +68,8 @@ - GLIBC_DYNAMIC_LINKER_DEFAULT and TARGET_DEFAULT_FLOAT_ABI. */ - - #undef GLIBC_DYNAMIC_LINKER --#define GLIBC_DYNAMIC_LINKER_SOFT_FLOAT "/lib/ld-linux.so.3" --#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT "/lib/ld-linux-armhf.so.3" -+#define GLIBC_DYNAMIC_LINKER_SOFT_FLOAT "/lib/ld-musl-arm.so.1" -+#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT "/lib/ld-musl-armhf.so.1" - #define GLIBC_DYNAMIC_LINKER_DEFAULT GLIBC_DYNAMIC_LINKER_SOFT_FLOAT - - #define GLIBC_DYNAMIC_LINKER \ -diff -ur a/gcc-4.8.3/gcc/config/i386/linux64.h b/gcc-4.8.3/gcc/config/i386/linux64.h ---- a/gcc-4.8.3/gcc/config/i386/linux64.h 2013-01-10 21:38:27.000000000 -0100 -+++ b/gcc-4.8.3/gcc/config/i386/linux64.h 2014-11-26 21:09:34.162787397 -0100 -@@ -27,6 +27,6 @@ - #define GNU_USER_LINK_EMULATION64 "elf_x86_64" - #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64" - --#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2" --#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2" -+#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-musl-i386.so.1" -+#define GLIBC_DYNAMIC_LINKER64 "/lib/ld-musl-x86_64.so.1" - #define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2" -diff -ur a/gcc-4.8.3/gcc/config/mips/linux.h b/gcc-4.8.3/gcc/config/mips/linux.h ---- a/gcc-4.8.3/gcc/config/mips/linux.h 2013-01-10 21:38:27.000000000 -0100 -+++ b/gcc-4.8.3/gcc/config/mips/linux.h 2014-11-26 21:11:28.772354580 -0100 -@@ -17,4 +17,9 @@ - along with GCC; see the file COPYING3. If not see - <http://www.gnu.org/licenses/>. */ - --#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1" -+#if TARGET_ENDIAN_DEFAULT == 0 /* LE */ -+#define GLIBC_DYNAMIC_LINKER_E "%{EB:;:el}" -+#else -+#define GLIBC_DYNAMIC_LINKER_E "%{EL:el}" -+#endif -+#define GLIBC_DYNAMIC_LINKER "/lib/ld-musl-mips" GLIBC_DYNAMIC_LINKER_E ".so.1" -diff -ur a/gcc-4.8.3/gcc/config/rs6000/linux64.h b/gcc-4.8.3/gcc/config/rs6000/linux64.h ---- a/gcc-4.8.3/gcc/config/rs6000/linux64.h 2014-04-04 16:10:24.000000000 -0100 -+++ b/gcc-4.8.3/gcc/config/rs6000/linux64.h 2014-11-26 21:09:34.164787372 -0100 -@@ -366,12 +366,8 @@ - #undef LINK_OS_DEFAULT_SPEC - #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)" - --#define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1" --#ifdef LINUX64_DEFAULT_ABI_ELFv2 --#define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv1:/lib64/ld64.so.1;:/lib64/ld64.so.2}" --#else --#define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv2:/lib64/ld64.so.2;:/lib64/ld64.so.1}" --#endif -+#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-musl-powerpc.so.1" -+#define GLIBC_DYNAMIC_LINKER64 "/lib/ld-musl-powerpc64.so.1" - #define UCLIBC_DYNAMIC_LINKER32 "/lib/ld-uClibc.so.0" - #define UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0" - #if DEFAULT_LIBC == LIBC_UCLIBC -diff -ur a/gcc-4.8.3/gcc/config/rs6000/sysv4.h b/gcc-4.8.3/gcc/config/rs6000/sysv4.h ---- a/gcc-4.8.3/gcc/config/rs6000/sysv4.h 2014-04-04 15:50:31.000000000 -0100 -+++ b/gcc-4.8.3/gcc/config/rs6000/sysv4.h 2014-11-26 21:09:34.164787372 -0100 -@@ -761,7 +761,7 @@ - - #define LINK_START_LINUX_SPEC "" - --#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1" -+#define GLIBC_DYNAMIC_LINKER "/lib/ld-musl-powerpc.so.1" - #define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" - #if DEFAULT_LIBC == LIBC_UCLIBC - #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}" diff --git a/sys-devel/gcc/files/gcc-4.8.3-musl-res_state.patch b/sys-devel/gcc/files/gcc-4.8.3-musl-res_state.patch deleted file mode 100644 index 7757c38c..00000000 --- a/sys-devel/gcc/files/gcc-4.8.3-musl-res_state.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -ENwbur gcc-4.8.3.orig/libsanitizer/tsan/tsan_platform_linux.cc gcc-4.8.3/libsanitizer/tsan/tsan_platform_linux.cc ---- gcc-4.8.3.orig/libsanitizer/tsan/tsan_platform_linux.cc 2014-08-31 12:50:18.381689906 +0000 -+++ gcc-4.8.3/libsanitizer/tsan/tsan_platform_linux.cc 2014-08-31 13:12:19.838446253 +0000 -@@ -292,7 +292,7 @@ - #ifndef TSAN_GO - int ExtractResolvFDs(void *state, int *fds, int nfd) { - int cnt = 0; -- __res_state *statp = (__res_state*)state; -+ res_state statp = (res_state)state; - for (int i = 0; i < MAXNS && cnt < nfd; i++) { - if (statp->_u._ext.nsaddrs[i] && statp->_u._ext.nssocks[i] != -1) - fds[cnt++] = statp->_u._ext.nssocks[i]; diff --git a/sys-devel/gcc/files/gcc-4.8.3-secure-plt.patch b/sys-devel/gcc/files/gcc-4.8.3-secure-plt.patch deleted file mode 100644 index fc367aef..00000000 --- a/sys-devel/gcc/files/gcc-4.8.3-secure-plt.patch +++ /dev/null @@ -1,43 +0,0 @@ -diff -ur a/gcc-4.8.3/gcc/config/rs6000/secureplt.h b/gcc-4.8.3/gcc/config/rs6000/secureplt.h ---- a/gcc-4.8.3/gcc/config/rs6000/secureplt.h 2013-01-10 21:38:27.000000000 -0100 -+++ b/gcc-4.8.3/gcc/config/rs6000/secureplt.h 2014-11-03 20:41:01.696584962 -0100 -@@ -18,3 +18,4 @@ - <http://www.gnu.org/licenses/>. */ - - #define CC1_SECURE_PLT_DEFAULT_SPEC "-msecure-plt" -+#define LINK_SECURE_PLT_DEFAULT_SPEC "--secure-plt" -diff -ur a/gcc-4.8.3/gcc/config/rs6000/sysv4.h b/gcc-4.8.3/gcc/config/rs6000/sysv4.h ---- a/gcc-4.8.3/gcc/config/rs6000/sysv4.h 2014-04-04 15:50:31.000000000 -0100 -+++ b/gcc-4.8.3/gcc/config/rs6000/sysv4.h 2014-11-03 20:42:30.098479787 -0100 -@@ -585,7 +585,8 @@ - - /* Override the default target of the linker. */ - #define LINK_TARGET_SPEC \ -- ENDIAN_SELECT("", " --oformat elf32-powerpcle", "") -+ ENDIAN_SELECT("", " --oformat elf32-powerpcle", "") \ -+ "%{!mbss-plt: %{!msecure-plt: %(link_secure_plt_default)}}" - - /* Any specific OS flags. */ - #define LINK_OS_SPEC "\ -@@ -894,6 +895,7 @@ - { "link_os_openbsd", LINK_OS_OPENBSD_SPEC }, \ - { "link_os_default", LINK_OS_DEFAULT_SPEC }, \ - { "cc1_secure_plt_default", CC1_SECURE_PLT_DEFAULT_SPEC }, \ -+ { "link_secure_plt_default", LINK_SECURE_PLT_DEFAULT_SPEC }, \ - { "cpp_os_ads", CPP_OS_ADS_SPEC }, \ - { "cpp_os_yellowknife", CPP_OS_YELLOWKNIFE_SPEC }, \ - { "cpp_os_mvme", CPP_OS_MVME_SPEC }, \ -diff -ur a/gcc-4.8.3/gcc/config.gcc b/gcc-4.8.3/gcc/config.gcc ---- a/gcc-4.8.3/gcc/config.gcc 2014-05-06 16:29:04.000000000 -0100 -+++ b/gcc-4.8.3/gcc/config.gcc 2014-11-03 20:40:13.135192063 -0100 -@@ -2135,6 +2135,10 @@ - powerpc*-*-linux*paired*) - tm_file="${tm_file} rs6000/750cl.h" ;; - esac -+ case ${target} in -+ *-linux*-musl*) -+ enable_secureplt=yes ;; -+ esac - if test x${enable_secureplt} = xyes; then - tm_file="rs6000/secureplt.h ${tm_file}" - fi diff --git a/sys-devel/gcc/files/gcc-configure-LANG.patch b/sys-devel/gcc/files/gcc-configure-LANG.patch deleted file mode 100644 index d1b1b035..00000000 --- a/sys-devel/gcc/files/gcc-configure-LANG.patch +++ /dev/null @@ -1,64 +0,0 @@ -The LANG vars aren't reset early enough so when sed tries to use [a-zA-Z] in -option parsing, it may break. - -http://bugs.gentoo.org/103483 - ---- configure -+++ configure -@@ -54,6 +54,19 @@ - infodir='${prefix}/info' - mandir='${prefix}/man' - -+# NLS nuisances. -+for as_var in \ -+ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ -+ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ -+ LC_TELEPHONE LC_TIME -+do -+ if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then -+ eval $as_var=C; export $as_var -+ else -+ unset $as_var -+ fi -+done -+ - # Initialize some other variables. - subdirs= - MFLAGS= MAKEFLAGS= -@@ -452,16 +463,6 @@ - esac - done - --# NLS nuisances. --# Only set these to C if already set. These must not be set unconditionally --# because not all systems understand e.g. LANG=C (notably SCO). --# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! --# Non-C LC_CTYPE values break the ctype check. --if test "${LANG+set}" = set; then LANG=C; export LANG; fi --if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi --if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi --if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi -- - # confdefs.h avoids OS command line length limits that DEFS can exceed. - rm -rf conftest* confdefs.h - # AIX cpp loses on an empty file, so make sure it contains at least a newline. -@@ -1850,6 +1850,19 @@ - # Compiler output produced by configure, useful for debugging - # configure, is in ./config.log if it exists. - -+# NLS nuisances. -+for as_var in \ -+ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ -+ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ -+ LC_TELEPHONE LC_TIME -+do -+ if (set +x; test -z "`(eval \$as_var=C; export \$as_var) 2>&1`"); then -+ eval \$as_var=C; export \$as_var -+ else -+ unset \$as_var -+ fi -+done -+ - ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" - for ac_option - do diff --git a/sys-devel/gcc/files/gcc-configure-texinfo.patch b/sys-devel/gcc/files/gcc-configure-texinfo.patch deleted file mode 100644 index ddc098dd..00000000 --- a/sys-devel/gcc/files/gcc-configure-texinfo.patch +++ /dev/null @@ -1,16 +0,0 @@ -Chances are quite good that the installed makeinfo is sufficient. -So ignore false positives where the makeinfo installed is so new -that it violates the cheesy version grep. - -http://bugs.gentoo.org/198182 - ---- configure -+++ configure -@@ -3573,6 +3573,6 @@ - : - else -- MAKEINFO="$MISSING makeinfo" -+ : - fi - ;; - diff --git a/sys-devel/gcc/files/gcc-spec-env-r1.patch b/sys-devel/gcc/files/gcc-spec-env-r1.patch deleted file mode 100644 index a5892683..00000000 --- a/sys-devel/gcc/files/gcc-spec-env-r1.patch +++ /dev/null @@ -1,87 +0,0 @@ -2013-08-22 Magnus Granberg <zorry@gentoo.org> - - * gcc/gcc.c (main): Add support for external spec file via the GCC_SPECS env var - and move the process of the user specifed specs. - - This allows us to easily control pie/ssp defaults with gcc-config profiles. - Original patch by Rob Holland - Extended to support multiple entries separated by ':' by Kevin F. Quinn - Modified to use getenv instead of poisoned GET_ENVIRONMENT by Ryan Hill - Modified to process the GCC_SPECS env var befor DRIVER_SELF_SPECS by Magnus Granberg - ---- gcc-4.8-20130210/gcc/gcc.c 2013-02-05 16:55:31.000000000 +0100 -+++ gcc-4.8-20130210-work/gcc/gcc.c 2013-07-26 02:32:14.625089864 +0200 -@@ -6427,6 +6428,48 @@ main (int argc, char **argv) - do_option_spec (option_default_specs[i].name, - option_default_specs[i].spec); - -+#if !(defined (__MSDOS__) || defined (OS2) || defined (VMS) || defined (WIN32)) -+ /* Add specs listed in GCC_SPECS. Note; in the process of separating -+ * each spec listed, the string is overwritten at token boundaries -+ * (':') with '\0', an effect of strtok_r(). -+ */ -+ specs_file = getenv ("GCC_SPECS"); -+ if (specs_file && (strlen(specs_file) > 0)) -+ { -+ char *spec, *saveptr; -+ for (spec=strtok_r(specs_file,":",&saveptr); -+ spec!=NULL; -+ spec=strtok_r(NULL,":",&saveptr)) -+ { -+ struct user_specs *user = (struct user_specs *) -+ xmalloc (sizeof (struct user_specs)); -+ user->next = (struct user_specs *) 0; -+ user->filename = spec; -+ if (user_specs_tail) -+ user_specs_tail->next = user; -+ else -+ user_specs_head = user; -+ user_specs_tail = user; -+ } -+ } -+#endif -+ /* Process any user specified specs in the order given on the command -+ * line. */ -+ for (uptr = user_specs_head; uptr; uptr = uptr->next) -+ { -+ char *filename = find_a_file (&startfile_prefixes, uptr->filename, -+ R_OK, true); -+ read_specs (filename ? filename : uptr->filename, false, true); -+ } -+ /* Process any user self specs. */ -+ { -+ struct spec_list *sl; -+ for (sl = specs; sl; sl = sl->next) -+ if (sl->name_len == sizeof "self_spec" - 1 -+ && !strcmp (sl->name, "self_spec")) -+ do_self_spec (*sl->ptr_spec); -+ } -+ - /* Process DRIVER_SELF_SPECS, adding any new options to the end - of the command line. */ - -@@ -6535,24 +6578,6 @@ main (int argc, char **argv) - PREFIX_PRIORITY_LAST, 0, 1); - } - -- /* Process any user specified specs in the order given on the command -- line. */ -- for (uptr = user_specs_head; uptr; uptr = uptr->next) -- { -- char *filename = find_a_file (&startfile_prefixes, uptr->filename, -- R_OK, true); -- read_specs (filename ? filename : uptr->filename, false, true); -- } -- -- /* Process any user self specs. */ -- { -- struct spec_list *sl; -- for (sl = specs; sl; sl = sl->next) -- if (sl->name_len == sizeof "self_spec" - 1 -- && !strcmp (sl->name, "self_spec")) -- do_self_spec (*sl->ptr_spec); -- } -- - if (compare_debug) - { - enum save_temps save; diff --git a/sys-devel/gcc/files/gcc-spec-env.patch b/sys-devel/gcc/files/gcc-spec-env.patch deleted file mode 100644 index 57e7567e..00000000 --- a/sys-devel/gcc/files/gcc-spec-env.patch +++ /dev/null @@ -1,42 +0,0 @@ - Add support for external spec file via the GCC_SPECS env var. This - allows us to easily control pie/ssp defaults with gcc-config profiles. - - Original patch by Rob Holland - Extended to support multiple entries separated by ':' by Kevin F. Quinn - Modified to use getenv instead of poisoned GET_ENVIRONMENT by Ryan Hill - ---- gcc-4/gcc/gcc.c -+++ gcc-4/gcc/gcc.c -@@ -6482,6 +6482,32 @@ - - /* Process any user specified specs in the order given on the command - line. */ -+#if !(defined (__MSDOS__) || defined (OS2) || defined (VMS) || defined (WIN32)) -+ /* Add specs listed in GCC_SPECS. Note; in the process of separating -+ * each spec listed, the string is overwritten at token boundaries -+ * (':') with '\0', an effect of strtok_r(). -+ */ -+ specs_file = getenv ("GCC_SPECS"); -+ if (specs_file && (strlen(specs_file) > 0)) -+ { -+ char *spec, *saveptr; -+ for (spec=strtok_r(specs_file,":",&saveptr); -+ spec!=NULL; -+ spec=strtok_r(NULL,":",&saveptr)) -+ { -+ struct user_specs *user = (struct user_specs *) -+ xmalloc (sizeof (struct user_specs)); -+ -+ user->next = (struct user_specs *) 0; -+ user->filename = spec; -+ if (user_specs_tail) -+ user_specs_tail->next = user; -+ else -+ user_specs_head = user; -+ user_specs_tail = user; -+ } -+ } -+#endif - for (uptr = user_specs_head; uptr; uptr = uptr->next) - { - char *filename = find_a_file (&startfile_prefixes, uptr->filename, diff --git a/sys-devel/gcc/files/mkinfodir b/sys-devel/gcc/files/mkinfodir deleted file mode 100644 index a62840ee..00000000 --- a/sys-devel/gcc/files/mkinfodir +++ /dev/null @@ -1,233 +0,0 @@ -#!/bin/bash -# $Id: mkinfodir,v 1.1 2001/09/01 07:56:19 drobbins Exp $ -# Generate the top-level Info node, given a directory of Info files -# and (optionally) a skeleton file. The output will be suitable for a -# top-level dir file. The skeleton file contains info topic names in the -# order they should appear in the output. There are three special -# lines that alter the behavior: a line consisting of just "--" causes -# the next line to be echoed verbatim to the output. A line -# containing just "%%" causes all the remaining filenames (wildcards -# allowed) in the rest of the file to be ignored. A line containing -# just "!!" exits the script when reached (unless preceded by a line -# containing just "--"). Once the script reaches the end of the -# skeleton file, it goes through the remaining files in the directory -# in order, putting their entries at the end. The script will use the -# ENTRY information in each info file if it exists. Otherwise it will -# make a minimal entry. - -# sent by Jeffrey Osier <jeffrey@cygnus.com>, who thinks it came from -# zoo@winternet.com (david d `zoo' zuhn) - -# modified 7 April 1995 by Joe Harrington <jh@tecate.gsfc.nasa.gov> to -# take special flags - -INFODIR=$1 -if [ $# = 2 ] ; then - SKELETON=$2 -else - SKELETON=/dev/null -fi - -skip= - -if [ $# -gt 2 ] ; then - echo usage: $0 info-directory [ skeleton-file ] 1>&2 - exit 1 -elif [ -z "${INFODIR}" ] ; then - INFODIR="%%DEFAULT_INFO_DIR%%" -else - true -fi - -if [ ! -d ${INFODIR} ] ; then - echo "$0: first argument must specify a directory" - exit 1 -fi - -### output the dir header -echo "-*- Text -*-" -echo "This file was generated automatically by $0." -echo "This version was generated on `date`" -echo "by `whoami`@`hostname` for `(cd ${INFODIR}; pwd)`" - -cat << moobler -\$Id: mkinfodir,v 1.1 2001/09/01 07:56:19 drobbins Exp $ -This is the file .../info/dir, which contains the topmost node of the -Info hierarchy. The first time you invoke Info you start off -looking at that node, which is (dir)Top. - -File: dir Node: Top This is the top of the INFO tree - - This (the Directory node) gives a menu of major topics. - Typing "q" exits, "?" lists all Info commands, "d" returns here, - "h" gives a primer for first-timers, - "mEmacs<Return>" visits the Emacs topic, etc. - - In Emacs, you can click mouse button 2 on a menu item or cross reference - to select it. - -* Menu: The list of major topics begins on the next line. - -moobler - -### go through the list of files in the skeleton. If an info file -### exists, grab the ENTRY information from it. If an entry exists -### use it, otherwise create a minimal dir entry. -### -### Then remove that file from the list of existing files. If any -### additional files remain (ones that don't have a skeleton entry), -### then generate entries for those in the same way, putting the info for -### those at the end.... - -infofiles=`(cd ${INFODIR}; /bin/ls | grep -v '\-[0-9]*\.gz$' | grep -v '\-[0-9]*$' | egrep -v '^dir$|^dir\.info$|^dir\.orig$')` - -# echoing gets clobbered by backquotes; we do it the hard way... -lines=`wc $SKELETON | awk '{print $1}'` -line=1 -while [ $lines -ge $line ] ; do - # Read one line from the file. This is so that we can echo lines with - # whitespace and quoted characters in them. - fileline=`awk NR==$line $SKELETON` - - # flag fancy features - if [ ! -z "$echoline" ] ; then # echo line - echo "$fileline" - fileline= - echoline= - elif [ "${fileline}" = "--" ] ; then # should we echo the next line? - echoline=1 - elif [ "${fileline}" = "%%" ] ; then # eliminate remaining files from dir? - skip=1 - elif [ "${fileline}" = "!!" ] ; then # quit now - exit 0 - fi - - # handle files if they exist - for file in $fileline"" ; do # expand wildcards ("" handles blank lines) - - fname= - - if [ -z "$echoline" -a ! -z "$file" ] ; then - - # Find the file to operate upon. Check both possible names. - infoname=`echo $file | sed 's/\.gz$//'` - infoname=`echo $infoname | sed 's/\.info$//'` - noext= - ext= - if [ -f ${INFODIR}/$infoname ] ; then - noext=$infoname - fi - if [ -f ${INFODIR}/${infoname}.info ] ; then - ext=${infoname}.info - fi - if [ -f ${INFODIR}/${infoname}.info.gz ] ; then - ext=${infoname}.info.gz - fi - # If it exists with both names take what was said in the file. - if [ ! -z "$ext" -a ! -z "$noext" ]; then - fname=$file - warn="### Warning: $ext and $noext both exist! Using ${file}. ###" - elif [ ! \( -z "$ext" -a -z "$noext" \) ]; then - # just take the name if it exists only once - fname=${noext}${ext} - fi - - # if we found something and aren't skipping, do the entry - if [ ! -z "$fname" ] ; then - if [ -z "$skip" ] ; then - - if [ ! -z "$warn" ] ; then # issue any warning - echo $warn - warn= - fi - if [ "${fname##*.}" = "gz" ] ; then - entry=`zcat ${INFODIR}/${fname} | sed -e '1,/START-INFO-DIR-ENTRY/d' \ - -e '/END-INFO-DIR-ENTRY/,$d' ` - else - entry=`sed -e '1,/START-INFO-DIR-ENTRY/d' \ - -e '/END-INFO-DIR-ENTRY/,$d' ${INFODIR}/$fname` - fi - if [ ! -z "${entry}" ] ; then - echo "${entry}" - else - echo "* ${infoname}: (${infoname})." - fi - fi - - # remove the name from the directory listing - infofiles=`echo "" ${infofiles} "" | sed -e "s/ ${fname} / /" -e "s/ / /g"` - - fi - - fi - - done - - line=`expr $line + 1` -done - -if [ -z "${infofiles}" ] ; then - exit 0 -elif [ $lines -gt 0 ]; then - echo -fi - -# Sort remaining files by INFO-DIR-SECTION. -prevsect= -filesectdata=`(cd ${INFODIR}; fgrep INFO-DIR-SECTION /dev/null ${infofiles} | \ - fgrep -v 'INFO-DIR-SECTION Miscellaneous' | \ - sort -t: -k2 -k1 | tr ' ' '_')` -for sectdata in ${filesectdata}; do - file=`echo ${sectdata} | cut -d: -f1` - section=`sed -n -e 's/^INFO-DIR-SECTION //p' ${INFODIR}/${file}` - infofiles=`echo "" ${infofiles} "" | sed -e "s/ ${file} / /" -e "s/ / /g"` - - if [ "${prevsect}" != "${section}" ] ; then - if [ ! -z "${prevsect}" ] ; then - echo "" - fi - echo "${section}" - prevsect="${section}" - fi - infoname=`echo $file | sed 's/\.gz$//'` - infoname=`echo $infoname | sed 's/\.info$//'` - if [ "${file##*.}" = "gz" ] ; then - entry=`zcat ${INFODIR}/$file | sed -e '1,/START-INFO-DIR-ENTRY/d' \ - -e '/END-INFO-DIR-ENTRY/,$d' ` - else - entry=`sed -e '1,/START-INFO-DIR-ENTRY/d' \ - -e '/END-INFO-DIR-ENTRY/,$d' ${INFODIR}/$file` - fi - if [ ! -z "${entry}" ] ; then - echo "${entry}" - elif [ ! -d "${INFODIR}/${file}" ] ; then - echo "* ${infoname}: (${infoname})." - fi -done - -# Process miscellaneous files. -for file in ${infofiles}; do - if [ ! -z "${prevsect}" ] ; then - echo "" - echo "Miscellaneous" - prevsect="" - fi - - infoname=`echo $file | sed 's/\.gz$//'` - infoname=`echo $infoname | sed 's/\.info$//'` - if [ "${file##*.}" = "gz" ] ; then - entry=`zcat ${INFODIR}/${file} | sed -e '1,/START-INFO-DIR-ENTRY/d' \ - -e '/END-INFO-DIR-ENTRY/,$d'` - else - entry=`sed -e '1,/START-INFO-DIR-ENTRY/d' \ - -e '/END-INFO-DIR-ENTRY/,$d' ${INFODIR}/$file` - fi - - - if [ ! -z "${entry}" ] ; then - echo "${entry}" - elif [ ! -d "${INFODIR}/${file}" ] ; then - echo "* ${infoname}: (${infoname})." - fi -done - |