[gcc-6] 310/401: * Fix the configure check for compressed debug section support in as and ld. Enables the -gz option again. Taken from the trunk.
Ximin Luo
infinity0 at debian.org
Wed Apr 5 15:50:16 UTC 2017
This is an automated email from the git hooks/post-receive script.
infinity0 pushed a commit to branch pu/reproducible_builds
in repository gcc-6.
commit c242ea44db08879ca5f45281251753780009deac
Author: doko <doko at 6ca36cf4-e1d1-0310-8c6f-e303bb2178ca>
Date: Fri Dec 2 22:28:00 2016 +0000
* Fix the configure check for compressed debug section support in as and ld.
Enables the -gz option again. Taken from the trunk.
git-svn-id: svn://anonscm.debian.org/gcccvs/branches/sid/gcc-6@9168 6ca36cf4-e1d1-0310-8c6f-e303bb2178ca
---
debian/changelog | 2 +
debian/patches/compress-debug-check.diff | 88 ++++++++++++++++++++++++++++++++
debian/rules.patch | 1 +
3 files changed, 91 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index 1506068..afb40fb 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -9,6 +9,8 @@ gcc-6 (6.2.1-6) UNRELEASED; urgency=medium
* Install missing vecintrin.h header on s390x.
* Fix PR target/77267 (x86), taken from the trunk.
* Use --push-state/--pop-state for gold as well when linking libtsan.
+ * Fix the configure check for compressed debug section support in as and ld.
+ Enables the -gz option again. Taken from the trunk.
[ Svante Signell ]
* GNU/Hurd port for gccgo.
diff --git a/debian/patches/compress-debug-check.diff b/debian/patches/compress-debug-check.diff
new file mode 100644
index 0000000..2395e6a
--- /dev/null
+++ b/debian/patches/compress-debug-check.diff
@@ -0,0 +1,88 @@
+gcc/
+
+2016-06-22 Rainer Orth <ro at CeBiTec.Uni-Bielefeld.DE>
+
+ * configure.ac (gcc_cv_as_compress_debug): Remove
+ --compress-debug-sections as extra as switch.
+ Handle gas --compress-debug-sections=type.
+ (gcc_cv_ld_compess_debug): Remove bogus ld_date check.
+ Handle gld --compress-debug-sections=type.
+ * configure: Regenerate.
+
+
+--- a/src/gcc/configure.ac
++++ b/src/gcc/configure.ac
+@@ -4729,12 +4729,21 @@
+ fi
+
+ gcc_GAS_CHECK_FEATURE([compressed debug sections],
+- gcc_cv_as_compress_debug,,[--compress-debug-sections],,
++ gcc_cv_as_compress_debug,,,,
+ [# gas compiled without zlib cannot compress debug sections and warns
+ # about it, but still exits successfully. So check for this, too.
+ if $gcc_cv_as --compress-debug-sections -o conftest.o conftest.s 2>&1 | grep -i warning > /dev/null
+ then
+ gcc_cv_as_compress_debug=0
++ # Since binutils 2.26, gas supports --compress-debug-sections=type,
++ # defaulting to the ELF gABI format.
++ elif $gcc_cv_as --compress-debug-sections=zlib-gnu -o conftest.o conftest.s > /dev/null 2>&1
++ then
++ gcc_cv_as_compress_debug=2
++ gcc_cv_as_compress_debug_option="--compress-debug-sections"
++ gcc_cv_as_no_compress_debug_option="--nocompress-debug-sections"
++ # Before binutils 2.26, gas only supported --compress-debug-options and
++ # emitted the traditional GNU format.
+ elif $gcc_cv_as --compress-debug-sections -o conftest.o conftest.s > /dev/null 2>&1
+ then
+ gcc_cv_as_compress_debug=1
+@@ -4742,8 +4751,6 @@
+ gcc_cv_as_no_compress_debug_option="--nocompress-debug-sections"
+ else
+ gcc_cv_as_compress_debug=0
+- # FIXME: Future gas versions will support ELF gABI style via
+- # --compress-debug-sections[=type].
+ fi])
+ AC_DEFINE_UNQUOTED(HAVE_AS_COMPRESS_DEBUG, $gcc_cv_as_compress_debug,
+ [Define to the level of your assembler's compressed debug section support.])
+@@ -5118,6 +5125,7 @@
+
+ AC_MSG_CHECKING(linker for compressed debug sections)
+ # gold/gld support compressed debug sections since binutils 2.19/2.21
++# In binutils 2.26, gld gained support for the ELF gABI format.
+ if test $in_tree_ld = yes ; then
+ gcc_cv_ld_compress_debug=0
+ if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 19 -o "$gcc_cv_gld_major_version" -gt 2 \
+@@ -5124,21 +5132,23 @@
+ && test $in_tree_ld_is_elf = yes && test $ld_is_gold = yes; then
+ gcc_cv_ld_compress_debug=2
+ gcc_cv_ld_compress_debug_option="--compress-debug-sections"
++ elif test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 26 -o "$gcc_cv_gld_major_version" -gt 2 \
++ && test $in_tree_ld_is_elf = yes && test $ld_is_gold = no; then
++ gcc_cv_ld_compress_debug=3
++ gcc_cv_ld_compress_debug_option="--compress-debug-sections"
+ elif test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 21 -o "$gcc_cv_gld_major_version" -gt 2 \
+ && test $in_tree_ld_is_elf = yes; then
+ gcc_cv_ld_compress_debug=1
+ fi
+ elif echo "$ld_ver" | grep GNU > /dev/null; then
+- gcc_cv_ld_compress_debug=1
+- if test 0"$ld_date" -lt 20050308; then
+- if test -n "$ld_date"; then
+- # If there was date string, but was earlier than 2005-03-08, fail
+- gcc_cv_ld_compress_debug=0
+- elif test "$ld_vers_major" -lt 2; then
+- gcc_cv_ld_compress_debug=0
+- elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -lt 21; then
+- gcc_cv_ld_compress_debug=0
+- fi
++ if test "$ld_vers_major" -lt 2 \
++ || test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -lt 21; then
++ gcc_cv_ld_compress_debug=0
++ elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -lt 26; then
++ gcc_cv_ld_compress_debug=1
++ else
++ gcc_cv_ld_compress_debug=3
++ gcc_cv_ld_compress_debug_option="--compress-debug-sections"
+ fi
+ if test $ld_is_gold = yes; then
+ gcc_cv_ld_compress_debug=2
diff --git a/debian/rules.patch b/debian/rules.patch
index 5dd285e..b8bda00 100644
--- a/debian/rules.patch
+++ b/debian/rules.patch
@@ -101,6 +101,7 @@ debian_patches += \
libgo-rawClone-no-pt_regs \
libgo-elf-relocations-sparc64 \
libobjc-system-gc \
+ compress-debug-check \
pr77267 \
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/gcc-6.git
More information about the Reproducible-commits
mailing list