summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
Diffstat (limited to 'debian')
-rw-r--r--debian/README.cross11
-rw-r--r--debian/README.source2
-rw-r--r--debian/binutils-common.overrides2
-rw-r--r--debian/binutils-cross.overrides7
-rw-r--r--debian/binutils-cross.shlibs.in2
-rw-r--r--debian/binutils-hppa64-linux-gnu.overrides3
-rw-r--r--debian/binutils-hppa64-linux-gnu.shlibs.in2
-rw-r--r--debian/binutils-triplet.overrides4
-rw-r--r--debian/binutils.overrides11
-rw-r--r--debian/binutils.shlibs.in2
-rw-r--r--debian/changelog888
-rw-r--r--debian/control964
-rw-r--r--debian/control.cross.in22
-rw-r--r--debian/control.in124
-rw-r--r--debian/dwp.16
-rw-r--r--debian/ld.gold.165
-rw-r--r--debian/libbinutils.overrides5
-rw-r--r--debian/libbinutils.shlibs.in2
-rw-r--r--debian/patches/001_ld_makefile_patch.patch6
-rw-r--r--debian/patches/012_check_ldrunpath_length.patch16
-rw-r--r--debian/patches/013_bash_in_ld_testsuite.patch17
-rw-r--r--debian/patches/128_ppc64_powerpc_biarch.patch2
-rw-r--r--debian/patches/129_multiarch_libpath.patch55
-rw-r--r--debian/patches/130_gold_disable_testsuite_build.patch6
-rw-r--r--debian/patches/131_ld_bootstrap_testsuite.patch8
-rw-r--r--debian/patches/135_bfd_soversion.patch38
-rw-r--r--debian/patches/135_bfd_version.patch49
-rw-r--r--debian/patches/136_bfd_pic.patch16
-rw-r--r--debian/patches/161_gold_dummy_zoption.diff4
-rw-r--r--debian/patches/164_ld_doc_remove_xref.diff8
-rw-r--r--debian/patches/binutils-no-development.diff10
-rw-r--r--debian/patches/branch-no-development.diff11
-rw-r--r--debian/patches/branch-updates.diff2548
-rw-r--r--debian/patches/branch-version.diff630
-rw-r--r--debian/patches/gold-no-keep-files-mapped.diff16
-rw-r--r--debian/patches/gold-sparc-fix.diff44
-rw-r--r--debian/patches/gprof-build.diff6
-rw-r--r--debian/patches/i18n-fr.diff13
-rw-r--r--debian/patches/infinity-notes.diff183
-rw-r--r--debian/patches/ld-new-dtags-by-default.diff49
-rw-r--r--debian/patches/mips64-default-n64.diff30
-rw-r--r--debian/patches/ppc-lib-search-order.diff28
-rw-r--r--debian/patches/pr21074-revert.diff67
-rw-r--r--debian/patches/pr21135.diff106
-rw-r--r--debian/patches/pr21137.diff112
-rw-r--r--debian/patches/pr21139.diff227
-rw-r--r--debian/patches/pr21156.diff156
-rw-r--r--debian/patches/pr21157.diff60
-rw-r--r--debian/patches/pr21342.diff99
-rw-r--r--debian/patches/pr21412.diff180
-rw-r--r--debian/patches/pr21414.diff99
-rw-r--r--debian/patches/pr21431.diff57
-rw-r--r--debian/patches/pr21432.diff85
-rw-r--r--debian/patches/pr21434.diff33
-rw-r--r--debian/patches/pr21438.diff125
-rw-r--r--debian/patches/pr21440.diff36
-rw-r--r--debian/patches/pr70909.diff343
-rw-r--r--debian/patches/series30
-rwxr-xr-xdebian/rules978
-rw-r--r--debian/source.lintian-overrides7
-rw-r--r--debian/source/format1
-rw-r--r--debian/strip.cross.in3
-rw-r--r--debian/tests/build13
-rw-r--r--debian/tests/control12
64 files changed, 3148 insertions, 5596 deletions
diff --git a/debian/README.cross b/debian/README.cross
index 6888a17..f118d3b 100644
--- a/debian/README.cross
+++ b/debian/README.cross
@@ -1,7 +1,7 @@
-Cross-binutils debian packages can be built directly from the binutils
-source package.
+Cross-binutils debian packages are directly built from the binutils
+source package together with the native binutils packages.
-To build a cross-binutils package:
+To build a cross-binutils package which is not yet built:
o Download and unpack the binutils source package:
@@ -20,7 +20,8 @@ To build a cross-binutils package:
(substitute your target name, e.g. "arm" or "m68k", instead of
"<your-target>")
----
-Nikita Youshchenko <yoush@cs.msu.su>
+--
Hector Oron <zumbi@debian.org>
Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
+Matthias Klose <doko@debian.org>
+Nikita Youshchenko <yoush@cs.msu.su>
diff --git a/debian/README.source b/debian/README.source
deleted file mode 100644
index f27f9f2..0000000
--- a/debian/README.source
+++ /dev/null
@@ -1,2 +0,0 @@
-The package uses dpatch to apply patches on top of the upstream source.
-See /usr/share/doc/dpatch/README.source.gz.
diff --git a/debian/binutils-common.overrides b/debian/binutils-common.overrides
new file mode 100644
index 0000000..65ee8dc
--- /dev/null
+++ b/debian/binutils-common.overrides
@@ -0,0 +1,2 @@
+# big tables
+binutils-common binary: manpage-has-errors-from-man
diff --git a/debian/binutils-cross.overrides b/debian/binutils-cross.overrides
index 4724c18..e5e9ca5 100644
--- a/debian/binutils-cross.overrides
+++ b/debian/binutils-cross.overrides
@@ -5,4 +5,11 @@
@PKG@ binary: file-in-unusual-dir
# internal libs, with the target name encoded
+@PKG@ binary: no-shlibs-control-file
+
+# yes, intended
@PKG@ binary: shlib-in-multi-arch-foreign-package
+@PKG@ binary: triplet-dir-and-architecture-mismatch
+
+# some triplets are long ...
+@PKG@ binary: extended-description-line-too-long
diff --git a/debian/binutils-cross.shlibs.in b/debian/binutils-cross.shlibs.in
deleted file mode 100644
index 2924a5c..0000000
--- a/debian/binutils-cross.shlibs.in
+++ /dev/null
@@ -1,2 +0,0 @@
-libbfd @VER@-@ARCH@@DATE_EXT@ @PKG@ (>= @DEB_UVER@), @PKG@ (<< @DEB_NVER@)
-libopcodes @VER@-@ARCH@@DATE_EXT@ @PKG@ (>= @DEB_UVER@), @PKG@ (<< @DEB_NVER@)
diff --git a/debian/binutils-hppa64-linux-gnu.overrides b/debian/binutils-hppa64-linux-gnu.overrides
index 45a02c2..ce5267c 100644
--- a/debian/binutils-hppa64-linux-gnu.overrides
+++ b/debian/binutils-hppa64-linux-gnu.overrides
@@ -5,3 +5,6 @@ binutils-hppa64-linux-gnu binary: binary-without-manpage
binutils-hppa64-linux-gnu binary: package-name-doesnt-match-sonames
binutils-hppa64-linux-gnu binary: non-standard-dir-in-usr
+
+# private library. no -dev package is provided, nothing can link it
+binutils-hppa64-linux-gnu binary: no-shlibs-control-file
diff --git a/debian/binutils-hppa64-linux-gnu.shlibs.in b/debian/binutils-hppa64-linux-gnu.shlibs.in
deleted file mode 100644
index 35544a0..0000000
--- a/debian/binutils-hppa64-linux-gnu.shlibs.in
+++ /dev/null
@@ -1,2 +0,0 @@
-libbfd @VER@-hppa64@DATE_EXT@ binutils-hppa64-linux-gnu
-libopcodes @VER@-hppa64@DATE_EXT@ binutils-hppa64-linux-gnu
diff --git a/debian/binutils-triplet.overrides b/debian/binutils-triplet.overrides
new file mode 100644
index 0000000..9fba6aa
--- /dev/null
+++ b/debian/binutils-triplet.overrides
@@ -0,0 +1,4 @@
+# empty
+
+# silence lintian stupidity
+@PKG@ binary: spelling-error-in-binary usr/bin/as mmnemonic mnemonic
diff --git a/debian/binutils.overrides b/debian/binutils.overrides
index b61b3cc..38c8364 100644
--- a/debian/binutils.overrides
+++ b/debian/binutils.overrides
@@ -1,11 +1,6 @@
-# the API of the shared libs is not public, don't care about the name
-binutils binary: package-name-doesnt-match-sonames
-
-# the upstream name, we don't care
-binutils binary: dev-pkg-without-shlib-symlink
-
-# big tables
-binutils binary: manpage-has-errors-from-man
+# manpages are in binutils-common
+binutils binary: binary-without-manpage usr/bin/ld.bfd
+binutils binary: binary-without-manpage usr/bin/ld.gold
# silence lintian stupidity
binutils binary: spelling-error-in-binary usr/bin/as mmnemonic mnemonic
diff --git a/debian/binutils.shlibs.in b/debian/binutils.shlibs.in
deleted file mode 100644
index f7bba79..0000000
--- a/debian/binutils.shlibs.in
+++ /dev/null
@@ -1,2 +0,0 @@
-libbfd @VER@-system@DATE_EXT@ binutils (>= @DEB_UVER@), binutils (<< @DEB_NVER@)
-libopcodes @VER@-system@DATE_EXT@ binutils (>= @DEB_UVER@), binutils (<< @DEB_NVER@)
diff --git a/debian/changelog b/debian/changelog
index 20a7de2..c212ebb 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,889 @@
+binutils (2.33.1-2) unstable; urgency=medium
+
+ * Update from the binutils 2.33 branch:
+ - Arm: Fix out of range conditional branch (PR/24991).
+ - [bfd] Revise import stubs on hppa.
+ - [bfd] Provide 8-byte minimum alignment for .plt section on hppa.
+ * Drop amd64 cross compiler from the build dependencies on x32.
+
+ -- Matthias Klose <doko@debian.org> Sun, 20 Oct 2019 21:28:38 +0200
+
+binutils (2.33.1-1) unstable; urgency=medium
+
+ * Binutils 2.33.1 release.
+
+ -- Matthias Klose <doko@debian.org> Tue, 15 Oct 2019 11:43:46 +0200
+
+binutils (2.33-2) unstable; urgency=medium
+
+ * Update from the binutils 2.33 branch:
+ - Fix PR25079, "ar s" stopped working. Closes: #941921.
+ - PowerPC TLS miscounting PLT for __tls_get_addr.
+ - PowerPC section flag tidy.
+ - PowerPC PIC vs. DLL TLS issues.
+ - PR25046, readelf "Reading xxx bytes extends past end of file for dynamic section".
+ - PR24262, plugin search dir doesn't respect --libdir.
+
+ -- Matthias Klose <doko@debian.org> Wed, 09 Oct 2019 10:42:29 +0200
+
+binutils (2.33-1) unstable; urgency=medium
+
+ * Binutils 2.33 release (taken from the binutils-2_33 tag).
+ * Update from the binutils 2.33 branch:
+ - Fix PR 24942, change objcopy's --set-section-alignment option so that it
+ takes a byte alignment value rather than a power of two alignment value.
+ - x86-64: fix handling of PUSH/POP of segment register. LP: #1843394.
+ * Merge changes from binutils-mipsen.
+ * Bump standards version.
+
+ -- Matthias Klose <doko@debian.org> Tue, 08 Oct 2019 11:43:29 +0200
+
+binutils (2.32.51.20190909-1) unstable; urgency=medium
+
+ * Snapshot, taken from the trunk (20190909).
+ * Build the mipsel and mips64el cross packages from the binutils-mipsen
+ source package.
+
+ -- Matthias Klose <doko@debian.org> Mon, 09 Sep 2019 08:50:20 +0200
+
+binutils (2.32.51.20190821-2) unstable; urgency=medium
+
+ * Drop build dependency on g++-mips-linux-gnu.
+ * Stop building mips binutils.
+
+ -- Matthias Klose <doko@debian.org> Thu, 22 Aug 2019 09:49:59 +0200
+
+binutils (2.32.51.20190821-1) unstable; urgency=medium
+
+ * Snapshot, taken from the trunk (20190821).
+ * Update test dependencies for added ppc64el, riscv64 and s390x builds.
+
+ -- Matthias Klose <doko@debian.org> Wed, 21 Aug 2019 11:32:58 +0200
+
+binutils (2.32.51.20190813-1) unstable; urgency=medium
+
+ * Snapshot, taken from the trunk (20190813).
+ - Fix PR ld/24857: ld: error adding symbols: bad value. Closes: #932847.
+ * binutils-source: Fix ftbfs when with_native is off (YunQiang Su).
+ Closes: #933358.
+
+ -- Matthias Klose <doko@debian.org> Tue, 13 Aug 2019 16:26:14 +0200
+
+binutils (2.32.51.20190727-1) unstable; urgency=medium
+
+ * Snapshot, taken from the trunk (20190727).
+ - Fix PR ld/24832. Closes: #932287.
+ * Build ppc64el packages on arm64.
+ * Build s390x packages on arm64 and ppc64el.
+ * Build riscv64 packages on arm64 and ppc64el. Closes: #932398.
+ * Bump standards version.
+
+ -- Matthias Klose <doko@debian.org> Sat, 27 Jul 2019 16:58:37 +0200
+
+binutils (2.32.51.20190707-1) unstable; urgency=medium
+
+ * Snapshot, taken from the trunk (20190707).
+
+ -- Matthias Klose <doko@debian.org> Sun, 07 Jul 2019 12:20:11 +0200
+
+binutils (2.32.51.20190701-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20190701).
+
+ -- Matthias Klose <doko@debian.org> Mon, 01 Jul 2019 13:46:05 +0200
+
+binutils (2.32.51.20190624-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20190624).
+ - Fix PR ld/24704, skiboot link failure. LP: #1833237.
+
+ -- Matthias Klose <doko@debian.org> Mon, 24 Jun 2019 07:59:05 +0000
+
+binutils (2.32.51.20190611-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20190611).
+ * Simplify setting the soname for the various builds.
+
+ -- Matthias Klose <doko@debian.org> Tue, 11 Jun 2019 10:48:30 +0200
+
+binutils (2.32-8) experimental; urgency=medium
+
+ * Snapshot, taken from the 2.32 branch (20190424).
+ - Fix PR ld/24302 (AArch64): When DF_BIND_NOW don't use TLSDESC GOT value.
+ - Fix PR ld/24458 (x86): Also check x86 linker_def for non-shared
+ definition.
+ - AArch64: Add new LDGM/STGM instruction.
+ - AArch64: Update Store Allocation Tag instructions.
+ - AArch64: Fix disassembler bug with out-of-order sections.
+
+ -- Matthias Klose <doko@debian.org> Wed, 24 Apr 2019 09:25:48 +0200
+
+binutils (2.32-7) experimental; urgency=medium
+
+ * Snapshot, taken from the 2.32 branch (20190321).
+ - Fix PR ld/24355, segfault in function called from ppc_finish_symbols.
+ * Demote binutils-<target> from Multi-Arch: foreign to Multi-Arch: allowed
+ (Helmut Grohne). Closes: #920286.
+ * Let binutils-for-host Depends: binutils-<host>:any.
+
+ -- Matthias Klose <doko@debian.org> Thu, 21 Mar 2019 16:23:32 +0100
+
+binutils (2.32-6) experimental; urgency=medium
+
+ * Snapshot, taken from the 2.32 branch (20190313).
+ - S/390: arch13 instruction descriptions.
+ * Fix VCS attributes in the control file. Closes: #915982.
+
+ -- Matthias Klose <doko@debian.org> Wed, 13 Mar 2019 16:12:45 +0100
+
+binutils (2.32-5) experimental; urgency=medium
+
+ * Snapshot, taken from the 2.32 branch (20190213).
+ - S390: Revert "Add support to GNU ld to separate got related plt entries".
+ * binutils-source: Redact the build directory out of the tarball paths.
+ (Andrej Shadura). Closes: #920797.
+
+ -- Matthias Klose <doko@debian.org> Wed, 06 Mar 2019 11:11:50 +0100
+
+binutils (2.32-4) experimental; urgency=medium
+
+ * Remove mips64 build/check dependency.
+ * Fix PR binutils/23843, taken from the trunk.
+ * Fix PR ld/24276, taken from the trunk. Addresses: #923246.
+
+ -- Matthias Klose <doko@debian.org> Wed, 27 Feb 2019 22:34:34 +0100
+
+binutils (2.32-3) experimental; urgency=medium
+
+ * Snapshot, taken from the 2.32 branch (20190213).
+ - Fix PR ld/24151, PR gas/24165.
+ * Stop building cross packages now built by binutils-mipsen.
+
+ -- Matthias Klose <doko@debian.org> Wed, 13 Feb 2019 10:47:43 +0100
+
+binutils (2.32-2) experimental; urgency=medium
+
+ * Snapshot, taken from the 2.32 branch (20190208).
+ - Make inline plt reloc "unsupported for bss-plt" an error (ppc32).
+ - Arm: Backport hlt to all architectures.
+ - SPARC: fix PR ld/18841 (ld test failures).
+ - Visium: fix bogus overflow check on 32-bit hosts.
+ - Visium: align branch absolute instruction for the GR6.
+ * Stop building packages for powerpcspe.
+
+ -- Matthias Klose <doko@debian.org> Sat, 09 Feb 2019 13:12:21 +0100
+
+binutils (2.32-1) experimental; urgency=medium
+
+ * New upstream version.
+
+ -- Matthias Klose <doko@debian.org> Sun, 03 Feb 2019 10:34:56 +0100
+
+binutils (2.31.90.20190119-1) experimental; urgency=medium
+
+ * Snapshot, taken from the binutils 2.32 branch (20190119).
+
+ -- Matthias Klose <doko@debian.org> Sat, 19 Jan 2019 18:30:02 +0100
+
+binutils (2.31.51.20181204-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20181204).
+
+ -- Matthias Klose <doko@debian.org> Tue, 04 Dec 2018 11:20:13 +0100
+
+binutils (2.31.51.20181022-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20181022).
+ * Refresh patches.
+
+ -- Matthias Klose <doko@debian.org> Mon, 22 Oct 2018 12:08:04 +0200
+
+binutils (2.31.1-10) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20181130).
+ - Fix PR ld/23937, powerpc64le local ifunc IRELATIVE relocs are wrong.
+
+ -- Matthias Klose <doko@debian.org> Fri, 30 Nov 2018 13:20:30 +0100
+
+binutils (2.31.1-9) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20181127).
+ - Fix Pr ld/23904, regression in Cortex A53 erratum with PIE.
+ Closes: #911497.
+
+ -- Matthias Klose <doko@debian.org> Tue, 27 Nov 2018 14:25:35 +0100
+
+binutils (2.31.1-8) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20181121).
+ - Fix PR gas/23854 (x86): Disable GOT relaxation with data prefix.
+ - Fix PR ld/23818, when assigning symbol version, hide debug symbols defined
+ in discarded sections from IR objects so that they can be removed later.
+ - ARC updates.
+ - ARM: Skip new binary decode tests on pe targets.
+ - ARM: Fix disassembler crashing on -b binary when thumb file and thumb not
+ forced.
+
+ -- Matthias Klose <doko@debian.org> Fri, 23 Nov 2018 09:02:12 +0100
+
+binutils (2.31.1-7) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20181018).
+ - AArch64: Fix error checking for SIMD udot (by element).
+ - x86: Add Intel ENCLV to assembler and disassembler.
+
+ -- Matthias Klose <doko@debian.org> Thu, 18 Oct 2018 08:54:07 +0200
+
+binutils (2.31.1-6) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20180919).
+ - PR ld/23499: elf: Check for corrupt symbol version info.
+ - Fix Aarch64 bug in warning filtering.
+ - Improve the code in the assembler to detect and reject a duplicate
+ input and output file.
+ * Don't reset CROSS_ARCHS when building in an autopkg tests (as done by
+ the cross-toolchain-base build test).
+
+ -- Matthias Klose <doko@debian.org> Wed, 19 Sep 2018 13:48:13 +0200
+
+binutils (2.31.1-5) unstable; urgency=medium
+
+ * Fix the "build" autopkg test, depending on fakeroot and allowing output
+ on stderr.
+
+ -- Matthias Klose <doko@debian.org> Fri, 31 Aug 2018 11:56:41 +0200
+
+binutils (2.31.1-4) unstable; urgency=medium
+
+ * Rewrite. the "build" autopkg tests not to use the "build-needed"
+ restriction until #906125 is fixed. Closes: #884117.
+ * Build armel and armhf cross binutils on ppc64el.
+
+ -- Matthias Klose <doko@debian.org> Tue, 14 Aug 2018 20:43:44 +0200
+
+binutils (2.31.1-3) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20180814).
+ - Fix PR ld/23428, properly add X86_ISA_1_NEEDED property.
+ - Fix PR ld/23486, properly merge GNU_PROPERTY_X86_ISA_1_USED.
+ - x32: Align the .note.gnu.property section to 4 bytes.
+ - PowerPC64 __tls_get_addr_opt stub .eh_frame fix.
+ - PowerPC64: __tls_get_addr_opt stubs and tocsave optimization.
+ - PR gas/23465, x86: don't mistakenly scale non-8-bit displacements.
+ - PR gold/23455, add --warn-drop-version option; by default, do not warn
+ when discarding version info.
+ - hppa: Fix unwind offset for call_info->start_symbol.
+ * Build arm64 cross binutils on ppc64el.
+
+ -- Matthias Klose <doko@debian.org> Tue, 14 Aug 2018 07:33:39 +0200
+
+binutils (2.31.1-2) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20180726).
+ - S/390: Set the htm flag on PPA.
+ - x86: Add a GNU_PROPERTY_X86_ISA_1_USED note if needed.
+ - x86: Split vcvtps2{,u}qq and vcvttps2{,u}qq.
+
+ -- Matthias Klose <doko@debian.org> Thu, 26 Jul 2018 12:23:07 +0200
+
+binutils (2.31.1-1) unstable; urgency=medium
+
+ * Binutils 2.31.1 release.
+ * Remove the riscv64 build hack. Closes: #903857.
+
+ -- Matthias Klose <doko@debian.org> Wed, 18 Jul 2018 11:58:00 +0200
+
+binutils (2.31-1) unstable; urgency=medium
+
+ * Binutils 2.31 release.
+
+ -- Matthias Klose <doko@debian.org> Mon, 16 Jul 2018 11:40:18 +0200
+
+binutils (2.30.90.20180710-1) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20180710).
+ - Fix PR ld/23388, configuration with --enable-separate-code on i386.
+ Closes: #903376.
+ - Fix PR ld/23372, Remove x86 ISA properties with empty bits.
+ - Fix PR binutils/23369, read/write flag for these registers on AArch64.
+ - Fix PR binutils/23242, SBO bit in disassembly mask for ldrah on AArch64.
+ - [GOLD] PowerPC .gnu.attributes support.
+ - CVE-2018-8945: PR binutils/22809, objdump segfault.
+
+ -- Matthias Klose <doko@debian.org> Tue, 10 Jul 2018 11:44:16 +0200
+
+binutils (2.30.90.20180705-1) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20180705).
+ - Install the diagnostics.h header. Closes: #902765, #902823.
+
+ -- Matthias Klose <doko@debian.org> Thu, 05 Jul 2018 17:55:14 +0200
+
+binutils (2.30.90.20180627-1) unstable; urgency=medium
+
+ * Snapshot, taken from the 2.31 branch (20180627).
+ - CVE-2018-10372: PR binutils/23064, Fix illegal memory access when parsing
+ corrupt DWARF information.
+ - CVE-2018-10373: PR binutils/23065, nm segfault.
+ - CVE-2018-10534: PR binutils/23110, objcopy segfault.
+ - CVE-2018-10535: PR binutils/23113, objcopy segfault.
+
+ -- Matthias Klose <doko@debian.org> Wed, 27 Jun 2018 21:55:43 +0200
+
+binutils (2.30.52.20180613-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20180613).
+
+ -- Matthias Klose <doko@debian.org> Wed, 13 Jun 2018 14:20:30 +0200
+
+binutils (2.30.51.20180512-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20180512).
+
+ -- Matthias Klose <doko@debian.org> Sat, 12 May 2018 11:45:10 -0400
+
+binutils (2.30-22) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180622.
+ - x86 gas: Replace CET bit with IBT and SHSTK bits.
+
+ -- Matthias Klose <doko@debian.org> Fri, 22 Jun 2018 08:11:21 +0200
+
+binutils (2.30-21) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180529.
+ - x86-64: Add TLSDESC fields to elf_x86_lazy_plt_layout.
+ - PR binutils/23199, mark section in a section group with SHF_GROUP.
+ - PR ld/23194, x86: Don't set eh->local_ref to 1 for versioned symbol.
+ - PR ld/23189, x86: Don't set eh->local_ref to 1 for linker defined symbols.
+ - PR binutils/23199, Invalid SHT_GROUP entry leads to group confusion.
+ * Fix PR gprof/23056, memory corruption in gprof. LP: #1763098.
+ * Fix PR binutils/23054, memory corruption in as. LP: #1763096.
+ * Fix PR ld/23055, memory corruption in ld. LP: #1763094.
+
+ -- Matthias Klose <doko@debian.org> Tue, 29 May 2018 15:46:35 +0200
+
+binutils (2.30-20) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180516.
+ - Fix PR binutils/23109, disassembly mask for vector sdot on AArch64.
+ - Fix uninitialised memory acccess in COFF bfd backend.
+ - Update Portuguese translations.
+
+ -- Matthias Klose <doko@debian.org> Wed, 16 May 2018 10:21:19 -0400
+
+binutils (2.30-19) unstable; urgency=medium
+
+ * Build-depend on procps.
+
+ -- Matthias Klose <doko@debian.org> Thu, 03 May 2018 07:44:55 +0200
+
+binutils (2.30-17) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180502.
+ - Fix PR ld/23123, PR ld/22374, PowerPC32 ifunc regression.
+ - AArch64: Fix the mask for the sqrdml(a|s)h instructions.
+ * Fix unintialized memory in aarch64 opcodes, taken from the trunk.
+
+ -- Matthias Klose <doko@debian.org> Wed, 02 May 2018 14:11:28 +0200
+
+binutils (2.30-16) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180425.
+ - Fix PR ld 22782, x86: Remove the unused _GLOBAL_OFFSET_TABLE_.
+ - Update spanish and russian translations.
+ * Add amd64, i386, x32 and riscv64 cross compilers as build (test)
+ dependencies.
+
+ -- Matthias Klose <doko@debian.org> Wed, 25 Apr 2018 06:53:58 +0200
+
+binutils (2.30-15) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180408.
+ * Only build the basic package when running the autopkg tests.
+ Closes: #884117.
+
+ -- Matthias Klose <doko@debian.org> Sun, 08 Apr 2018 22:55:34 +0200
+
+binutils (2.30-14) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180405.
+ - Fix PR binutils/23025, Clear vex instead of vex.evex (x86).
+ * Fix PR gold/22770, MIPS: Fix GOT page counter in multi-got links,
+ taken from the trunk. Closes: #886222.
+ * Fix PR ld/23030 (stop the IA64 linker from removing unwind tables
+ when garbage collecting), taken from the trunk. Closes: #894915, #894719.
+ * More work arounds to build natively on riscv64.
+
+ -- Matthias Klose <doko@debian.org> Thu, 05 Apr 2018 19:13:24 +0200
+
+binutils (2.30-13) unstable; urgency=medium
+
+ * Build cross binutils for i386 and x32 on arm64 and ppc64el.
+
+ -- Matthias Klose <doko@debian.org> Wed, 04 Apr 2018 10:32:15 +0200
+
+binutils (2.30-11) unstable; urgency=medium
+
+ * Filter out the host architecture when passed as a cross architecture.
+
+ -- Matthias Klose <doko@debian.org> Sun, 01 Apr 2018 17:01:49 +0200
+
+binutils (2.30-10) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180330.
+ - Fix PR 22773, ARM assembler's parsing of an illegal ORR instruction.
+ - Fix PR gold/22868, PR ld/22972 on SPARC, .
+ - PR ld/23000, x86-64: Add ENDBR64 to the TLSDESC PLT entry.
+
+ -- Matthias Klose <doko@debian.org> Fri, 30 Mar 2018 18:55:59 +0800
+
+binutils (2.30-9) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180325.
+ - Fix PowerPC64 out-of-line save/restore functions.
+ - Remove unnecessary power9 group terminating nop.
+ - Set non_ir_ref_dynamic if a symbol is made dynamic.
+ - Fix PR ld/22836, "-r -s" doesn't work with -g3 using GCC 7.
+ * Fix amd64, i386 and x32 cross builds.
+
+ -- Matthias Klose <doko@debian.org> Sun, 25 Mar 2018 14:53:41 +0800
+
+binutils (2.30-8) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180318.
+ - [ARM] Fix bxns mask.
+ - Extend the fix for PR ld/20882.
+ * Fix PowerPC64 out-of-line save/restore functions. Closes: #886264.
+ * Revert the 2.30-7 change.
+
+ -- Matthias Klose <doko@debian.org> Sun, 18 Mar 2018 12:51:40 +0800
+
+binutils (2.30-7) unstable; urgency=medium
+
+ * Upload without build dependencies on the cross compilers and don't run
+ the testsuite for this upload.
+
+ -- Matthias Klose <doko@debian.org> Thu, 08 Mar 2018 12:04:10 +0700
+
+binutils (2.30-6) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180308.
+ - Fix PR ld/15904, linker error with --no-keep-memory.
+ - Enable link time garbage collection for the IA64 target. Closes: #890909.
+ - Fix PR gas/22014, memory corruption in MIPS assembler.
+ - Fix PR ld/22758, a bug that would place executable and non-executables
+ pages in the same segment.
+ - Fix PR ld/22832 on SPARC.
+ - Fix AArch32 build attributes for Armv8.4-A.
+ - Update translations.
+ * CVE-2018-7208: Fix PR binutils/22741, taken from the trunk.
+ * CVE-2018-7568: Fix PR binutils/22894, taken from the trunk.
+ * CVE-2018-7569: Fix PR binutils/22895, taken from the trunk.
+ * CVE-2018-7642: Fix PR binutils/22887, taken from the trunk.
+ * CVE-2018-7643: Fix PR binutils/22905, taken from the trunk.
+ * CVE-2018-7570: PR binutils/22881 needs a proper backport.
+ * Update package descriptions for binutils-<target>. Closes: #891377.
+ * Build binutils-for-host for TARGET (Helmut Grohne). Closes: #891863.
+
+ -- Matthias Klose <doko@debian.org> Thu, 08 Mar 2018 09:56:54 +0700
+
+binutils (2.30-5) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180215.
+ - gas: xtensa: fix trampoline placement.
+ - Fix PR gas/22738 (.dc.a directive has wrong size on SPARC 64-bit).
+ - Fix GOT relocation overflow on SPARC. Closes: #890359.
+ * strings --include-all-whitespace doesn't take an argument. Closes: #887894.
+
+ -- Matthias Klose <doko@debian.org> Thu, 15 Feb 2018 08:20:04 +0700
+
+binutils (2.30-4) unstable; urgency=high
+
+ * Update, taken from the 2.30 branch 20180209.
+ - Fix PR binutils/22788 (CVE-2018-6872).
+ * binutils-multiarch: Add riscv64 support.
+ * Bump dpkg version to a version supporting riscv64.
+
+ -- Matthias Klose <doko@debian.org> Fri, 09 Feb 2018 19:24:28 +0100
+
+binutils (2.30-3) unstable; urgency=high
+
+ * Update, taken from the 2.30 branch 20180208.
+ - Remove speculation barrier support, remove --speculate-indirect-jumps
+ support (PPC).
+ - Fix PR ld/22764.
+ * CVE-2018-6323: Fix PR binutils/22746, taken from the trunk.
+ * CVE-2018-6543: Fix PR binutils/22769, taken from the trunk.
+ * CVE-2018-6759: Fix PR binutils/22794, taken from the trunk.
+ * Build riscv64 cross packages. This is using a hack, making binutils
+ not building natively on riscv64. At the mercy of a dpkg update
+ to handle riscv64 in stretch ...
+
+ -- Matthias Klose <doko@debian.org> Thu, 08 Feb 2018 10:22:10 +0100
+
+binutils (2.30-2) unstable; urgency=medium
+
+ * Update, taken from the 2.30 branch 20180205.
+ - Fix PR ld/22762.
+ - gold: Add support for DWARF-4 line number tables.
+ - Update Brazillian portuguese and Russian translations.
+ * Apply approved patch for PR ld/22764 (AArch64). LP: #1746765.
+ Closes: #888789.
+ * Fix PR binutils/22734, taken from the trunk. Closes: #887729.
+
+ -- Matthias Klose <doko@debian.org> Mon, 05 Feb 2018 16:22:40 +0100
+
+binutils (2.30-1) unstable; urgency=medium
+
+ * Binutils 2.30 release.
+
+ -- Matthias Klose <doko@debian.org> Mon, 29 Jan 2018 14:29:38 +0100
+
+binutils (2.29.90.20180122-1) unstable; urgency=medium
+
+ * Snapshot, taken from the binutils 2.30 branch (20180122).
+ * Security issues addressed in 2.30: CVE-2017-13716, CVE-2017-14930,
+ CVE-2017-14932, CVE-2017-14933, CVE-2017-14934, CVE-2017-14938,
+ CVE-2017-14939, CVE-2017-14940, CVE-2017-15020, CVE-2017-15021,
+ CVE-2017-15022, CVE-2017-15023, CVE-2017-15024, CVE-2017-15025,
+ CVE-2017-15225, CVE-2017-15938, CVE-2017-15996, CVE-2017-16826,
+ CVE-2017-16827, CVE-2017-16828, CVE-2017-16829, CVE-2017-16830,
+ CVE-2017-16831, CVE-2017-16832, CVE-2017-17080, CVE-2017-17121,
+ CVE-2017-17122, CVE-2017-17123, CVE-2017-17124, CVE-2017-17125,
+ CVE-2017-17126.
+
+ -- Matthias Klose <doko@debian.org> Tue, 23 Jan 2018 04:11:38 +0100
+
+binutils (2.29.51.20180110-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20180110).
+
+ -- Matthias Klose <doko@debian.org> Wed, 10 Jan 2018 16:54:44 +0100
+
+binutils (2.29.51.20171219-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20171219).
+
+ -- Matthias Klose <doko@debian.org> Tue, 19 Dec 2017 14:50:11 +0100
+
+binutils (2.29.51.20171208-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20171208).
+ * binutils-source: Depend on python3 instead of python.
+ * Override m68k, powerpcspe and m68k buildd admins to run the testsuite.
+ * Build binutils-x86-64-linux-gnu on arm64 and ppc64el. See #883769.
+ * Revived from the tombs, build a binutils-ia64-linux-gnu package.
+
+ -- Matthias Klose <doko@debian.org> Fri, 08 Dec 2017 15:19:09 +0100
+
+binutils (2.29.51.20171128-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20171128).
+
+ -- Matthias Klose <doko@debian.org> Tue, 28 Nov 2017 08:59:33 +0100
+
+binutils (2.29.1-13) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20180105.
+ - Fix PR ld/22626, invalid dynindx used for dynamic relocs against
+ section symbols.
+ * Fix cross builds, use host tools (Helmut Grohne). Closes: #883865.
+
+ -- Matthias Klose <doko@debian.org> Fri, 05 Jan 2018 23:44:48 +0100
+
+binutils (2.29.1-12) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20171212.
+ - Fix PR binutils/21118, don't mask X_add_number containing
+ a register number.
+ * Revived from the tombs, build a binutils-ia64-linux-gnu package.
+
+ -- Matthias Klose <doko@debian.org> Wed, 13 Dec 2017 01:10:25 +0100
+
+binutils (2.29.1-11) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20171208.
+ - Fix PR gold/22309.
+ * Build binutils-x86-64-linux-gnu on arm64 and ppc64el. See #883769.
+
+ -- Matthias Klose <doko@debian.org> Fri, 08 Dec 2017 12:41:16 +0100
+
+binutils (2.29.1-10) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20171201.
+ - Fix PR gold/22233, segfault in relocate_erratum_stub on aarch64.
+ - Update local fix for PR gold/20765, internal error in fix_errata on
+ aarch64 (Peter Smith). LP: #1638902.
+ * binutils-source: Depend on python3 instead of python.
+ * Override m68k, powerpcspe and m68k buildd admins to run the testsuite.
+
+ -- Matthias Klose <doko@debian.org> Fri, 01 Dec 2017 02:34:24 +0100
+
+binutils (2.29.1-9) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20171128.
+ - Fix PR ld/22431, powerpc64 ld segfault when .plt discarded.
+ - Fix DWARF reader to use correct size for DW_FORM_ref_addr.
+
+ -- Matthias Klose <doko@debian.org> Tue, 28 Nov 2017 07:02:24 +0100
+
+binutils (2.29.1-8) unstable; urgency=medium
+
+ * Apply proposed patch for PR gold/22233. Closes: #876786.
+
+ -- Matthias Klose <doko@debian.org> Mon, 13 Nov 2017 15:45:39 +0100
+
+binutils (2.29.1-7) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20171107.
+ - Fix PR ld/22397, PR ld/22300, PR binutils/22348.
+ * Use dwz -m to compress the -dbg packages.
+ * Add a plethora of mips r6 packages ... Closes: #881060.
+ * Provide "long" description for -dbg packages. Closes: #880001.
+
+ -- Matthias Klose <doko@debian.org> Wed, 08 Nov 2017 12:17:38 +0100
+
+binutils (2.29.1-6) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20171022.
+ - [GOLD] Fix powerpc64 optimization of TOC accesses.
+ * Do the extra/optional dance ...
+ * Build debug packages. Closes: #863728.
+ * Fix stripping the binutils-<native triplet> packages.
+
+ -- Matthias Klose <doko@debian.org> Sun, 22 Oct 2017 22:41:34 +0200
+
+binutils (2.29.1-5) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20171017.
+ - Fix PR binutils/22245, undefined behavior in bfd_set_error.
+ - Correct ctor/dtor in init_array/fini_array error value.
+ * Stop installing i586 compat links for i386 builds. Closes: #877791.
+ * Build a binutils-i686-linux-gnu package on amd64 and x32 too.
+
+ -- Matthias Klose <doko@debian.org> Tue, 17 Oct 2017 11:29:33 +0200
+
+binutils (2.29.1-4) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20171001.
+ - PR ld/22220, BFD linker wrongly marks symbols as PREVAILING_DEF_IRONLY.
+ - PR ld/22199, x86-64: Don't pass output_bfd to info->callbacks->minfo.
+ - [GOLD] Set non-exec stack for ppc64.
+ * Move man/{go,}ld.1.gz to binutils-common (Helmut Grohne). Closes: #877266.
+ * Build-depend on target g++ compilers instead of target gcc compilers.
+ * Fail when string merge can't alloc memory, taken from the trunk.
+ Closes: #874674.
+ * Fix legacy cross builds. Closes: #876677.
+
+ -- Matthias Klose <doko@debian.org> Sun, 01 Oct 2017 20:16:22 +0200
+
+binutils (2.29.1-3) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170923.
+ - gold: Add --no-relax option.
+ - readelf: Handle E_MIPS_MACH_5900.
+ - gold: PowerPC function address in non-PIC.
+ - Fix PR binutils/22163, PR binutils/22170.
+ * libbinutils: Fix generation of upper dependency for two-number versions.
+ * debian/rules. Remove the old cross build targets.
+
+ -- Matthias Klose <doko@debian.org> Sat, 23 Sep 2017 14:00:50 +0200
+
+binutils (2.29.1-1) unstable; urgency=medium
+
+ * binutils 2.29.1 release.
+ * Convert to package source format 3.0 (quilt).
+
+ -- Matthias Klose <doko@debian.org> Wed, 20 Sep 2017 10:11:56 +0200
+
+binutils (2.29-13) unstable; urgency=medium
+
+ * Build again all cross packages.
+
+ -- Matthias Klose <doko@debian.org> Tue, 19 Sep 2017 13:11:06 +0200
+
+binutils (2.29-12) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170919.
+ - Fix PR ld/21441, PowerPC64 stubs don't match calculated size.
+ Closes: #876134.
+ - Fix PR ld/22048, Incorrect .eh_frame section in libc.so.
+ - Fix PR ld/22150, ld keeps a version reference for gc'd symbols.
+ Closes: #874585. LP: #1715641.
+ - Fix PR ld/22148, Integer overflow in elf64-x86-64.c.
+ - Fix PR ld/21924, Require GCC 5 or above for 3 x86 tests.
+ * Fix installation of test summaries.
+ * Compare test summaries for cross builds.
+
+ -- Matthias Klose <doko@debian.org> Tue, 19 Sep 2017 13:04:07 +0200
+
+binutils (2.29-10) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170915.
+ - Fix PR binutils/22047 (CVE-2017-14129), PR binutils/22018.
+ * gold on 32bit archs: Release mapped files after each pass.
+ * Build-depend on cross compilers to run the tests for the binutils
+ cross packages.
+ * Install the ldscripts into /usr/lib/<multiarch>/ldscripts and move
+ ldscripts into the binutils-<triplet> packages.
+ * Install the unprefixed manual packages into binutils-common and
+ derive the timestamps from the debian/changelog entry.
+ * binutils-<triplet>: Remove dependency on binutils.
+
+ -- Matthias Klose <doko@debian.org> Fri, 15 Sep 2017 11:55:58 +0200
+
+binutils (2.29-9) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170906.
+ - Fix PR binutils/22032, PR binutils/21786 (CVE-2017-12451),
+ PR binutils/21787 (CVE-2017-12448), PR binutils/21813 (CVE-2017-12450,
+ CVE-2017-12452, CVE-2017-12453, CVE-2017-12454), PR ld/21824,
+ PR binutils/21916, PR ld/21441, PR ld/22067, PR ld/22064, PR ld/22061,
+ PR binutils/22059 (CVE-2017-14128), PR binutils/21933 (CVE-2017-12799),
+ PR binutils/22060, PR binutils/22058 (CVE-2017-14130), PR binutils/21995,
+ PR binutils/21861, PR binutils/21813 (CVE-2017-12456), PR binutils/21909,
+ PR binutils/21820, PR binutils/21990, PR binutils/21994, PR ld/21441,
+ PR ld/22064, PR ld/22061, PR lto/81968, PR lto/81968, PR lto/81925.
+ * Fix typo in control.in interpolation when TARGET is non-empty (Helmut
+ Grohne). Addresses: #873387.
+
+ -- Matthias Klose <doko@debian.org> Wed, 06 Sep 2017 08:14:12 +0200
+
+binutils (2.29-8) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170830.
+ - Fix PR gold/21868. Closes: #830540, #869768.
+ - Fix address violation issues when parsing corrupt binaries.
+ - PR gold/21847: Provide symbol flag for PowerPC64 localentry:0 tracking.
+
+ -- Matthias Klose <doko@debian.org> Wed, 30 Aug 2017 08:03:09 +0200
+
+binutils (2.29-7) unstable; urgency=high
+
+ * Fix binutils dependency on binutils-<triplet> on non amd64 architectures.
+
+ -- Matthias Klose <doko@debian.org> Wed, 23 Aug 2017 23:51:26 +0200
+
+binutils (2.29-6) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170823.
+ - Fix PR ld/21988, PR ld/21964, PR ld/21910.
+ * readelf: Add patch to read Infinity notes.
+ * Reorganize packages to provide binutils-for-host/binutils-for-build
+ packages (Helmut Grohne). Closes: #842439.
+ - Break out a binutils-common package.
+ - Refactor code to build with DEB_BUILD_OPTIONS=nogold.
+ - Rename gold, ld.gold, ld.bfd to their triplet prefixed equivalents.
+ - Remove shlibs files for hppa64 and cross packages.
+ - Set NATIVE_ARCHS explicitly.
+ - Split out a libbinutils package and binutils-<triplet> packages.
+ - Build binutils-for-host and binutils-for-build packages.
+ * Fix some issues in the above patches.
+ * Mark binutils-common and libbinutils as M-A: same.
+ * Remove obsolete Breaks/Conflicts/Replaces.
+ * Replace FIXME markers with TODO markers. Silly lintian ...
+
+ -- Matthias Klose <doko@debian.org> Wed, 23 Aug 2017 12:01:12 +0200
+
+binutils (2.29-5) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170820.
+ - Fix PR binutils/21962, buffer overrun when parsing a corrupt tekhex
+ binary.
+ - Fix PR ld/18808: [AArch64] Skip IFUNC relocations in debug sections.
+ - Fix PR ld/18841: [AArch64] ifunc relocation ordering.
+ - [AArch64] Turn lr, fp, ip0 and ip1 into proper aliases.
+ - Fix PR ld/21923.
+ * Build gold on s390x. LP: #1709873.
+
+ -- Matthias Klose <doko@debian.org> Sun, 20 Aug 2017 19:00:03 +0200
+
+binutils (2.29-4) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170804.
+ * Fix PR ld/21884, taken from the trunk. Do not choose a non-ELF format
+ input file to hold the linker created GOT sections. Closes: #870611.
+
+ -- Matthias Klose <doko@debian.org> Mon, 07 Aug 2017 08:46:12 -0400
+
+binutils (2.29-3) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170802.
+ - S390 testsuite fixes.
+ * Fix PR ld/21884, taken from the trunk. Closes: #870343.
+
+ -- Matthias Klose <doko@debian.org> Wed, 02 Aug 2017 14:16:35 +0200
+
+binutils (2.29-2) unstable; urgency=medium
+
+ * Update, taken from the 2.29 branch 20170731.
+ - Fix PR 21847, PowerPC64 --plt-localentry issues.
+ - Fix PR gold/21857, PR ld/21849 (AVR).
+ * Remove Daniel as an uploader. Closes: #869305.
+
+ -- Matthias Klose <doko@debian.org> Mon, 31 Jul 2017 09:17:30 +0200
+
+binutils (2.29-1) unstable; urgency=medium
+
+ * binutils 2.29 release.
+
+ -- Matthias Klose <doko@debian.org> Tue, 25 Jul 2017 11:02:19 +0200
+
+binutils (2.28.90.20170718-1) experimental; urgency=medium
+
+ * Snapshot, taken from the 2.29 branch (20170718).
+
+ -- Matthias Klose <doko@debian.org> Tue, 18 Jul 2017 11:26:15 +0200
+
+binutils (2.28.51.20170703-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20170703).
+ - Addresses CVE-2017-9040, CVE-2017-9042, CVE-2017-9043, CVE-2017-9044,
+ CVE-2017-9742, CVE-2017-9743, CVE-2017-9744, CVE-2017-9745,
+ CVE-2017-9746, CVE-2017-9747, CVE-2017-9748, CVE-2017-9749,
+ CVE-2017-9750, CVE-2017-9751, CVE-2017-9752, CVE-2017-9753,
+ CVE-2017-9754, CVE-2017-9755, CVE-2017-9756, CVE-2017-9954,
+ CVE-2017-9955. Closes: #863674.
+
+ -- Matthias Klose <doko@debian.org> Mon, 03 Jul 2017 16:08:53 +0200
+
+binutils (2.28.51.20170627-1) experimental; urgency=high
+
+ * Snapshot, taken from the trunk (20170627).
+
+ -- Matthias Klose <doko@debian.org> Tue, 27 Jun 2017 14:53:24 +0200
+
+binutils (2.28.51.20170620-1) experimental; urgency=medium
+
+ * Snapshot, taken from the trunk (20170620).
+ - Addresses issues CVE-2017-9040, CVE-2017-9042, CVE-2017-9043.
+ - ILP32 patches applied upstream. Closes: #861833.
+ - Fixes PR ld/21334 (MIPS), undefined hidden symbols causing assertion
+ failure. Closes: #858898.
+ * Configure with --enable-new-dtags.
+ * Don't revert the commit causing PR 21074.
+
+ -- Matthias Klose <doko@debian.org> Tue, 20 Jun 2017 15:32:31 +0200
+
+binutils (2.28-6) unstable; urgency=medium
+
+ * Update, taken from the 2.28 branch 20170615.
+ - Fix PR ld/19579 (AArch64), handling of relocations against common symbols.
+ Closes: #863152.
+ - Fix PR ld/21523 (ARM32).
+ - Fix PR ld/21529 (ARM32), internal error in linker.
+ - Fix PR ld/21404 (AVR).
+ - Fix PR binutils/21034.
+ - Fix PR gold/21503, gold not creating linker stub symbols on ppc64.
+ - Remove linker option: -z prefix-nop (x86).
+ * Fix several crashes. Addresses: #863674.
+ - PR binutils/21343, readelf crash. CVE-2017-9038.
+ - PR binutils/21345, readelf crash. CVE-2017-9039.
+ - PR binutils/21344, readelf crash. CVE-2017-9041.
+
+ -- Matthias Klose <doko@debian.org> Thu, 15 Jun 2017 17:46:47 +0200
+
binutils (2.28-5+dyson1) unstable; urgency=medium
* Package for Dyson
@@ -8,7 +894,7 @@ binutils (2.28-5) unstable; urgency=medium
* Update, taken from the 2.28 branch 20170510.
- RISC-V updates.
- - Fix PR ld/21334 (MIPS),
+ - Fix PR ld/21334 (MIPS).
- VxWorks fix.
- Fix PR ld/16044 (CRIS).
* Fix PR binutils/21412, global-buffer-overflow in objcopy. CVE-2017-8393.
diff --git a/debian/control b/debian/control
index 38e66b8..12dcfc0 100644
--- a/debian/control
+++ b/debian/control
@@ -2,29 +2,63 @@ Source: binutils
Section: devel
Priority: optional
Maintainer: Matthias Klose <doko@debian.org>
-Uploaders: James Troup <binutils@elmo.tasta.io>, Daniel Jacobowitz <dan@debian.org>
-Standards-Version: 3.9.8
-Build-Depends: autoconf (>= 2.64), dpkg-dev (>= 1.17.11),
- bison, flex, gettext, texinfo, dejagnu, quilt, chrpath,
- python3:any, file, xz-utils, lsb-release, zlib1g-dev
+Uploaders: James Troup <binutils@elmo.tasta.io>
+Standards-Version: 4.4.1
+Build-Depends: autoconf (>= 2.64), dpkg-dev (>= 1.19.0.5),
+ bison, flex, gettext, texinfo, dejagnu, quilt, chrpath, dwz,
+ python3:any, file, xz-utils, lsb-release, zlib1g-dev, procps,
+ g++-aarch64-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-arm-linux-gnueabi [amd64 arm64 i386 x32] <!nocheck>,
+ g++-arm-linux-gnueabihf [amd64 arm64 i386 x32] <!nocheck>,
+ g++-powerpc64le-linux-gnu [amd64 arm64 i386 ppc64 x32] <!nocheck>,
+ g++-s390x-linux-gnu [amd64 arm64 i386 ppc64el x32] <!nocheck>,
+ g++-alpha-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-hppa-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-m68k-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-powerpc-linux-gnu [amd64 i386 ppc64el x32] <!nocheck>,
+ g++-powerpc64-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-riscv64-linux-gnu [amd64 arm64 i386 ppc64el x32] <!nocheck>,
+ g++-sh4-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-sparc64-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-i686-linux-gnu [amd64 arm64 ppc64el x32] <!nocheck>,
+ g++-x86-64-linux-gnu [arm64 i386 ppc64el] <!nocheck>,
+ g++-x86-64-linux-gnux32 [amd64 arm64 i386 ppc64el] <!nocheck>,
Build-Conflicts: libelf-dev
Homepage: https://www.gnu.org/software/binutils/
-Vcs-Browser: https://code.launchpad.net/~doko/binutils/pkg-2.28-debian
-Vcs-Bzr: http://bazaar.launchpad.net/~doko/binutils/pkg-2.28-debian
+Vcs-Browser: https://salsa.debian.org/toolchain-team/binutils
+Vcs-Git: https://salsa.debian.org/toolchain-team/binutils.git
XS-Testsuite: autopkgtest
+Package: binutils-for-host
+Architecture: any
+Depends: ${binutils:native}:any (>= ${binutils:minver}),
+ binutils-common (= ${binary:Version}),
+Multi-Arch: same
+Description: GNU assembler, linker and binary utilities for the host architecture
+ The programs in this package are used to assemble, link and manipulate
+ binary and object files for the architecture of this package. They may be
+ used in conjunction with a matching compiler and various libraries to build
+ programs. When using binutils through this metapackage, all tools must be
+ used with an architecture prefix.
+
+Package: binutils-for-build
+Architecture: all
+Depends: binutils (>= ${binutils:minver}),
+ binutils-common (>= ${binutils:minver})
+Multi-Arch: foreign
+Description: GNU assembler, linker and binary utilities for the build architecture
+ The programs in this package are used to assemble, link and manipulate
+ binary and object files for the native architecture. They may be used in
+ conjunction with a build architecture compiler and various libraries to build
+ programs. When using binutils through this metapackage, tools without an
+ architecture prefix must be used.
+
Package: binutils
Architecture: any
-Depends: ${shlibs:Depends}
-Conflicts: gas, elf-binutils, modutils (<< 2.4.19-1), ${extraConflicts},
- binutils-gold (<< 2.20.51.20100415),
+Depends: ${shlibs:Depends}, binutils-common (= ${binary:Version}),
+ libbinutils (= ${binary:Version}), ${binutils:native} (= ${binary:Version})
+Conflicts: modutils (<< 2.4.19-1), ${extraConflicts},
binutils-multiarch (<< 2.27-8)
-Breaks: binutils-mingw-w64-i686 (<< 2.23.52.20130612-1+3),
- binutils-mingw-w64-x86-64 (<< 2.23.52.20130612-1+3),
- hardening-wrapper (<< 2.8+nmu3)
-Replaces: binutils-gold (<< 2.20.51.20100415),
- binutils-mingw-w64-i686 (<< 2.23.52.20130612-1+3),
- binutils-mingw-w64-x86-64 (<< 2.23.52.20130612-1+3)
Provides: elf-binutils, ${gold:Provides}
Suggests: binutils-doc (>= ${source:Version})
Description: GNU assembler, linker and binary utilities
@@ -32,10 +66,27 @@ Description: GNU assembler, linker and binary utilities
binary and object files. They may be used in conjunction with a compiler
and various libraries to build programs.
+Package: libbinutils
+Architecture: any
+Multi-Arch: same
+Depends: ${shlibs:Depends}, binutils-common (= ${binary:Version})
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities (private shared library)
+ This package includes the private shared libraries libbfd and libopcodes.
+
+Package: libbinutils-dbg
+Section: debug
+Architecture: any
+Multi-Arch: same
+Depends: libbinutils (= ${binary:Version})
+Description: GNU binary utilities (private shared library, debug symbols)
+ This package provides debug symbols for libbinutils.
+
Package: binutils-dev
Architecture: any
-Priority: extra
-Depends: binutils (= ${binary:Version})
+Priority: optional
+Depends: binutils (= ${binary:Version}), libbinutils (= ${binary:Version})
Conflicts: libbfd-dev
Provides: libbfd-dev
Replaces: libbfd-dev, libc5-dev
@@ -47,8 +98,9 @@ Description: GNU binary utilities (BFD development files)
Package: binutils-multiarch
Architecture: any
-Priority: extra
-Depends: ${shlibs:Depends}, binutils (= ${binary:Version})
+Priority: optional
+Depends: ${shlibs:Depends}, binutils (= ${binary:Version}),
+ binutils-common (= ${binary:Version})
Description: Binary utilities that support multi-arch targets
The programs in this package are used to manipulate binary and object
files that may have been created on other architectures. This package
@@ -59,9 +111,17 @@ Description: Binary utilities that support multi-arch targets
NORMAL USERS SHOULD NOT INSTALL THIS PACKAGE. It's meant only for those
requiring support for reading info from binaries from other architectures.
+Package: binutils-multiarch-dbg
+Section: debug
+Architecture: any
+Priority: optional
+Depends: binutils-multiarch (= ${binary:Version})
+Description: Binary utilities that support multi-arch targets (debug symbols)
+ This package provides debug symbols for binutils-multiarch.
+
Package: binutils-multiarch-dev
Architecture: any
-Priority: extra
+Priority: optional
Depends: ${shlibs:Depends},
binutils-dev (= ${binary:Version}), binutils-multiarch (= ${binary:Version})
Replaces: binutils-multiarch (<< 2.24-5)
@@ -76,7 +136,8 @@ Description: GNU binary utilities that support multi-arch targets (BFD developme
Package: binutils-hppa64-linux-gnu
Architecture: amd64 i386 x32 hppa
-Depends: ${shlibs:Depends}, binutils (= ${binary:Version})
+Depends: ${shlibs:Depends}, binutils (= ${binary:Version}),
+ binutils-common (= ${binary:Version})
Recommends: libc6-dev
Provides: binutils-hppa64
Suggests: binutils-doc (>= ${source:Version})
@@ -89,13 +150,18 @@ Description: GNU assembler, linker and binary utilities targeted for hppa64-linu
.
This package is needed to build an 64-bit kernel for 64-bit hppa machines.
+Package: binutils-hppa64-linux-gnu-dbg
+Section: debug
+Architecture: amd64 i386 x32 hppa
+Depends: binutils-hppa64-linux-gnu (= ${binary:Version})
+Description: GNU binutils targeted for hppa64-linux (debug symbols)
+ This package provides debug symbols for binutils-hppa64-linux-gnu.
+
Package: binutils-doc
Section: doc
Architecture: all
Multi-Arch: foreign
Priority: optional
-Depends: dpkg (>= 1.15.4) | install-info
-Conflicts: binutils (<< 2.9.1.0.25-3)
Suggests: binutils (= ${binary:Version})
Description: Documentation for the GNU assembler, linker and binary utilities
This package consists of the documentation for the GNU assembler,
@@ -105,273 +171,849 @@ Package: binutils-source
Architecture: all
Multi-Arch: foreign
Priority: optional
-Depends: texinfo, zlib1g-dev, make, python
+Depends: texinfo, zlib1g-dev, make, python3
Description: GNU assembler, linker and binary utilities (source)
This package contains the sources and patches which are needed to
build binutils.
-Package: binutils-s390x-linux-gnu
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-common
+Architecture: any
+Multi-Arch: same
+Breaks: binutils (<< 2.29.1-3.1~)
+Replaces: binutils (<< 2.29.1-3.1~)
+Description: Common files for the GNU assembler, linker and binary utilities
+ This package contains the localization files used by binutils packages for
+ various target architectures and parts of the binutils documentation. It is
+ not useful on its own.
+
+Package: binutils-x86-64-linux-gnu
+Priority: optional
+Architecture: amd64 arm64 i386 ppc64el x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
-Description: GNU binary utilities, for s390x-linux-gnu target
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for x86-64-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for s390x-linux-gnu target, for use in a cross-compilation environment.
+ for the x86-64-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for s390x-linux-gnu.
+ for x86-64-linux-gnu and x86-64-linux-gnu is not your native platform.
-Package: binutils-powerpc64le-linux-gnu
-Architecture: amd64 i386 x32 ppc64
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
-Suggests: binutils-doc (= ${source:Version})
-Provides:
-Priority: extra
+Package: binutils-x86-64-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: amd64 arm64 i386 ppc64el x32
Multi-Arch: foreign
-Description: GNU binary utilities, for powerpc64le-linux-gnu target
- This package provides GNU assembler, linker and binary utilities
- for powerpc64le-linux-gnu target, for use in a cross-compilation environment.
- .
- You don't need this package unless you plan to cross-compile programs
- for powerpc64le-linux-gnu.
+Depends: binutils-x86-64-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for x86-64-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-x86-64-linux-gnu.
-Package: binutils-powerpc-linux-gnu
-Architecture: amd64 i386 x32 ppc64el
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-i686-linux-gnu
+Priority: optional
+Architecture: i386 amd64 arm64 ppc64el x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
-Provides:
-Priority: extra
-Multi-Arch: foreign
-Description: GNU binary utilities, for powerpc-linux-gnu target
+Provides: binutils-i586-linux-gnu
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for i686-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for powerpc-linux-gnu target, for use in a cross-compilation environment.
+ for the i686-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for powerpc-linux-gnu.
+ for i686-linux-gnu and i686-linux-gnu is not your native platform.
+
+Package: binutils-i686-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: i386 amd64 arm64 ppc64el x32
+Multi-Arch: foreign
+Depends: binutils-i686-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for i686-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-i686-linux-gnu.
Package: binutils-aarch64-linux-gnu
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Priority: optional
+Architecture: arm64 amd64 i386 x32 ppc64el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
Description: GNU binary utilities, for aarch64-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for aarch64-linux-gnu target, for use in a cross-compilation environment.
+ for the aarch64-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for aarch64-linux-gnu.
+ for aarch64-linux-gnu and aarch64-linux-gnu is not your native platform.
+
+Package: binutils-aarch64-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: arm64 amd64 i386 x32 ppc64el
+Multi-Arch: foreign
+Depends: binutils-aarch64-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for aarch64-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-aarch64-linux-gnu.
Package: binutils-arm-linux-gnueabihf
-Architecture: amd64 i386 x32 arm64
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Priority: optional
+Architecture: armhf amd64 i386 x32 arm64 ppc64el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
Description: GNU binary utilities, for arm-linux-gnueabihf target
This package provides GNU assembler, linker and binary utilities
- for arm-linux-gnueabihf target, for use in a cross-compilation environment.
+ for the arm-linux-gnueabihf target.
.
You don't need this package unless you plan to cross-compile programs
- for arm-linux-gnueabihf.
+ for arm-linux-gnueabihf and arm-linux-gnueabihf is not your native platform.
+
+Package: binutils-arm-linux-gnueabihf-dbg
+Section: debug
+Priority: optional
+Architecture: armhf amd64 i386 x32 arm64 ppc64el
+Multi-Arch: foreign
+Depends: binutils-arm-linux-gnueabihf (= ${binary:Version})
+Description: GNU binary utilities, for arm-linux-gnueabihf target (debug symbols)
+ This package provides debug symbols for binutils-arm-linux-gnueabihf.
Package: binutils-arm-linux-gnueabi
-Architecture: amd64 i386 x32 arm64
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Priority: optional
+Architecture: armel amd64 i386 x32 arm64 ppc64el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
Description: GNU binary utilities, for arm-linux-gnueabi target
This package provides GNU assembler, linker and binary utilities
- for arm-linux-gnueabi target, for use in a cross-compilation environment.
+ for the arm-linux-gnueabi target.
.
You don't need this package unless you plan to cross-compile programs
- for arm-linux-gnueabi.
+ for arm-linux-gnueabi and arm-linux-gnueabi is not your native platform.
-Package: binutils-mips-linux-gnu
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-arm-linux-gnueabi-dbg
+Section: debug
+Priority: optional
+Architecture: armel amd64 i386 x32 arm64 ppc64el
+Multi-Arch: foreign
+Depends: binutils-arm-linux-gnueabi (= ${binary:Version})
+Description: GNU binary utilities, for arm-linux-gnueabi target (debug symbols)
+ This package provides debug symbols for binutils-arm-linux-gnueabi.
+
+Package: binutils-powerpc64le-linux-gnu
+Priority: optional
+Architecture: ppc64el amd64 i386 x32 ppc64 arm64
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
-Description: GNU binary utilities, for mips-linux-gnu target
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for powerpc64le-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for mips-linux-gnu target, for use in a cross-compilation environment.
+ for the powerpc64le-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for mips-linux-gnu.
+ for powerpc64le-linux-gnu and powerpc64le-linux-gnu is not your native platform.
-Package: binutils-mipsel-linux-gnu
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-powerpc64le-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: ppc64el amd64 i386 x32 ppc64 arm64
+Multi-Arch: foreign
+Depends: binutils-powerpc64le-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for powerpc64le-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-powerpc64le-linux-gnu.
+
+Package: binutils-s390x-linux-gnu
+Priority: optional
+Architecture: s390x amd64 i386 x32 arm64 ppc64el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
-Description: GNU binary utilities, for mipsel-linux-gnu target
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for s390x-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for mipsel-linux-gnu target, for use in a cross-compilation environment.
+ for the s390x-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for mipsel-linux-gnu.
+ for s390x-linux-gnu and s390x-linux-gnu is not your native platform.
+
+Package: binutils-s390x-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: s390x amd64 i386 x32 arm64 ppc64el
+Multi-Arch: foreign
+Depends: binutils-s390x-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for s390x-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-s390x-linux-gnu.
Package: binutils-alpha-linux-gnu
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Priority: optional
+Architecture: alpha amd64 i386 x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
Description: GNU binary utilities, for alpha-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for alpha-linux-gnu target, for use in a cross-compilation environment.
+ for the alpha-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for alpha-linux-gnu.
+ for alpha-linux-gnu and alpha-linux-gnu is not your native platform.
+
+Package: binutils-alpha-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: alpha amd64 i386 x32
+Multi-Arch: foreign
+Depends: binutils-alpha-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for alpha-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-alpha-linux-gnu.
Package: binutils-hppa-linux-gnu
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Priority: optional
+Architecture: hppa amd64 i386 x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
Description: GNU binary utilities, for hppa-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for hppa-linux-gnu target, for use in a cross-compilation environment.
+ for the hppa-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for hppa-linux-gnu.
+ for hppa-linux-gnu and hppa-linux-gnu is not your native platform.
-Package: binutils-m68k-linux-gnu
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-hppa-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: hppa amd64 i386 x32
+Multi-Arch: foreign
+Depends: binutils-hppa-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for hppa-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-hppa-linux-gnu.
+
+Package: binutils-ia64-linux-gnu
+Priority: optional
+Architecture: ia64 amd64 i386 x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for ia64-linux-gnu target
+ This package provides GNU assembler, linker and binary utilities
+ for the ia64-linux-gnu target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for ia64-linux-gnu and ia64-linux-gnu is not your native platform.
+
+Package: binutils-ia64-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: ia64 amd64 i386 x32
Multi-Arch: foreign
+Depends: binutils-ia64-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for ia64-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-ia64-linux-gnu.
+
+Package: binutils-m68k-linux-gnu
+Priority: optional
+Architecture: m68k amd64 i386 x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
Description: GNU binary utilities, for m68k-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for m68k-linux-gnu target, for use in a cross-compilation environment.
+ for the m68k-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for m68k-linux-gnu.
+ for m68k-linux-gnu and m68k-linux-gnu is not your native platform.
-Package: binutils-mips64-linux-gnuabi64
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-m68k-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: m68k amd64 i386 x32
+Multi-Arch: foreign
+Depends: binutils-m68k-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for m68k-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-m68k-linux-gnu.
+
+Package: binutils-powerpc-linux-gnu
+Priority: optional
+Architecture: powerpc amd64 i386 x32 ppc64el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
-Description: GNU binary utilities, for mips64-linux-gnuabi64 target
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for powerpc-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for mips64-linux-gnuabi64 target, for use in a cross-compilation environment.
+ for the powerpc-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for mips64-linux-gnuabi64.
+ for powerpc-linux-gnu and powerpc-linux-gnu is not your native platform.
-Package: binutils-mips64el-linux-gnuabi64
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-powerpc-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: powerpc amd64 i386 x32 ppc64el
+Multi-Arch: foreign
+Depends: binutils-powerpc-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for powerpc-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-powerpc-linux-gnu.
+
+Package: binutils-powerpc64-linux-gnu
+Priority: optional
+Architecture: ppc64 amd64 i386 x32 ppc64el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for powerpc64-linux-gnu target
+ This package provides GNU assembler, linker and binary utilities
+ for the powerpc64-linux-gnu target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for powerpc64-linux-gnu and powerpc64-linux-gnu is not your native platform.
+
+Package: binutils-powerpc64-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: ppc64 amd64 i386 x32 ppc64el
Multi-Arch: foreign
-Description: GNU binary utilities, for mips64el-linux-gnuabi64 target
+Depends: binutils-powerpc64-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for powerpc64-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-powerpc64-linux-gnu.
+
+Package: binutils-riscv64-linux-gnu
+Priority: optional
+Architecture: riscv64 amd64 i386 x32 arm64 ppc64el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for riscv64-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for mips64el-linux-gnuabi64 target, for use in a cross-compilation environment.
+ for the riscv64-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for mips64el-linux-gnuabi64.
+ for riscv64-linux-gnu and riscv64-linux-gnu is not your native platform.
+
+Package: binutils-riscv64-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: riscv64 amd64 i386 x32 arm64 ppc64el
+Multi-Arch: foreign
+Depends: binutils-riscv64-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for riscv64-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-riscv64-linux-gnu.
-Package: binutils-powerpc-linux-gnuspe
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-sh4-linux-gnu
+Priority: optional
+Architecture: sh4 amd64 i386 x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for sh4-linux-gnu target
+ This package provides GNU assembler, linker and binary utilities
+ for the sh4-linux-gnu target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for sh4-linux-gnu and sh4-linux-gnu is not your native platform.
+
+Package: binutils-sh4-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: sh4 amd64 i386 x32
Multi-Arch: foreign
-Description: GNU binary utilities, for powerpc-linux-gnuspe target
+Depends: binutils-sh4-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for sh4-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-sh4-linux-gnu.
+
+Package: binutils-sparc64-linux-gnu
+Priority: optional
+Architecture: sparc64 amd64 i386 x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for sparc64-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for powerpc-linux-gnuspe target, for use in a cross-compilation environment.
+ for the sparc64-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for powerpc-linux-gnuspe.
+ for sparc64-linux-gnu and sparc64-linux-gnu is not your native platform.
-Package: binutils-powerpc64-linux-gnu
-Architecture: amd64 i386 x32 ppc64el
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-sparc64-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: sparc64 amd64 i386 x32
+Multi-Arch: foreign
+Depends: binutils-sparc64-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for sparc64-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-sparc64-linux-gnu.
+
+Package: binutils-x86-64-linux-gnux32
+Priority: optional
+Architecture: x32 amd64 arm64 i386 ppc64el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for x86-64-linux-gnux32 target
+ This package provides GNU assembler, linker and binary utilities
+ for the x86-64-linux-gnux32 target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for x86-64-linux-gnux32 and x86-64-linux-gnux32 is not your native platform.
+
+Package: binutils-x86-64-linux-gnux32-dbg
+Section: debug
+Priority: optional
+Architecture: x32 amd64 arm64 i386 ppc64el
Multi-Arch: foreign
-Description: GNU binary utilities, for powerpc64-linux-gnu target
+Depends: binutils-x86-64-linux-gnux32 (= ${binary:Version})
+Description: GNU binary utilities, for x86-64-linux-gnux32 target (debug symbols)
+ This package provides debug symbols for binutils-x86-64-linux-gnux32.
+
+Package: binutils-i686-gnu
+Priority: optional
+Architecture: hurd-i386 amd64 i386 x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides: binutils-i586-gnu
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for i686-gnu target
This package provides GNU assembler, linker and binary utilities
- for powerpc64-linux-gnu target, for use in a cross-compilation environment.
+ for the i686-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for powerpc64-linux-gnu.
+ for i686-gnu and i686-gnu is not your native platform.
-Package: binutils-sh4-linux-gnu
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-i686-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: hurd-i386 amd64 i386 x32
+Multi-Arch: foreign
+Depends: binutils-i686-gnu (= ${binary:Version})
+Description: GNU binary utilities, for i686-gnu target (debug symbols)
+ This package provides debug symbols for binutils-i686-gnu.
+
+Package: binutils-x86-64-kfreebsd-gnu
+Priority: optional
+Architecture: kfreebsd-amd64 amd64 i386 x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for x86-64-kfreebsd-gnu target
+ This package provides GNU assembler, linker and binary utilities
+ for the x86-64-kfreebsd-gnu target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for x86-64-kfreebsd-gnu and x86-64-kfreebsd-gnu is not your native platform.
+
+Package: binutils-x86-64-kfreebsd-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: kfreebsd-amd64 amd64 i386 x32
Multi-Arch: foreign
-Description: GNU binary utilities, for sh4-linux-gnu target
+Depends: binutils-x86-64-kfreebsd-gnu (= ${binary:Version})
+Description: GNU binary utilities, for x86-64-kfreebsd-gnu target (debug symbols)
+ This package provides debug symbols for binutils-x86-64-kfreebsd-gnu.
+
+Package: binutils-i686-kfreebsd-gnu
+Priority: optional
+Architecture: kfreebsd-i386 amd64 i386 x32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides: binutils-i586-kfreebsd-gnu
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for i686-kfreebsd-gnu target
This package provides GNU assembler, linker and binary utilities
- for sh4-linux-gnu target, for use in a cross-compilation environment.
+ for the i686-kfreebsd-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for sh4-linux-gnu.
+ for i686-kfreebsd-gnu and i686-kfreebsd-gnu is not your native platform.
-Package: binutils-sparc64-linux-gnu
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Package: binutils-i686-kfreebsd-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: kfreebsd-i386 amd64 i386 x32
+Multi-Arch: foreign
+Depends: binutils-i686-kfreebsd-gnu (= ${binary:Version})
+Description: GNU binary utilities, for i686-kfreebsd-gnu target (debug symbols)
+ This package provides debug symbols for binutils-i686-kfreebsd-gnu.
+
+Package: binutils-mips-linux-gnu
+Priority: optional
+Architecture: mips
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mips-linux-gnu target
+ This package provides GNU assembler, linker and binary utilities
+ for the mips-linux-gnu target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for mips-linux-gnu and mips-linux-gnu is not your native platform.
+
+Package: binutils-mips-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: mips
Multi-Arch: foreign
-Description: GNU binary utilities, for sparc64-linux-gnu target
+Depends: binutils-mips-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for mips-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-mips-linux-gnu.
+
+Package: binutils-mipsel-linux-gnu
+Priority: optional
+Architecture: mipsel
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mipsel-linux-gnu target
This package provides GNU assembler, linker and binary utilities
- for sparc64-linux-gnu target, for use in a cross-compilation environment.
+ for the mipsel-linux-gnu target.
.
You don't need this package unless you plan to cross-compile programs
- for sparc64-linux-gnu.
+ for mipsel-linux-gnu and mipsel-linux-gnu is not your native platform.
+
+Package: binutils-mipsel-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: mipsel
+Multi-Arch: foreign
+Depends: binutils-mipsel-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for mipsel-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-mipsel-linux-gnu.
Package: binutils-mips64-linux-gnuabin32
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Priority: optional
+Architecture: mipsn32
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
Description: GNU binary utilities, for mips64-linux-gnuabin32 target
This package provides GNU assembler, linker and binary utilities
- for mips64-linux-gnuabin32 target, for use in a cross-compilation environment.
+ for the mips64-linux-gnuabin32 target.
.
You don't need this package unless you plan to cross-compile programs
- for mips64-linux-gnuabin32.
+ for mips64-linux-gnuabin32 and mips64-linux-gnuabin32 is not your native platform.
+
+Package: binutils-mips64-linux-gnuabin32-dbg
+Section: debug
+Priority: optional
+Architecture: mipsn32
+Multi-Arch: foreign
+Depends: binutils-mips64-linux-gnuabin32 (= ${binary:Version})
+Description: GNU binary utilities, for mips64-linux-gnuabin32 target (debug symbols)
+ This package provides debug symbols for binutils-mips64-linux-gnuabin32.
Package: binutils-mips64el-linux-gnuabin32
-Architecture: amd64 i386 x32
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Priority: optional
+Architecture: mipsn32el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides:
-Priority: extra
-Multi-Arch: foreign
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
Description: GNU binary utilities, for mips64el-linux-gnuabin32 target
This package provides GNU assembler, linker and binary utilities
- for mips64el-linux-gnuabin32 target, for use in a cross-compilation environment.
+ for the mips64el-linux-gnuabin32 target.
.
You don't need this package unless you plan to cross-compile programs
- for mips64el-linux-gnuabin32.
+ for mips64el-linux-gnuabin32 and mips64el-linux-gnuabin32 is not your native platform.
+
+Package: binutils-mips64el-linux-gnuabin32-dbg
+Section: debug
+Priority: optional
+Architecture: mipsn32el
+Multi-Arch: foreign
+Depends: binutils-mips64el-linux-gnuabin32 (= ${binary:Version})
+Description: GNU binary utilities, for mips64el-linux-gnuabin32 target (debug symbols)
+ This package provides debug symbols for binutils-mips64el-linux-gnuabin32.
+
+Package: binutils-mips64-linux-gnuabi64
+Priority: optional
+Architecture: mips64
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mips64-linux-gnuabi64 target
+ This package provides GNU assembler, linker and binary utilities
+ for the mips64-linux-gnuabi64 target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for mips64-linux-gnuabi64 and mips64-linux-gnuabi64 is not your native platform.
+
+Package: binutils-mips64-linux-gnuabi64-dbg
+Section: debug
+Priority: optional
+Architecture: mips64
+Multi-Arch: foreign
+Depends: binutils-mips64-linux-gnuabi64 (= ${binary:Version})
+Description: GNU binary utilities, for mips64-linux-gnuabi64 target (debug symbols)
+ This package provides debug symbols for binutils-mips64-linux-gnuabi64.
+
+Package: binutils-mips64el-linux-gnuabi64
+Priority: optional
+Architecture: mips64el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mips64el-linux-gnuabi64 target
+ This package provides GNU assembler, linker and binary utilities
+ for the mips64el-linux-gnuabi64 target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for mips64el-linux-gnuabi64 and mips64el-linux-gnuabi64 is not your native platform.
+
+Package: binutils-mips64el-linux-gnuabi64-dbg
+Section: debug
+Priority: optional
+Architecture: mips64el
+Multi-Arch: foreign
+Depends: binutils-mips64el-linux-gnuabi64 (= ${binary:Version})
+Description: GNU binary utilities, for mips64el-linux-gnuabi64 target (debug symbols)
+ This package provides debug symbols for binutils-mips64el-linux-gnuabi64.
+
+Package: binutils-mipsisa64r6-linux-gnuabin32
+Priority: optional
+Architecture: mipsn32r6
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mipsisa64r6-linux-gnuabin32 target
+ This package provides GNU assembler, linker and binary utilities
+ for the mipsisa64r6-linux-gnuabin32 target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for mipsisa64r6-linux-gnuabin32 and mipsisa64r6-linux-gnuabin32 is not your native platform.
+
+Package: binutils-mipsisa64r6-linux-gnuabin32-dbg
+Section: debug
+Priority: optional
+Architecture: mipsn32r6
+Multi-Arch: foreign
+Depends: binutils-mipsisa64r6-linux-gnuabin32 (= ${binary:Version})
+Description: GNU binary utilities, for mipsisa64r6-linux-gnuabin32 target (debug symbols)
+ This package provides debug symbols for binutils-mipsisa64r6-linux-gnuabin32.
+
+Package: binutils-mipsisa64r6el-linux-gnuabin32
+Priority: optional
+Architecture: mipsn32r6el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mipsisa64r6el-linux-gnuabin32 target
+ This package provides GNU assembler, linker and binary utilities
+ for the mipsisa64r6el-linux-gnuabin32 target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for mipsisa64r6el-linux-gnuabin32 and mipsisa64r6el-linux-gnuabin32 is not your native platform.
+
+Package: binutils-mipsisa64r6el-linux-gnuabin32-dbg
+Section: debug
+Priority: optional
+Architecture: mipsn32r6el
+Multi-Arch: foreign
+Depends: binutils-mipsisa64r6el-linux-gnuabin32 (= ${binary:Version})
+Description: GNU binary utilities, for mipsisa64r6el-linux-gnuabin32 target (debug symbols)
+ This package provides debug symbols for binutils-mipsisa64r6el-linux-gnuabin32.
+
+Package: binutils-mipsisa32r6-linux-gnu
+Priority: optional
+Architecture: mipsr6
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mipsisa32r6-linux-gnu target
+ This package provides GNU assembler, linker and binary utilities
+ for the mipsisa32r6-linux-gnu target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for mipsisa32r6-linux-gnu and mipsisa32r6-linux-gnu is not your native platform.
+
+Package: binutils-mipsisa32r6-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: mipsr6
+Multi-Arch: foreign
+Depends: binutils-mipsisa32r6-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for mipsisa32r6-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-mipsisa32r6-linux-gnu.
+
+Package: binutils-mipsisa32r6el-linux-gnu
+Priority: optional
+Architecture: mipsr6el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mipsisa32r6el-linux-gnu target
+ This package provides GNU assembler, linker and binary utilities
+ for the mipsisa32r6el-linux-gnu target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for mipsisa32r6el-linux-gnu and mipsisa32r6el-linux-gnu is not your native platform.
+
+Package: binutils-mipsisa32r6el-linux-gnu-dbg
+Section: debug
+Priority: optional
+Architecture: mipsr6el
+Multi-Arch: foreign
+Depends: binutils-mipsisa32r6el-linux-gnu (= ${binary:Version})
+Description: GNU binary utilities, for mipsisa32r6el-linux-gnu target (debug symbols)
+ This package provides debug symbols for binutils-mipsisa32r6el-linux-gnu.
+
+Package: binutils-mipsisa64r6-linux-gnuabi64
+Priority: optional
+Architecture: mips64r6
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mipsisa64r6-linux-gnuabi64 target
+ This package provides GNU assembler, linker and binary utilities
+ for the mipsisa64r6-linux-gnuabi64 target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for mipsisa64r6-linux-gnuabi64 and mipsisa64r6-linux-gnuabi64 is not your native platform.
+
+Package: binutils-mipsisa64r6-linux-gnuabi64-dbg
+Section: debug
+Priority: optional
+Architecture: mips64r6
+Multi-Arch: foreign
+Depends: binutils-mipsisa64r6-linux-gnuabi64 (= ${binary:Version})
+Description: GNU binary utilities, for mipsisa64r6-linux-gnuabi64 target (debug symbols)
+ This package provides debug symbols for binutils-mipsisa64r6-linux-gnuabi64.
+
+Package: binutils-mipsisa64r6el-linux-gnuabi64
+Priority: optional
+Architecture: mips64r6el
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
+Suggests: binutils-doc (= ${source:Version})
+Provides:
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities, for mipsisa64r6el-linux-gnuabi64 target
+ This package provides GNU assembler, linker and binary utilities
+ for the mipsisa64r6el-linux-gnuabi64 target.
+ .
+ You don't need this package unless you plan to cross-compile programs
+ for mipsisa64r6el-linux-gnuabi64 and mipsisa64r6el-linux-gnuabi64 is not your native platform.
+
+Package: binutils-mipsisa64r6el-linux-gnuabi64-dbg
+Section: debug
+Priority: optional
+Architecture: mips64r6el
+Multi-Arch: foreign
+Depends: binutils-mipsisa64r6el-linux-gnuabi64 (= ${binary:Version})
+Description: GNU binary utilities, for mipsisa64r6el-linux-gnuabi64 target (debug symbols)
+ This package provides debug symbols for binutils-mipsisa64r6el-linux-gnuabi64.
diff --git a/debian/control.cross.in b/debian/control.cross.in
index 9c9279c..20142c7 100644
--- a/debian/control.cross.in
+++ b/debian/control.cross.in
@@ -1,15 +1,27 @@
Package: binutils-@target@
+Priority: optional
Architecture: @host_archs@
-Depends: binutils (= ${binary:Version}), ${shlibs:Depends}
+Multi-Arch: allowed
+Depends: binutils-common (= ${binary:Version}),
+ ${shlibs:Depends}, ${extraDepends}
Suggests: binutils-doc (= ${source:Version})
Provides: @binutils_alt_triplet@
-Priority: extra
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
Built-Using: ${Built-Using}
-Multi-Arch: foreign
Description: GNU binary utilities, for @target@ target
This package provides GNU assembler, linker and binary utilities
- for @target@ target, for use in a cross-compilation environment.
+ for the @target@ target.
.
You don't need this package unless you plan to cross-compile programs
- for @target@.
+ for @target@ and @target@ is not your native platform.
+
+Package: binutils-@target@-dbg
+Section: debug
+Priority: optional
+Architecture: @host_archs@
+Multi-Arch: foreign
+Depends: binutils-@target@ (= ${binary:Version})
+Description: GNU binary utilities, for @target@ target (debug symbols)
+ This package provides debug symbols for binutils-@target@.
diff --git a/debian/control.in b/debian/control.in
index fffc591..ed93b32 100644
--- a/debian/control.in
+++ b/debian/control.in
@@ -2,29 +2,63 @@ Source: binutils
Section: devel
Priority: optional
Maintainer: Matthias Klose <doko@debian.org>
-Uploaders: James Troup <binutils@elmo.tasta.io>, Daniel Jacobowitz <dan@debian.org>
-Standards-Version: 3.9.8
+Uploaders: James Troup <binutils@elmo.tasta.io>
+Standards-Version: 4.4.1
Build-Depends: autoconf (>= 2.64), @dpkg_dev@
- bison, flex, gettext, texinfo, dejagnu, quilt, chrpath,
- python3:any, file, xz-utils, lsb-release, zlib1g-dev
+ bison, flex, gettext, texinfo, dejagnu, quilt, chrpath, dwz,
+ python3:any, file, xz-utils, lsb-release, zlib1g-dev, procps,
+ g++-aarch64-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-arm-linux-gnueabi [amd64 arm64 i386 x32] <!nocheck>,
+ g++-arm-linux-gnueabihf [amd64 arm64 i386 x32] <!nocheck>,
+ g++-powerpc64le-linux-gnu [amd64 arm64 i386 ppc64 x32] <!nocheck>,
+ g++-s390x-linux-gnu [amd64 arm64 i386 ppc64el x32] <!nocheck>,
+ g++-alpha-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-hppa-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-m68k-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-powerpc-linux-gnu [amd64 i386 ppc64el x32] <!nocheck>,
+ g++-powerpc64-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-riscv64-linux-gnu [amd64 arm64 i386 ppc64el x32] <!nocheck>,
+ g++-sh4-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-sparc64-linux-gnu [amd64 i386 x32] <!nocheck>,
+ g++-i686-linux-gnu [amd64 arm64 ppc64el x32] <!nocheck>,
+ g++-x86-64-linux-gnu [arm64 i386 ppc64el] <!nocheck>,
+ g++-x86-64-linux-gnux32 [amd64 arm64 i386 ppc64el] <!nocheck>,
Build-Conflicts: libelf-dev
Homepage: https://www.gnu.org/software/binutils/
-Vcs-Browser: https://code.launchpad.net/~doko/binutils/pkg-2.28-debian
-Vcs-Bzr: http://bazaar.launchpad.net/~doko/binutils/pkg-2.28-debian
+Vcs-Browser: https://salsa.debian.org/toolchain-team/binutils
+Vcs-Git: https://salsa.debian.org/toolchain-team/binutils.git
XS-Testsuite: autopkgtest
+Package: binutils-for-host
+Architecture: any
+Depends: ${binutils:native}:any (>= ${binutils:minver}),
+ binutils-common (= ${binary:Version}),
+Multi-Arch: same
+Description: GNU assembler, linker and binary utilities for the host architecture
+ The programs in this package are used to assemble, link and manipulate
+ binary and object files for the architecture of this package. They may be
+ used in conjunction with a matching compiler and various libraries to build
+ programs. When using binutils through this metapackage, all tools must be
+ used with an architecture prefix.
+
+Package: binutils-for-build
+Architecture: all
+Depends: binutils (>= ${binutils:minver}),
+ binutils-common (>= ${binutils:minver})
+Multi-Arch: foreign
+Description: GNU assembler, linker and binary utilities for the build architecture
+ The programs in this package are used to assemble, link and manipulate
+ binary and object files for the native architecture. They may be used in
+ conjunction with a build architecture compiler and various libraries to build
+ programs. When using binutils through this metapackage, tools without an
+ architecture prefix must be used.
+
Package: binutils
Architecture: any
-Depends: ${shlibs:Depends}
-Conflicts: gas, elf-binutils, modutils (<< 2.4.19-1), ${extraConflicts},
- binutils-gold (<< 2.20.51.20100415),
+Depends: ${shlibs:Depends}, binutils-common (= ${binary:Version}),
+ libbinutils (= ${binary:Version}), ${binutils:native} (= ${binary:Version})
+Conflicts: modutils (<< 2.4.19-1), ${extraConflicts},
binutils-multiarch (<< 2.27-8)
-Breaks: binutils-mingw-w64-i686 (<< 2.23.52.20130612-1+3),
- binutils-mingw-w64-x86-64 (<< 2.23.52.20130612-1+3),
- hardening-wrapper (<< 2.8+nmu3)
-Replaces: binutils-gold (<< 2.20.51.20100415),
- binutils-mingw-w64-i686 (<< 2.23.52.20130612-1+3),
- binutils-mingw-w64-x86-64 (<< 2.23.52.20130612-1+3)
Provides: elf-binutils, ${gold:Provides}
Suggests: binutils-doc (>= ${source:Version})
Description: GNU assembler, linker and binary utilities
@@ -32,10 +66,27 @@ Description: GNU assembler, linker and binary utilities
binary and object files. They may be used in conjunction with a compiler
and various libraries to build programs.
+Package: libbinutils
+Architecture: any
+Multi-Arch: same
+Depends: ${shlibs:Depends}, binutils-common (= ${binary:Version})
+Breaks: binutils (<< 2.29-6)
+Replaces: binutils (<< 2.29-6)
+Description: GNU binary utilities (private shared library)
+ This package includes the private shared libraries libbfd and libopcodes.
+
+Package: libbinutils-dbg
+Section: debug
+Architecture: any
+Multi-Arch: same
+Depends: libbinutils (= ${binary:Version})
+Description: GNU binary utilities (private shared library, debug symbols)
+ This package provides debug symbols for libbinutils.
+
Package: binutils-dev
Architecture: any
-Priority: extra
-Depends: binutils (= ${binary:Version})
+Priority: optional
+Depends: binutils (= ${binary:Version}), libbinutils (= ${binary:Version})
Conflicts: libbfd-dev
Provides: libbfd-dev
Replaces: libbfd-dev, libc5-dev
@@ -47,8 +98,9 @@ Description: GNU binary utilities (BFD development files)
Package: binutils-multiarch
Architecture: any
-Priority: extra
-Depends: ${shlibs:Depends}, binutils (= ${binary:Version})
+Priority: optional
+Depends: ${shlibs:Depends}, binutils (= ${binary:Version}),
+ binutils-common (= ${binary:Version})
Description: Binary utilities that support multi-arch targets
The programs in this package are used to manipulate binary and object
files that may have been created on other architectures. This package
@@ -59,9 +111,17 @@ Description: Binary utilities that support multi-arch targets
NORMAL USERS SHOULD NOT INSTALL THIS PACKAGE. It's meant only for those
requiring support for reading info from binaries from other architectures.
+Package: binutils-multiarch-dbg
+Section: debug
+Architecture: any
+Priority: optional
+Depends: binutils-multiarch (= ${binary:Version})
+Description: Binary utilities that support multi-arch targets (debug symbols)
+ This package provides debug symbols for binutils-multiarch.
+
Package: binutils-multiarch-dev
Architecture: any
-Priority: extra
+Priority: optional
Depends: ${shlibs:Depends},
binutils-dev (= ${binary:Version}), binutils-multiarch (= ${binary:Version})
Replaces: binutils-multiarch (<< 2.24-5)
@@ -76,7 +136,8 @@ Description: GNU binary utilities that support multi-arch targets (BFD developme
Package: binutils-hppa64-linux-gnu
Architecture: amd64 i386 x32 hppa
-Depends: ${shlibs:Depends}, binutils (= ${binary:Version})
+Depends: ${shlibs:Depends}, binutils (= ${binary:Version}),
+ binutils-common (= ${binary:Version})
Recommends: libc6-dev
Provides: binutils-hppa64
Suggests: binutils-doc (>= ${source:Version})
@@ -89,13 +150,18 @@ Description: GNU assembler, linker and binary utilities targeted for hppa64-linu
.
This package is needed to build an 64-bit kernel for 64-bit hppa machines.
+Package: binutils-hppa64-linux-gnu-dbg
+Section: debug
+Architecture: amd64 i386 x32 hppa
+Depends: binutils-hppa64-linux-gnu (= ${binary:Version})
+Description: GNU binutils targeted for hppa64-linux (debug symbols)
+ This package provides debug symbols for binutils-hppa64-linux-gnu.
+
Package: binutils-doc
Section: doc
Architecture: all
Multi-Arch: foreign
Priority: optional
-Depends: dpkg (>= 1.15.4) | install-info
-Conflicts: binutils (<< 2.9.1.0.25-3)
Suggests: binutils (= ${binary:Version})
Description: Documentation for the GNU assembler, linker and binary utilities
This package consists of the documentation for the GNU assembler,
@@ -105,7 +171,17 @@ Package: binutils-source
Architecture: all
Multi-Arch: foreign
Priority: optional
-Depends: texinfo, zlib1g-dev, make, python
+Depends: texinfo, zlib1g-dev, make, python3
Description: GNU assembler, linker and binary utilities (source)
This package contains the sources and patches which are needed to
build binutils.
+
+Package: binutils-common
+Architecture: any
+Multi-Arch: same
+Breaks: binutils (<< 2.29.1-3.1~)
+Replaces: binutils (<< 2.29.1-3.1~)
+Description: Common files for the GNU assembler, linker and binary utilities
+ This package contains the localization files used by binutils packages for
+ various target architectures and parts of the binutils documentation. It is
+ not useful on its own.
diff --git a/debian/dwp.1 b/debian/dwp.1
index fb78be7..a6a068b 100644
--- a/debian/dwp.1
+++ b/debian/dwp.1
@@ -1,5 +1,5 @@
-.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.4.
-.TH DWP "1" "May 2017" "dwp (GNU Binutils for Debian) 2.28" "User Commands"
+.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.10.
+.TH DWP "1" "June 2019" "dwp (GNU Binutils for Debian) 2.32.51.20190611" "User Commands"
.SH NAME
dwp \- The DWARF packaging utility
.SH SYNOPSIS
@@ -27,7 +27,7 @@ Print version number
.SH "REPORTING BUGS"
Report bugs to <http://www.sourceware.org/bugzilla/>
.SH COPYRIGHT
-Copyright \(co 2017 Free Software Foundation, Inc.
+Copyright \(co 2019 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) any later version.
This program has absolutely no warranty.
diff --git a/debian/ld.gold.1 b/debian/ld.gold.1
index 50a4261..b54f96a 100644
--- a/debian/ld.gold.1
+++ b/debian/ld.gold.1
@@ -1,5 +1,5 @@
-.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.4.
-.TH GOLD "1" "May 2017" "gold (GNU Binutils for Debian 2.28) 1.14" "User Commands"
+.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.10.
+.TH GOLD "1" "June 2019" "gold (GNU Binutils for Debian 2.32.51.20190611) 1.16" "User Commands"
.SH NAME
gold \- The GNU ELF linker
.SH SYNOPSIS
@@ -151,6 +151,12 @@ Add C++ operator new/delete to dynamic symbols
.TP
\fB\-\-dynamic\-list\fR FILE
Read a list of dynamic symbols
+.TP
+\fB\-\-emit\-stub\-syms\fR
+(PowerPC only) Label linker stubs with a symbol (default)
+.TP
+\fB\-\-no\-emit\-stub\-syms\fR
+(PowerPC only) Do not label linker stubs with a symbol
.HP
\fB\-e\fR ADDRESS, \fB\-\-entry\fR ADDRESS Set program start address
.TP
@@ -231,7 +237,7 @@ Call SYMBOL at unload\-time
\fB\-\-fix\-v4bx\-interworking\fR
(ARM only) Rewrite BX rn branch to ARMv4 interworking veneer
.TP
-\fB\-fuse\-ld\fR
+\fB\-fuse\-ld\fR [gold,bfd]
Ignored for GCC linker option compatibility
.TP
\fB\-g\fR
@@ -274,7 +280,7 @@ Alias for \fB\-r\fR
Identical Code Folding. '\-\-icf=safe' Folds ctors, dtors and functions whose pointers are definitely not taken
.TP
\fB\-\-icf\-iterations\fR COUNT
-Number of iterations of ICF (default 2)
+Number of iterations of ICF (default 3)
.TP
\fB\-\-incremental\fR
Do an incremental link if possible; otherwise, do a full link and prepare output for incremental linking
@@ -423,7 +429,13 @@ Force PIC sequences for ARM/Thumb interworking veneers
(ARM only) Ignore for backward compatibility (default)
.TP
\fB\-\-plt\-align\fR [=P2ALIGN]
-(PowerPC64 only) Align PLT call stubs to fit cache lines
+(PowerPC only) Align PLT call stubs to fit cache lines
+.TP
+\fB\-\-plt\-localentry\fR
+(PowerPC64 only) Optimize calls to ELFv2 localentry:0 functions
+.TP
+\fB\-\-no\-plt\-localentry\fR
+(PowerPC64 only) Don't optimize ELFv2 calls (default)
.TP
\fB\-\-plt\-static\-chain\fR
(PowerPC64 only) PLT call stubs should load r11
@@ -488,6 +500,9 @@ Generate relocatable output
\fB\-\-relax\fR
Relax branches on certain targets
.TP
+\fB\-\-no\-relax\fR
+Do not relax branches (default)
+.TP
\fB\-\-retain\-symbols\-file\fR FILE
keep only symbols listed in this file
.TP
@@ -543,7 +558,10 @@ Dynamic tag slots to reserve (default 5)
(ARM, PowerPC only) The maximum distance from instructions in a group of sections to their stubs. Negative values mean stubs are always after the group. 1 means use default size
.TP
\fB\-\-stub\-group\-multi\fR
-(PowerPC only) Allow a group of stubs to serve multiple output sections
+(PowerPC only) Allow a group of stubs to serve multiple output sections (default)
+.TP
+\fB\-\-no\-stub\-group\-multi\fR
+(PowerPC only) Each output section has its own stubs
.TP
\fB\-\-split\-stack\-adjust\-size\fR SIZE
Stack size when \fB\-fsplit\-stack\fR function calls non\-split
@@ -598,6 +616,18 @@ Number of threads to use in initial pass
\fB\-\-thread\-count\-final\fR COUNT
Number of threads to use in final pass
.TP
+\fB\-\-tls\-optimize\fR
+(PowerPC/64 only) Optimize GD/LD/IE code to IE/LE (default)
+.TP
+\fB\-\-no\-tls\-optimize\fR
+(PowerPC/64 only) Don'''t try to optimize TLS accesses
+.TP
+\fB\-\-tls\-get\-addr\-optimize\fR
+(PowerPC/64 only) Use a special __tls_get_addr call (default)
+.TP
+\fB\-\-no\-tls\-get\-addr\-optimize\fR
+(PowerPC/64 only) Don't use a special __tls_get_addr call
+.TP
\fB\-\-toc\-optimize\fR
(PowerPC64 only) Optimize TOC code sequences (default)
.TP
@@ -652,6 +682,12 @@ Ignored
\fB\-\-no\-warn\-constructors\fR
Ignored
.TP
+\fB\-\-warn\-drop\-version\fR
+Warn when discarding version information
+.TP
+\fB\-\-no\-warn\-drop\-version\fR
+Do not warn when discarding version information (default)
+.TP
\fB\-\-warn\-execstack\fR
Warn if the stack is executable
.TP
@@ -810,13 +846,24 @@ Permit relocations in read\-only segments (default)
.TP
\fB\-z\fR textoff
Permit relocations in read\-only segments (default)
+.TP
+\fB\-z\fR text\-unlikely\-segment
+Move .text.unlikely sections to a separate segment.
+.TP
+\fB\-z\fR notext\-unlikely\-segment
+Do not move .text.unlikely sections to a separate segment. (default)
+.HP
+\fB\-z\fR keep\-text\-section\-prefix Keep .text.hot, .text.startup, .text.exit and .text.unlikely as separate sections in the final binary.
+.TP
+\fB\-z\fR nokeep\-text\-section\-prefix
+Merge all .text.* prefix sections. (default)
.PP
-ld.gold: supported targets: elf32\-iamcu elf32\-i386 elf32\-i386\-freebsd elf32\-i386\-nacl elf32\-x86\-64 elf32\-x86\-64\-freebsd elf32\-x86\-64\-nacl elf64\-x86\-64 elf64\-x86\-64\-freebsd elf64\-x86\-64\-nacl
-ld.gold: supported emulations: elf_iamcu elf_i386 elf_i386_nacl elf32_x86_64 elf32_x86_64_nacl elf_x86_64 elf_x86_64_nacl
+debian/tmp/usr/bin/ld.gold: supported targets: elf32\-iamcu elf32\-i386 elf32\-i386\-freebsd elf32\-i386\-nacl elf32\-x86\-64 elf32\-x86\-64\-freebsd elf32\-x86\-64\-nacl elf64\-x86\-64 elf64\-x86\-64\-freebsd elf64\-x86\-64\-nacl
+debian/tmp/usr/bin/ld.gold: supported emulations: elf_iamcu elf_i386 elf_i386_nacl elf32_x86_64 elf32_x86_64_nacl elf_x86_64 elf_x86_64_nacl
.SH "REPORTING BUGS"
Report bugs to <http://www.sourceware.org/bugzilla/>
.SH COPYRIGHT
-Copyright \(co 2017 Free Software Foundation, Inc.
+Copyright \(co 2019 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) a later version.
This program has absolutely no warranty.
diff --git a/debian/libbinutils.overrides b/debian/libbinutils.overrides
new file mode 100644
index 0000000..67e71e7
--- /dev/null
+++ b/debian/libbinutils.overrides
@@ -0,0 +1,5 @@
+# the API of the shared libs is not public, don't care about the name
+libbinutils binary: package-name-doesnt-match-sonames
+
+# the upstream name, we don't care
+libbinutils binary: dev-pkg-without-shlib-symlink
diff --git a/debian/libbinutils.shlibs.in b/debian/libbinutils.shlibs.in
new file mode 100644
index 0000000..6964e29
--- /dev/null
+++ b/debian/libbinutils.shlibs.in
@@ -0,0 +1,2 @@
+libbfd @VER@-system@DATE_EXT@ libbinutils (>= @DEB_UVER@), libbinutils (<< @DEB_NVER@)
+libopcodes @VER@-system@DATE_EXT@ libbinutils (>= @DEB_UVER@), libbinutils (<< @DEB_NVER@)
diff --git a/debian/patches/001_ld_makefile_patch.patch b/debian/patches/001_ld_makefile_patch.patch
index bb83d23..096efe2 100644
--- a/debian/patches/001_ld_makefile_patch.patch
+++ b/debian/patches/001_ld_makefile_patch.patch
@@ -3,8 +3,6 @@ Description: Description: correct where ld scripts are installed
Author: Chris Chimelis <chris@debian.org>
Upstream status: N/A
Date: ??
-Index: b/ld/Makefile.am
-===================================================================
--- a/ld/Makefile.am
+++ b/ld/Makefile.am
@@ -57,7 +57,7 @@ endif
@@ -16,11 +14,9 @@ Index: b/ld/Makefile.am
EMUL = @EMUL@
EMULATION_OFILES = @EMULATION_OFILES@
-Index: b/ld/Makefile.in
-===================================================================
--- a/ld/Makefile.in
+++ b/ld/Makefile.in
-@@ -452,7 +452,7 @@ AM_CFLAGS = $(WARN_CFLAGS) $(ELF_CLFAGS)
+@@ -564,7 +564,7 @@ AM_CFLAGS = $(WARN_CFLAGS) $(ELF_CLFAGS)
# We put the scripts in the directory $(scriptdir)/ldscripts.
# We can't put the scripts in $(datadir) because the SEARCH_DIR
# directives need to be different for native and cross linkers.
diff --git a/debian/patches/012_check_ldrunpath_length.patch b/debian/patches/012_check_ldrunpath_length.patch
index 012f838..74f6333 100644
--- a/debian/patches/012_check_ldrunpath_length.patch
+++ b/debian/patches/012_check_ldrunpath_length.patch
@@ -1,20 +1,18 @@
Author: Chris Chimelis <chris@debian.org>
Description: Only generate an RPATH entry if LD_RUN_PATH is not empty, for
cases where -rpath isn't specified. (#151024)
-Index: b/ld/emultempl/elf32.em
-===================================================================
--- a/ld/emultempl/elf32.em
+++ b/ld/emultempl/elf32.em
-@@ -1411,6 +1411,8 @@ fragment <<EOF
+@@ -1470,6 +1470,8 @@ fragment <<EOF
&& command_line.rpath == NULL)
{
- lib_path = (const char *) getenv ("LD_RUN_PATH");
-+ if ((lib_path) && (strlen (lib_path) == 0))
-+ lib_path = NULL;
- if (gld${EMULATION_NAME}_search_needed (lib_path, &n,
- force))
+ path = (const char *) getenv ("LD_RUN_PATH");
++ if ((path) && (strlen (path) == 0))
++ path = NULL;
+ if (path
+ && gld${EMULATION_NAME}_search_needed (path, &n, force))
break;
-@@ -1692,6 +1694,8 @@ gld${EMULATION_NAME}_before_allocation (
+@@ -1745,6 +1747,8 @@ gld${EMULATION_NAME}_before_allocation (
rpath = command_line.rpath;
if (rpath == NULL)
rpath = (const char *) getenv ("LD_RUN_PATH");
diff --git a/debian/patches/013_bash_in_ld_testsuite.patch b/debian/patches/013_bash_in_ld_testsuite.patch
index 09be8ac..ed642cf 100644
--- a/debian/patches/013_bash_in_ld_testsuite.patch
+++ b/debian/patches/013_bash_in_ld_testsuite.patch
@@ -1,23 +1,10 @@
Author: Matthias Klose <doko@ubuntu.com>
-Description: Explicitely use bash for the ld testsuite.
+Description: Explicitly use bash for the ld testsuite.
Index: b/ld/testsuite/config/default.exp
===================================================================
--- a/ld/testsuite/config/default.exp
+++ b/ld/testsuite/config/default.exp
-@@ -124,10 +124,10 @@ proc get_link_files {varname} {
- #makefile rules, with embedded shell variable expansions.
- #make wants $$shell_var, we want $shell_var ...
- set cmd "host='$target_triplet' && . $srcdir/../configure.host && sed -e 's,\\\$\\\$,\$,g' <<EOF\n\$$varname\nEOF"
-- set status [catch "exec sh -c [list $cmd]" result]
-+ set status [catch "exec bash -c [list $cmd]" result]
- if $status { error "Error getting native link files: $result" }
- set cmd "CC='$CC' && eval echo \"$result\""
-- set status [catch "exec sh -c [list $cmd]" result]
-+ set status [catch "exec bash -c [list $cmd]" result]
- if $status { error "Error getting native link files: $result" }
- set $varname $result
- send_log "$varname = $result\n"
-@@ -137,7 +137,7 @@ proc get_link_files {varname} {
+@@ -117,7 +117,7 @@ load_lib ld-lib.exp
proc get_target_emul {} {
global target_triplet
global srcdir
diff --git a/debian/patches/128_ppc64_powerpc_biarch.patch b/debian/patches/128_ppc64_powerpc_biarch.patch
index f75ec74..a72fb51 100644
--- a/debian/patches/128_ppc64_powerpc_biarch.patch
+++ b/debian/patches/128_ppc64_powerpc_biarch.patch
@@ -2,7 +2,7 @@ Index: b/ld/emulparams/elf32ppccommon.sh
===================================================================
--- a/ld/emulparams/elf32ppccommon.sh
+++ b/ld/emulparams/elf32ppccommon.sh
-@@ -54,3 +54,12 @@ case "$host":"$EMULATION_NAME" in
+@@ -56,3 +56,12 @@ case `echo "$target" | sed -e 's/-.*//'`
*:*64*) LIBPATH_SUFFIX=64 ;;
*:*32*) LIBPATH_SUFFIX=32 ;;
esac
diff --git a/debian/patches/129_multiarch_libpath.patch b/debian/patches/129_multiarch_libpath.patch
index 9b59471..0af9090 100644
--- a/debian/patches/129_multiarch_libpath.patch
+++ b/debian/patches/129_multiarch_libpath.patch
@@ -1,10 +1,8 @@
# DP: Add multiarch directories to linker search path for ld and gold.
-Index: b/ld/genscripts.sh
-===================================================================
--- a/ld/genscripts.sh
+++ b/ld/genscripts.sh
-@@ -189,6 +189,104 @@ append_to_lib_path()
+@@ -235,6 +235,104 @@ append_to_lib_path()
fi
}
@@ -109,21 +107,21 @@ Index: b/ld/genscripts.sh
# Always search $(tooldir)/lib, aka /usr/local/TARGET/lib when native
# except when LIBPATH=":".
if [ "${LIB_PATH}" != ":" ] ; then
-@@ -205,31 +303,138 @@ if [ "${LIB_PATH}" != ":" ] ; then
- # vs. /usr/s390-linux/lib64)
- case "${NATIVE}:${LIBPATH_SUFFIX}:${TOOL_LIB}" in
- :* | *::* | *:*:*${LIBPATH_SUFFIX}) ;;
-- *) libs="${exec_prefix}/${target_alias}/lib${LIBPATH_SUFFIX}" ;;
-+ *)
-+ # FIXME:
-+ # For the binutils-multiarch build on x86_64-linux-gnu configured
-+ # with --enable-targets=powerpc-linux-gnu, /usr/x86_64-linux-gnu/lib64
-+ # is added instead of /usr/powerpc64-linux-gnu/lib64. However this
-+ # probably wanted for the "default" emulation. How to detect that?
-+ libs="${exec_prefix}/${target_alias}/lib${LIBPATH_SUFFIX}" ;;
- esac
+@@ -253,6 +351,13 @@ if [ "${LIB_PATH}" != ":" ] ; then
+ case "${NATIVE}:${libpath_suffix}:${TOOL_LIB}" in
+ :* | *::* | *:*:*${libpath_suffix}) ;;
+ *) libs="${exec_prefix}/${target_alias}/lib${libpath_suffix}" ;;
++ *)
++ # FIXME:
++ # For the binutils-multiarch build on x86_64-linux-gnu configured
++ # with --enable-targets=powerpc-linux-gnu, /usr/x86_64-linux-gnu/lib64
++ # is added instead of /usr/powerpc64-linux-gnu/lib64. However this
++ # probably wanted for the "default" emulation. How to detect that?
++ libs="${exec_prefix}/${target_alias}/lib${libpath_suffix}" ;;
+ esac
+ done
libs="${exec_prefix}/${TOOL_LIB}/lib ${libs}"
- fi
+@@ -260,24 +365,124 @@ if [ "${LIB_PATH}" != ":" ] ; then
append_to_lib_path ${libs}
fi
@@ -257,16 +255,13 @@ Index: b/ld/genscripts.sh
+ LIB_SEARCH_DIRS="${LIB_SEARCH_DIRS}SEARCH_DIR(\"$dir\"); "
+ done
+fi
-+echo X3: $LIB_PATH
+
# We need it for testsuite.
set $EMULATION_LIBPATH
if [ "x$1" = "x$EMULATION_NAME" ]; then
-Index: b/gold/Makefile.am
-===================================================================
--- a/gold/Makefile.am
+++ b/gold/Makefile.am
-@@ -38,6 +38,7 @@ AM_CPPFLAGS = \
+@@ -42,6 +42,7 @@ AM_CPPFLAGS = \
-I$(srcdir) -I$(srcdir)/../include -I$(srcdir)/../elfcpp \
-DLOCALEDIR="\"$(datadir)/locale\"" \
-DBINDIR="\"$(bindir)\"" -DTOOLBINDIR="\"$(tooldir)/bin\"" \
@@ -274,11 +269,9 @@ Index: b/gold/Makefile.am
-DTOOLLIBDIR="\"$(tooldir)/lib\"" @INCINTL@
LIBIBERTY = ../libiberty/libiberty.a
-Index: b/gold/configure
-===================================================================
--- a/gold/configure
+++ b/gold/configure
-@@ -594,6 +594,7 @@ LTLIBOBJS
+@@ -625,6 +625,7 @@ LTLIBOBJS
MAINT
MAINTAINER_MODE_FALSE
MAINTAINER_MODE_TRUE
@@ -286,7 +279,7 @@ Index: b/gold/configure
DLOPEN_LIBS
CXXCPP
HAVE_NO_USE_LINKER_PLUGIN_FALSE
-@@ -7720,6 +7721,14 @@ $as_echo "#define HAVE_LC_MESSAGES 1" >>
+@@ -10170,6 +10171,14 @@ $as_echo "#define HAVE_LC_MESSAGES 1" >>
fi
@@ -301,11 +294,9 @@ Index: b/gold/configure
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
-Index: b/gold/configure.ac
-===================================================================
--- a/gold/configure.ac
+++ b/gold/configure.ac
-@@ -662,6 +662,14 @@ AC_CHECK_HEADERS(locale.h)
+@@ -682,6 +682,14 @@ AC_CHECK_HEADERS(locale.h)
AC_CHECK_FUNCS(setlocale)
AM_LC_MESSAGES
@@ -320,11 +311,9 @@ Index: b/gold/configure.ac
AM_MAINTAINER_MODE
AC_OUTPUT(Makefile testsuite/Makefile po/Makefile.in:po/Make-in)
-Index: b/gold/options.cc
-===================================================================
--- a/gold/options.cc
+++ b/gold/options.cc
-@@ -1227,8 +1227,15 @@ General_options::finalize()
+@@ -1232,8 +1232,15 @@ General_options::finalize()
|| this->user_set_sysroot()
|| *TARGET_SYSTEM_ROOT != '\0')
{
@@ -340,11 +329,9 @@ Index: b/gold/options.cc
}
else
this->add_to_library_path_with_sysroot(TOOLLIBDIR);
-Index: b/gold/Makefile.in
-===================================================================
--- a/gold/Makefile.in
+++ b/gold/Makefile.in
-@@ -490,6 +490,7 @@ AM_CPPFLAGS = \
+@@ -674,6 +674,7 @@ AM_CPPFLAGS = \
-I$(srcdir) -I$(srcdir)/../include -I$(srcdir)/../elfcpp \
-DLOCALEDIR="\"$(datadir)/locale\"" \
-DBINDIR="\"$(bindir)\"" -DTOOLBINDIR="\"$(tooldir)/bin\"" \
diff --git a/debian/patches/130_gold_disable_testsuite_build.patch b/debian/patches/130_gold_disable_testsuite_build.patch
index 5fb0375..7e1d1af 100644
--- a/debian/patches/130_gold_disable_testsuite_build.patch
+++ b/debian/patches/130_gold_disable_testsuite_build.patch
@@ -2,8 +2,6 @@ Author:
Description: Description: Disable build of gold/testsuite
Author: Matthias Klose
Upstream status: local
-Index: b/gold/Makefile.am
-===================================================================
--- a/gold/Makefile.am
+++ b/gold/Makefile.am
@@ -19,7 +19,7 @@
@@ -15,11 +13,9 @@ Index: b/gold/Makefile.am
tooldir = $(exec_prefix)/$(target_alias)
-Index: b/gold/Makefile.in
-===================================================================
--- a/gold/Makefile.in
+++ b/gold/Makefile.in
-@@ -475,7 +475,7 @@ top_srcdir = @top_srcdir@
+@@ -656,7 +656,7 @@ top_srcdir = @top_srcdir@
zlibdir = @zlibdir@
zlibinc = @zlibinc@
AUTOMAKE_OPTIONS = foreign
diff --git a/debian/patches/131_ld_bootstrap_testsuite.patch b/debian/patches/131_ld_bootstrap_testsuite.patch
index 4c6f434..65af10e 100644
--- a/debian/patches/131_ld_bootstrap_testsuite.patch
+++ b/debian/patches/131_ld_bootstrap_testsuite.patch
@@ -2,11 +2,9 @@ Author:
Description: Description: Fix ld-bootstrap testsuite when configured with --enable-plugins
Author: Rafael Espindola
Upstream status: proposed patch
-Index: b/ld/testsuite/ld-bootstrap/bootstrap.exp
-===================================================================
--- a/ld/testsuite/ld-bootstrap/bootstrap.exp
+++ b/ld/testsuite/ld-bootstrap/bootstrap.exp
-@@ -44,6 +44,15 @@ if [check_plugin_api_available] {
+@@ -46,6 +46,15 @@ if [check_plugin_api_available] {
set plugins "yes"
}
@@ -22,7 +20,7 @@ Index: b/ld/testsuite/ld-bootstrap/bootstrap.exp
# Bootstrap ld. First link the object files together using -r, in
# order to test -r. Then link the result into an executable, ld1, to
# really test -r. Use ld1 to link a fresh ld, ld2. Use ld2 to link a
-@@ -90,6 +99,11 @@ foreach flags $test_flags {
+@@ -110,6 +119,11 @@ foreach flags $test_flags {
continue
}
@@ -34,7 +32,7 @@ Index: b/ld/testsuite/ld-bootstrap/bootstrap.exp
# If we only have a shared libbfd, we probably can't run the
# --static test.
if { $flags == "--static" && ! [string match "*libbfd.a*" $BFDLIB] } then {
-@@ -134,6 +148,10 @@ foreach flags $test_flags {
+@@ -154,6 +168,10 @@ foreach flags $test_flags {
}
}
diff --git a/debian/patches/135_bfd_soversion.patch b/debian/patches/135_bfd_soversion.patch
new file mode 100644
index 0000000..ecb6094
--- /dev/null
+++ b/debian/patches/135_bfd_soversion.patch
@@ -0,0 +1,38 @@
+--- a/bfd/Makefile.am
++++ b/bfd/Makefile.am
+@@ -958,14 +958,14 @@ bfdver.h: $(srcdir)/version.h $(srcdir)/
+ @echo "creating $@"
+ @bfd_version=`echo "$(VERSION)" | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
+ bfd_version_string="\"$(VERSION)\"" ;\
+- bfd_soversion="$(VERSION)" ;\
++ bfd_soversion="$(VERSION)$(BFD_SOVER_EXT)" ;\
+ bfd_version_package="\"$(PKGVERSION)\"" ;\
+ report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
+ . $(srcdir)/development.sh ;\
+ if test "$$development" = true ; then \
+ bfd_version_date=`$(SED) -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
+ bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
+- bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
++ bfd_soversion="$(VERSION)$(BFD_SOVER_EXT).$${bfd_version_date}" ;\
+ fi ;\
+ $(SED) -e "s,@bfd_version@,$$bfd_version," \
+ -e "s,@bfd_version_string@,$$bfd_version_string," \
+--- a/bfd/Makefile.in
++++ b/bfd/Makefile.in
+@@ -2076,14 +2076,14 @@ bfdver.h: $(srcdir)/version.h $(srcdir)/
+ @echo "creating $@"
+ @bfd_version=`echo "$(VERSION)" | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
+ bfd_version_string="\"$(VERSION)\"" ;\
+- bfd_soversion="$(VERSION)" ;\
++ bfd_soversion="$(VERSION)$(BFD_SOVER_EXT)" ;\
+ bfd_version_package="\"$(PKGVERSION)\"" ;\
+ report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
+ . $(srcdir)/development.sh ;\
+ if test "$$development" = true ; then \
+ bfd_version_date=`$(SED) -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
+ bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
+- bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
++ bfd_soversion="$(VERSION)$(BFD_SOVER_EXT).$${bfd_version_date}" ;\
+ fi ;\
+ $(SED) -e "s,@bfd_version@,$$bfd_version," \
+ -e "s,@bfd_version_string@,$$bfd_version_string," \
diff --git a/debian/patches/135_bfd_version.patch b/debian/patches/135_bfd_version.patch
deleted file mode 100644
index dc68ad1..0000000
--- a/debian/patches/135_bfd_version.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-Author:
-Description: Description: Fix bfd version handling for extra builds
-
-Index: b/bfd/Makefile.am
-===================================================================
---- a/bfd/Makefile.am
-+++ b/bfd/Makefile.am
-@@ -1069,15 +1069,15 @@ DISTCLEANFILES = $(BUILD_CFILES) $(BUILD
-
- bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in
- @echo "creating $@"
-- @bfd_version=`echo "$(VERSION)" | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
-- bfd_version_string="\"$(VERSION)\"" ;\
-+ @bfd_version=`echo "$(VERSION)" | sed -e 's/-.*$$//' | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
-+ bfd_version_string="\"`echo $(VERSION) | sed -e 's/-.*$$//'`\"" ;\
- bfd_soversion="$(VERSION)" ;\
- bfd_version_package="\"$(PKGVERSION)\"" ;\
- report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
- . $(srcdir)/development.sh ;\
- if test "$$development" = true ; then \
- bfd_version_date=`$(SED) -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
-- bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
-+ bfd_version_string="\"`echo $(VERSION) | sed -e 's/-.*$$//'`.$${bfd_version_date}\"" ;\
- bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
- fi ;\
- $(SED) -e "s,@bfd_version@,$$bfd_version," \
-Index: b/bfd/Makefile.in
-===================================================================
---- a/bfd/Makefile.in
-+++ b/bfd/Makefile.in
-@@ -2179,15 +2179,15 @@ stmp-lcoff-h: $(LIBCOFF_H_FILES)
-
- bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in
- @echo "creating $@"
-- @bfd_version=`echo "$(VERSION)" | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
-- bfd_version_string="\"$(VERSION)\"" ;\
-+ @bfd_version=`echo "$(VERSION)" | sed -e 's/-.*$$//' | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
-+ bfd_version_string="\"`echo $(VERSION) | sed -e 's/-.*$$//'`\"" ;\
- bfd_soversion="$(VERSION)" ;\
- bfd_version_package="\"$(PKGVERSION)\"" ;\
- report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
- . $(srcdir)/development.sh ;\
- if test "$$development" = true ; then \
- bfd_version_date=`$(SED) -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
-- bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
-+ bfd_version_string="\"`echo $(VERSION) | sed -e 's/-.*$$//'`.$${bfd_version_date}\"" ;\
- bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
- fi ;\
- $(SED) -e "s,@bfd_version@,$$bfd_version," \
diff --git a/debian/patches/136_bfd_pic.patch b/debian/patches/136_bfd_pic.patch
index 9ac484f..f200034 100644
--- a/debian/patches/136_bfd_pic.patch
+++ b/debian/patches/136_bfd_pic.patch
@@ -1,29 +1,25 @@
Author: Balint Reczey <balint@balintreczey.hu>
Description: Build libbfd with -fPIC to allow linking with PIE binaries
-Index: b/bfd/Makefile.am
-===================================================================
--- a/bfd/Makefile.am
+++ b/bfd/Makefile.am
-@@ -51,7 +51,7 @@ ZLIBINC = @zlibinc@
+@@ -52,7 +52,7 @@ ZLIBINC = @zlibinc@
WARN_CFLAGS = @WARN_CFLAGS@
NO_WERROR = @NO_WERROR@
-AM_CFLAGS = $(WARN_CFLAGS) $(ZLIBINC)
+AM_CFLAGS = $(WARN_CFLAGS) $(ZLIBINC) -fPIC
- AM_CPPFLAGS = -DBINDIR='"$(bindir)"'
+ AM_CPPFLAGS = -DBINDIR='"$(bindir)"' -DLIBDIR='"$(libdir)"'
if PLUGINS
bfdinclude_HEADERS += $(INCDIR)/plugin-api.h
-Index: b/bfd/Makefile.in
-===================================================================
--- a/bfd/Makefile.in
+++ b/bfd/Makefile.in
-@@ -388,7 +388,7 @@ libbfd_la_LDFLAGS = $(am__append_1) -rel
+@@ -478,7 +478,7 @@ libbfd_la_LDFLAGS = $(am__append_1) -rel
# case both are empty.
ZLIB = @zlibdir@ -lz
ZLIBINC = @zlibinc@
-AM_CFLAGS = $(WARN_CFLAGS) $(ZLIBINC)
+AM_CFLAGS = $(WARN_CFLAGS) $(ZLIBINC) -fPIC
- AM_CPPFLAGS = -DBINDIR='"$(bindir)"'
- @PLUGINS_TRUE@LIBDL = @lt_cv_dlopen_libs@
-
+ AM_CPPFLAGS = -DBINDIR='"$(bindir)"' -DLIBDIR='"$(libdir)"' @HDEFINES@ \
+ @COREFLAG@ @TDEFINES@ $(CSEARCH) $(CSWITCHES) $(HAVEVECS) \
+ @INCINTL@ $(am__empty)
diff --git a/debian/patches/161_gold_dummy_zoption.diff b/debian/patches/161_gold_dummy_zoption.diff
index e203ff7..793a40b 100644
--- a/debian/patches/161_gold_dummy_zoption.diff
+++ b/debian/patches/161_gold_dummy_zoption.diff
@@ -4,7 +4,7 @@ Index: b/gold/options.h
===================================================================
--- a/gold/options.h
+++ b/gold/options.h
-@@ -1359,6 +1359,9 @@ class General_options
+@@ -1390,6 +1390,9 @@ class General_options
options::TWO_DASHES, '\0',
N_("Report unresolved symbols as errors"),
NULL, true);
@@ -18,7 +18,7 @@ Index: b/gold/options.cc
===================================================================
--- a/gold/options.cc
+++ b/gold/options.cc
-@@ -967,6 +967,8 @@ parse_short_option(int argc, const char*
+@@ -965,6 +965,8 @@ parse_short_option(int argc, const char*
{
int dummy_i = 0;
const char* dash_z_arg = *arg;
diff --git a/debian/patches/164_ld_doc_remove_xref.diff b/debian/patches/164_ld_doc_remove_xref.diff
index 293724c..51fc77d 100644
--- a/debian/patches/164_ld_doc_remove_xref.diff
+++ b/debian/patches/164_ld_doc_remove_xref.diff
@@ -1,10 +1,8 @@
# DP: In ld.texi, remove cross reference to BFD internals documentation.
-Index: b/ld/ld.texinfo
-===================================================================
---- a/ld/ld.texinfo
-+++ b/ld/ld.texinfo
-@@ -8186,7 +8186,8 @@ may be spent optimizing algorithms for a
+--- a/ld/ld.texi
++++ b/ld/ld.texi
+@@ -8425,7 +8425,8 @@ may be spent optimizing algorithms for a
One minor artifact of the BFD solution which you should bear in
mind is the potential for information loss. There are two places where
useful information can be lost using the BFD mechanism: during
diff --git a/debian/patches/binutils-no-development.diff b/debian/patches/binutils-no-development.diff
new file mode 100644
index 0000000..9eba2f0
--- /dev/null
+++ b/debian/patches/binutils-no-development.diff
@@ -0,0 +1,10 @@
+Index: b/bfd/development.sh
+===================================================================
+--- a/bfd/development.sh
++++ b/bfd/development.sh
+@@ -16,4 +16,4 @@
+ # along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+ # Controls whether to enable development-mode features by default.
+-development=true
++development=false
diff --git a/debian/patches/branch-no-development.diff b/debian/patches/branch-no-development.diff
new file mode 100644
index 0000000..ecbe9c3
--- /dev/null
+++ b/debian/patches/branch-no-development.diff
@@ -0,0 +1,11 @@
+--- a/bfd/development.sh
++++ b/bfd/development.sh
+@@ -16,7 +16,7 @@
+ # along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+ # Controls whether to enable development-mode features by default.
+-development=true
++development=false
+
+ # Indicate whether this is a release branch.
+ experimental=false
diff --git a/debian/patches/branch-updates.diff b/debian/patches/branch-updates.diff
index a83015f..b6f41d9 100644
--- a/debian/patches/branch-updates.diff
+++ b/debian/patches/branch-updates.diff
@@ -1,2217 +1,397 @@
-# DP: updates from the binutils-2.28 branch
+# DP: updates from the binutils-2.33 branch
-# git diff d1b878ec9a4e6a92e2863a8929e9794dd12b13b9 de33d5aed37edb1f2467adab7c2402aef36045b4
+# git diff b5624945ea67525c0ba4ffec7a9d3f9366bf9071 7c65b97032bb8f8572723d4ce10d4f07c00c1734
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
-index 9809bcf..a51642b 100644
+index aa5a81ffed..86ce07a1c1 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
-@@ -1,3 +1,83 @@
-+2017-05-01 Palmer Dabbelt <palmer@dabbelt.com>
-+
-+ * config.bfd (riscv32-*): Enable rv64.
-+
-+2017-04-03 Palmer Dabbelt <palmer@dabbelt.com>
-+
-+ * elfnn-riscv.c (GP_NAME): Delete.
-+ (riscv_global_pointer_value): Change GP_NAME to RISCV_GP_SYMBOL.
-+ (_bfd_riscv_relax_lui): Likewise.
-+
-+2017-01-17 Kuan-Lin Chen <kuanlinchentw@gmail.com>
-+
-+ * elfnn-riscv.c (riscv_elf_object_p): New function.
-+
-+2017-04-26 Maciej W. Rozycki <macro@imgtec.com>
-+
-+ PR ld/21334
-+ * elf-bfd.h (elf_backend_data): Add `always_renumber_dynsyms'
-+ member.
-+ * elfxx-target.h [!elf_backend_always_renumber_dynsyms]
-+ (elf_backend_always_renumber_dynsyms): Define.
-+ (elfNN_bed): Initialize `always_renumber_dynsyms' member.
-+ * elfxx-mips.h (elf_backend_always_renumber_dynsyms): Define.
-+ * elflink.c (bfd_elf_size_dynsym_hash_dynstr): Also call
-+ `_bfd_elf_link_renumber_dynsyms' if the backend has requested
-+ it.
-+ (elf_gc_sweep): Likewise.
-+
-+2017-04-26 Maciej W. Rozycki <macro@imgtec.com>
-+
-+ * elflink.c (elf_gc_sweep): Only call
-+ `_bfd_elf_link_renumber_dynsyms' if dynamic sections have been
-+ created.
-+
-+2017-04-24 H.J. Lu <hongjiu.lu@intel.com>
-+
-+ PR ld/21425
-+ * elf32-i386.c (ELF_MAXPAGESIZE): Set to 0x1000 for VxWorks.
-+
-+2017-03-28 Hans-Peter Nilsson <hp@axis.com>
-+
-+ PR ld/16044
-+ * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Adjust BFD_ASSERT
-+ to handle a local symbol with a hash-symbol-entry; without PLT.
-+ Add BFD_ASSERT for an incidental case with GOT entry present.
-+ (cris_elf_check_relocs): Increment PLT refcount only if the symbol
-+ isn't forced-or-set local.
-+
-+2017-04-13 Alan Modra <amodra@gmail.com>
-+
-+ * elf32-arm.c (arm_type_of_stub): Supply missing args to "long
-+ branch veneers" error. Fix double space and format message.
-+ * elf32-avr.c (avr_add_stub): Do not pass NULL as %B arg.
-+ * elf64-ppc.c (tocsave_find): Supply missing %B arg.
-+
-+2017-04-10 H.J. Lu <hongjiu.lu@intel.com>
-+
-+ PR ld/19579
-+ PR ld/21306
-+ * elf32-s390.c (elf_s390_finish_dynamic_symbol): Check
-+ ELF_COMMON_DEF_P for common symbols.
-+ * elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
-+ * elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
-+ * elflink.c (_bfd_elf_merge_symbol): Revert commits
-+ 202ac193bbbecc96a4978d1ac3d17148253f9b01 and
-+ 07492f668d2173da7a2bda3707ff0985e0f460b6.
-+
-+2017-03-07 Alan Modra <amodra@gmail.com>
-+
-+ PR 21224
-+ PR 20519
-+ * elf64-ppc.c (ppc64_elf_relocate_section): Add missing
-+ dyn_relocs check.
-+
-+2017-03-07 Alan Modra <amodra@gmail.com>
-+
-+ Apply from master
-+ 2017-03-02 Alan Modra <amodra@gmail.com>
-+ * elf32-ppc.c (ppc_elf_vle_split16): Correct insn mask typo.
+@@ -1,3 +1,25 @@
++2019-10-20 John David Anglin <danglin@gcc.gnu.org>
++
++ * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Provide 8-byte
++ minimum alignment for .plt section.
++
++ * elf32-hppa.c: Revise import stub sequences.
++ (LONG_BRANCH_STUB_SIZE): Define.
++ (LONG_BRANCH_SHARED_STUB_SIZE): Define.
++ (IMPORT_STUB_SIZE): Define.
++ (IMPORT_SHARED_STUB_SIZE): Define.
++ (EXPORT_STUB_SIZE): Define.
++ (plt_stub): Revise to not use register %r22.
++ (LDO_R1_R22): Define.
++ (LDW_R22_R21): Define.
++ (LDW_R22_R19): Define.
++ (hppa_build_one_stub): Update stub generation and use new defines.
++ (hppa_size_one_stub): Likewise.
++
++2019-10-13 Nick Clifton <nickc@redhat.com>
++
++ * development.sh (development): Reset to true.
++
+ 2019-10-12 Nick Clifton <nickc@redhat.com>
+
+ Release 2.33.1
+diff --git a/bfd/development.sh b/bfd/development.sh
+index eb0e7b6da1..54d494c105 100644
+--- a/bfd/development.sh
++++ b/bfd/development.sh
+@@ -16,7 +16,7 @@
+ # along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+ # Controls whether to enable development-mode features by default.
+-development=false
++development=true
+
+ # Indicate whether this is a release branch.
+ experimental=false
+diff --git a/bfd/elf32-hppa.c b/bfd/elf32-hppa.c
+index a61adbc3c8..cd99584f27 100644
+--- a/bfd/elf32-hppa.c
++++ b/bfd/elf32-hppa.c
+@@ -71,34 +71,38 @@
+
+ Import stub to call shared library routine from normal object file
+ (single sub-space version)
+- : addil LR'lt_ptr+ltoff,%dp ; get procedure entry point
+- : ldw RR'lt_ptr+ltoff(%r1),%r21
++ : addil LR'lt_ptr+ltoff,%dp ; get PLT address
++ : ldo RR'lt_ptr+ltoff(%r1),%r22 ;
++ : ldw 0(%r22),%r21 ; get procedure entry point
+ : bv %r0(%r21)
+- : ldw RR'lt_ptr+ltoff+4(%r1),%r19 ; get new dlt value.
++ : ldw 4(%r22),%r19 ; get new dlt value.
+
+ Import stub to call shared library routine from shared library
+ (single sub-space version)
+- : addil LR'ltoff,%r19 ; get procedure entry point
+- : ldw RR'ltoff(%r1),%r21
++ : addil LR'ltoff,%r19 ; get PLT address
++ : ldo RR'ltoff(%r1),%r22
++ : ldw 0(%r22),%r21 ; get procedure entry point
+ : bv %r0(%r21)
+- : ldw RR'ltoff+4(%r1),%r19 ; get new dlt value.
++ : ldw 4(%r22),%r19 ; get new dlt value.
+
+ Import stub to call shared library routine from normal object file
+ (multiple sub-space support)
+- : addil LR'lt_ptr+ltoff,%dp ; get procedure entry point
+- : ldw RR'lt_ptr+ltoff(%r1),%r21
+- : ldw RR'lt_ptr+ltoff+4(%r1),%r19 ; get new dlt value.
+- : ldsid (%r21),%r1
++ : addil LR'lt_ptr+ltoff,%dp ; get PLT address
++ : ldo RR'lt_ptr+ltoff(%r1),%r22 ;
++ : ldw 0(%r22),%r21 ; get procedure entry point
++ : ldsid (%r21),%r1 ; get target sid
++ : ldw 4(%r22),%r19 ; get new dlt value.
+ : mtsp %r1,%sr0
+ : be 0(%sr0,%r21) ; branch to target
+ : stw %rp,-24(%sp) ; save rp
+
+ Import stub to call shared library routine from shared library
+ (multiple sub-space support)
+- : addil LR'ltoff,%r19 ; get procedure entry point
+- : ldw RR'ltoff(%r1),%r21
+- : ldw RR'ltoff+4(%r1),%r19 ; get new dlt value.
+- : ldsid (%r21),%r1
++ : addil LR'ltoff,%r19 ; get PLT address
++ : ldo RR'ltoff(%r1),%r22
++ : ldw 0(%r22),%r21 ; get procedure entry point
++ : ldsid (%r21),%r1 ; get target sid
++ : ldw 4(%r22),%r19 ; get new dlt value.
+ : mtsp %r1,%sr0
+ : be 0(%sr0,%r21) ; branch to target
+ : stw %rp,-24(%sp) ; save rp
+@@ -136,12 +140,17 @@
+
+ #define PLT_ENTRY_SIZE 8
+ #define GOT_ENTRY_SIZE 4
++#define LONG_BRANCH_STUB_SIZE 8
++#define LONG_BRANCH_SHARED_STUB_SIZE 12
++#define IMPORT_STUB_SIZE 20
++#define IMPORT_SHARED_STUB_SIZE 32
++#define EXPORT_STUB_SIZE 24
+ #define ELF_DYNAMIC_INTERPRETER "/lib/ld.so.1"
+
+ static const bfd_byte plt_stub[] =
+ {
+- 0x0e, 0x80, 0x10, 0x96, /* 1: ldw 0(%r20),%r22 */
+- 0xea, 0xc0, 0xc0, 0x00, /* bv %r0(%r22) */
++ 0x0e, 0x80, 0x10, 0x95, /* 1: ldw 0(%r20),%r21 */
++ 0xea, 0xa0, 0xc0, 0x00, /* bv %r0(%r21) */
+ 0x0e, 0x88, 0x10, 0x95, /* ldw 4(%r20),%r21 */
+ #define PLT_STUB_ENTRY (3*4)
+ 0xea, 0x9f, 0x1f, 0xdd, /* b,l 1b,%r20 */
+@@ -662,6 +671,10 @@ hppa_type_of_stub (asection *input_sec,
+ #define ADDIL_R19 0x2a600000 /* addil LR'XXX,%r19,%r1 */
+ #define LDW_R1_DP 0x483b0000 /* ldw RR'XXX(%sr0,%r1),%dp */
+
++#define LDO_R1_R22 0x34360000 /* ldo RR'XXX(%r1),%r22 */
++#define LDW_R22_R21 0x0ec01095 /* ldw 0(%r22),%r21 */
++#define LDW_R22_R19 0x0ec81093 /* ldw 4(%r22),%r19 */
++
+ #define LDSID_R21_R1 0x02a010a1 /* ldsid (%sr0,%r21),%r1 */
+ #define MTSP_R1 0x00011820 /* mtsp %r1,%sr0 */
+ #define BE_SR0_R21 0xe2a00000 /* be 0(%sr0,%r21) */
+@@ -734,7 +747,7 @@ hppa_build_one_stub (struct bfd_hash_entry *bh, void *in_arg)
+ insn = hppa_rebuild_insn ((int) BE_SR4_R1, val, 17);
+ bfd_put_32 (stub_bfd, insn, loc + 4);
+
+- size = 8;
++ size = LONG_BRANCH_STUB_SIZE;
+ break;
+
+ case hppa_stub_long_branch_shared:
+@@ -756,7 +769,7 @@ hppa_build_one_stub (struct bfd_hash_entry *bh, void *in_arg)
+ val = hppa_field_adjust (sym_value, (bfd_signed_vma) -8, e_rrsel) >> 2;
+ insn = hppa_rebuild_insn ((int) BE_SR4_R1, val, 17);
+ bfd_put_32 (stub_bfd, insn, loc + 8);
+- size = 12;
++ size = LONG_BRANCH_SHARED_STUB_SIZE;
+ break;
+
+ case hppa_stub_import:
+@@ -776,40 +789,35 @@ hppa_build_one_stub (struct bfd_hash_entry *bh, void *in_arg)
+ if (hsh->stub_type == hppa_stub_import_shared)
+ insn = ADDIL_R19;
+ #endif
+
- 2017-03-02 Tristan Gingold <gingold@adacore.com>
-
- * version.m4: Bump version to 2.28.0
-diff --git a/bfd/config.bfd b/bfd/config.bfd
-index 1b28016..c031216 100644
---- a/bfd/config.bfd
-+++ b/bfd/config.bfd
-@@ -1439,10 +1439,9 @@ case "${targ}" in
- #ifdef BFD64
- riscv32-*-*)
- targ_defvec=riscv_elf32_vec
-- targ_selvecs="riscv_elf32_vec"
-+ targ_selvecs="riscv_elf32_vec riscv_elf64_vec"
- want64=true
- ;;
++ /* Load function descriptor address into register %r22. It is
++ sometimes needed for lazy binding. */
+ val = hppa_field_adjust (sym_value, 0, e_lrsel),
+ insn = hppa_rebuild_insn ((int) insn, val, 21);
+ bfd_put_32 (stub_bfd, insn, loc);
+
+- /* It is critical to use lrsel/rrsel here because we are using
+- two different offsets (+0 and +4) from sym_value. If we use
+- lsel/rsel then with unfortunate sym_values we will round
+- sym_value+4 up to the next 2k block leading to a mis-match
+- between the lsel and rsel value. */
+ val = hppa_field_adjust (sym_value, 0, e_rrsel);
+- insn = hppa_rebuild_insn ((int) LDW_R1_R21, val, 14);
++ insn = hppa_rebuild_insn ((int) LDO_R1_R22, val, 14);
+ bfd_put_32 (stub_bfd, insn, loc + 4);
+
++ bfd_put_32 (stub_bfd, (bfd_vma) LDW_R22_R21, loc + 8);
++
+ if (htab->multi_subspace)
+ {
+- val = hppa_field_adjust (sym_value, (bfd_signed_vma) 4, e_rrsel);
+- insn = hppa_rebuild_insn ((int) LDW_R1_DLT, val, 14);
+- bfd_put_32 (stub_bfd, insn, loc + 8);
-
- riscv64-*-*)
- targ_defvec=riscv_elf64_vec
- targ_selvecs="riscv_elf32_vec riscv_elf64_vec"
-diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h
-index 5de9ab6..dc4bd87 100644
---- a/bfd/elf-bfd.h
-+++ b/bfd/elf-bfd.h
-@@ -1478,6 +1478,10 @@ struct elf_backend_data
- /* Address of protected data defined in the shared library may be
- external, i.e., due to copy relocation. */
- unsigned extern_protected_data : 1;
-+
-+ /* True if `_bfd_elf_link_renumber_dynsyms' must be called even for
-+ static binaries. */
-+ unsigned always_renumber_dynsyms : 1;
- };
-
- /* Information about reloc sections associated with a bfd_elf_section_data
-diff --git a/bfd/elf32-arm.c b/bfd/elf32-arm.c
-index 0a78595..e04caef 100644
---- a/bfd/elf32-arm.c
-+++ b/bfd/elf32-arm.c
-@@ -4024,10 +4024,12 @@ arm_type_of_stub (struct bfd_link_info *info,
- if (!thumb_only)
- {
- if (input_sec->flags & SEC_ELF_PURECODE)
-- _bfd_error_handler (_("\
--%B(%A): warning: long branch veneers used in section with SHF_ARM_PURECODE section \
--attribute is only supported for M-profile targets that implement the movw instruction."),
-- input_sec);
-+ _bfd_error_handler
-+ (_("%B(%A): warning: long branch veneers used in"
-+ " section with SHF_ARM_PURECODE section"
-+ " attribute is only supported for M-profile"
-+ " targets that implement the movw instruction."),
-+ input_bfd, input_sec);
-
- stub_type = (bfd_link_pic (info) | globals->pic_veneer)
- /* PIC stubs. */
-@@ -4056,10 +4058,12 @@ attribute is only supported for M-profile targets that implement the movw instru
- else
- {
- if (input_sec->flags & SEC_ELF_PURECODE)
-- _bfd_error_handler (_("\
--%B(%A): warning: long branch veneers used in section with SHF_ARM_PURECODE section \
--attribute is only supported for M-profile targets that implement the movw instruction."),
-- input_sec);
-+ _bfd_error_handler
-+ (_("%B(%A): warning: long branch veneers used in"
-+ " section with SHF_ARM_PURECODE section"
-+ " attribute is only supported for M-profile"
-+ " targets that implement the movw instruction."),
-+ input_bfd, input_sec);
-
- stub_type = (bfd_link_pic (info) | globals->pic_veneer)
- /* PIC stub. */
-@@ -4073,13 +4077,12 @@ attribute is only supported for M-profile targets that implement the movw instru
- else
- {
- if (input_sec->flags & SEC_ELF_PURECODE)
-- _bfd_error_handler (_("%B(%s): warning: long branch "
-- " veneers used in section with "
-- "SHF_ARM_PURECODE section "
-- "attribute is only supported"
-- " for M-profile targets that "
-- "implement the movw "
-- "instruction."));
-+ _bfd_error_handler
-+ (_("%B(%A): warning: long branch veneers used in"
-+ " section with SHF_ARM_PURECODE section"
-+ " attribute is only supported" " for M-profile"
-+ " targets that implement the movw instruction."),
-+ input_bfd, input_sec);
-
- /* Thumb to arm. */
- if (sym_sec != NULL
-@@ -4126,13 +4129,12 @@ attribute is only supported for M-profile targets that implement the movw instru
- || r_type == R_ARM_TLS_CALL)
- {
- if (input_sec->flags & SEC_ELF_PURECODE)
-- _bfd_error_handler (_("%B(%s): warning: long branch "
-- " veneers used in section with "
-- "SHF_ARM_PURECODE section "
-- "attribute is only supported"
-- " for M-profile targets that "
-- "implement the movw "
-- "instruction."));
-+ _bfd_error_handler
-+ (_("%B(%A): warning: long branch veneers used in"
-+ " section with SHF_ARM_PURECODE section"
-+ " attribute is only supported for M-profile"
-+ " targets that implement the movw instruction."),
-+ input_bfd, input_sec);
- if (branch_type == ST_BRANCH_TO_THUMB)
+ bfd_put_32 (stub_bfd, (bfd_vma) LDSID_R21_R1, loc + 12);
+- bfd_put_32 (stub_bfd, (bfd_vma) MTSP_R1, loc + 16);
+- bfd_put_32 (stub_bfd, (bfd_vma) BE_SR0_R21, loc + 20);
+- bfd_put_32 (stub_bfd, (bfd_vma) STW_RP, loc + 24);
++ bfd_put_32 (stub_bfd, (bfd_vma) LDW_R22_R19, loc + 16);
++ bfd_put_32 (stub_bfd, (bfd_vma) MTSP_R1, loc + 20);
++ bfd_put_32 (stub_bfd, (bfd_vma) BE_SR0_R21, loc + 24);
++ bfd_put_32 (stub_bfd, (bfd_vma) STW_RP, loc + 28);
+
+- size = 28;
++ size = IMPORT_SHARED_STUB_SIZE;
+ }
+ else
{
- /* Arm to thumb. */
-diff --git a/bfd/elf32-avr.c b/bfd/elf32-avr.c
-index 56b143d..0f6c188 100644
---- a/bfd/elf32-avr.c
-+++ b/bfd/elf32-avr.c
-@@ -3284,8 +3284,7 @@ avr_add_stub (const char *stub_name,
- if (hsh == NULL)
+- bfd_put_32 (stub_bfd, (bfd_vma) BV_R0_R21, loc + 8);
+- val = hppa_field_adjust (sym_value, (bfd_signed_vma) 4, e_rrsel);
+- insn = hppa_rebuild_insn ((int) LDW_R1_DLT, val, 14);
+- bfd_put_32 (stub_bfd, insn, loc + 12);
++ bfd_put_32 (stub_bfd, (bfd_vma) BV_R0_R21, loc + 12);
++ bfd_put_32 (stub_bfd, (bfd_vma) LDW_R22_R19, loc + 16);
+
+- size = 16;
++ size = IMPORT_STUB_SIZE;
+ }
+
+ break;
+@@ -858,7 +866,7 @@ hppa_build_one_stub (struct bfd_hash_entry *bh, void *in_arg)
+ hsh->hh->eh.root.u.def.section = stub_sec;
+ hsh->hh->eh.root.u.def.value = stub_sec->size;
+
+- size = 24;
++ size = EXPORT_STUB_SIZE;
+ break;
+
+ default:
+@@ -906,17 +914,17 @@ hppa_size_one_stub (struct bfd_hash_entry *bh, void *in_arg)
+ htab = in_arg;
+
+ if (hsh->stub_type == hppa_stub_long_branch)
+- size = 8;
++ size = LONG_BRANCH_STUB_SIZE;
+ else if (hsh->stub_type == hppa_stub_long_branch_shared)
+- size = 12;
++ size = LONG_BRANCH_SHARED_STUB_SIZE;
+ else if (hsh->stub_type == hppa_stub_export)
+- size = 24;
++ size = EXPORT_STUB_SIZE;
+ else /* hppa_stub_import or hppa_stub_import_shared. */
{
- /* xgettext:c-format */
-- _bfd_error_handler (_("%B: cannot create stub entry %s"),
-- NULL, stub_name);
-+ _bfd_error_handler (_("cannot create stub entry %s"), stub_name);
- return NULL;
+ if (htab->multi_subspace)
+- size = 28;
++ size = IMPORT_SHARED_STUB_SIZE;
+ else
+- size = 16;
++ size = IMPORT_STUB_SIZE;
}
-diff --git a/bfd/elf32-cris.c b/bfd/elf32-cris.c
-index 97b8cc3..d4bbceb 100644
---- a/bfd/elf32-cris.c
-+++ b/bfd/elf32-cris.c
-@@ -2714,8 +2714,9 @@ elf_cris_adjust_gotplt_to_got (struct elf_cris_link_hash_entry *h, void * p)
- struct bfd_link_info *info = (struct bfd_link_info *) p;
-
- /* A GOTPLT reloc, when activated, is supposed to be included into
-- the PLT refcount. */
-+ the PLT refcount, when the symbol isn't set-or-forced local. */
- BFD_ASSERT (h->gotplt_refcount == 0
-+ || h->root.plt.refcount == -1
- || h->gotplt_refcount <= h->root.plt.refcount);
-
- /* If nobody wanted a GOTPLT with this symbol, we're done. */
-@@ -2741,6 +2742,7 @@ elf_cris_adjust_gotplt_to_got (struct elf_cris_link_hash_entry *h, void * p)
- srelgot = elf_hash_table (info)->srelgot;
-
- /* Put accurate refcounts there. */
-+ BFD_ASSERT (h->root.got.refcount >= 0);
- h->root.got.refcount += h->gotplt_refcount;
- h->reg_got_refcount = h->gotplt_refcount;
-
-@@ -3476,7 +3478,10 @@ cris_elf_check_relocs (bfd *abfd,
- continue;
-
- h->needs_plt = 1;
-- h->plt.refcount++;
-+
-+ /* If the symbol is forced local, the refcount is unavailable. */
-+ if (h->plt.refcount != -1)
-+ h->plt.refcount++;
- break;
-
- case R_CRIS_8:
-diff --git a/bfd/elf32-i386.c b/bfd/elf32-i386.c
-index 24beba3..f570253 100644
---- a/bfd/elf32-i386.c
-+++ b/bfd/elf32-i386.c
-@@ -6576,6 +6576,8 @@ elf32_i386_nacl_elf_object_p (bfd *abfd)
- #undef TARGET_LITTLE_NAME
- #define TARGET_LITTLE_NAME "elf32-i386-vxworks"
- #undef ELF_OSABI
-+#undef ELF_MAXPAGESIZE
-+#define ELF_MAXPAGESIZE 0x1000
- #undef elf_backend_plt_alignment
- #define elf_backend_plt_alignment 4
-
-diff --git a/bfd/elf32-ppc.c b/bfd/elf32-ppc.c
-index 0f3eb68..10caa8a 100644
---- a/bfd/elf32-ppc.c
-+++ b/bfd/elf32-ppc.c
-@@ -4921,7 +4921,7 @@ ppc_elf_vle_split16 (bfd *input_bfd,
- unsigned int insn, opcode, top5;
-
- insn = bfd_get_32 (input_bfd, loc);
-- opcode = insn & 0xf300f800;
-+ opcode = insn & 0xfc00f800;
- if (opcode == E_OR2I_INSN
- || opcode == E_AND2I_DOT_INSN
- || opcode == E_OR2IS_INSN
-diff --git a/bfd/elf32-s390.c b/bfd/elf32-s390.c
-index fd1bc13..ddb6f5b 100644
---- a/bfd/elf32-s390.c
-+++ b/bfd/elf32-s390.c
-@@ -3785,7 +3785,7 @@ elf_s390_finish_dynamic_symbol (bfd *output_bfd,
- RELATIVE reloc. The entry in the global offset table
- will already have been initialized in the
- relocate_section function. */
-- if (!h->def_regular)
-+ if (!(h->def_regular || ELF_COMMON_DEF_P (h)))
- return FALSE;
- BFD_ASSERT((h->got.offset & 1) != 0);
- rela.r_info = ELF32_R_INFO (0, R_390_RELATIVE);
-diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c
-index e7d4792..765bc6b 100644
---- a/bfd/elf64-ppc.c
-+++ b/bfd/elf64-ppc.c
-@@ -7627,7 +7627,7 @@ tocsave_find (struct ppc_link_hash_table *htab,
- if (ent.sec == NULL || ent.sec->output_section == NULL)
- {
- _bfd_error_handler
-- (_("%B: undefined symbol on R_PPC64_TOCSAVE relocation"));
-+ (_("%B: undefined symbol on R_PPC64_TOCSAVE relocation"), ibfd);
- return NULL;
- }
-
-@@ -14798,8 +14798,10 @@ ppc64_elf_relocate_section (bfd *output_bfd,
- break;
-
- if (bfd_link_pic (info)
-- ? ((h != NULL && pc_dynrelocs (h))
-- || must_be_dyn_reloc (info, r_type))
-+ ? ((h == NULL
-+ || h->dyn_relocs != NULL)
-+ && ((h != NULL && pc_dynrelocs (h))
-+ || must_be_dyn_reloc (info, r_type)))
- : (h != NULL
- ? h->dyn_relocs != NULL
- : ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC))
-diff --git a/bfd/elf64-s390.c b/bfd/elf64-s390.c
-index b5fd05f..fbbf8d6 100644
---- a/bfd/elf64-s390.c
-+++ b/bfd/elf64-s390.c
-@@ -3582,7 +3582,7 @@ elf_s390_finish_dynamic_symbol (bfd *output_bfd,
- RELATIVE reloc. The entry in the global offset table
- will already have been initialized in the
- relocate_section function. */
-- if (!h->def_regular)
-+ if (!(h->def_regular || ELF_COMMON_DEF_P (h)))
- return FALSE;
- BFD_ASSERT((h->got.offset & 1) != 0);
- rela.r_info = ELF64_R_INFO (0, R_390_RELATIVE);
-diff --git a/bfd/elf64-x86-64.c b/bfd/elf64-x86-64.c
-index e0e6c16..e363eaf 100644
---- a/bfd/elf64-x86-64.c
-+++ b/bfd/elf64-x86-64.c
-@@ -4926,7 +4926,8 @@ do_ifunc_pointer:
- {
- /* Symbol is referenced locally. Make sure it is
- defined locally or for a branch. */
-- fail = !h->def_regular && !branch;
-+ fail = (!(h->def_regular || ELF_COMMON_DEF_P (h))
-+ && !branch);
- }
- else if (!(bfd_link_pie (info)
- && (h->needs_copy || eh->needs_copy)))
-diff --git a/bfd/elflink.c b/bfd/elflink.c
-index 69b66f2..cd03a13 100644
---- a/bfd/elflink.c
-+++ b/bfd/elflink.c
-@@ -1543,16 +1543,13 @@ _bfd_elf_merge_symbol (bfd *abfd,
- represent variables; this can cause confusion in principle, but
- any such confusion would seem to indicate an erroneous program or
- shared library. We also permit a common symbol in a regular
-- object to override a weak symbol in a shared object. A common
-- symbol in executable also overrides a symbol in a shared object. */
-+ object to override a weak symbol in a shared object. */
-
- if (newdyn
- && newdef
- && (olddef
- || (h->root.type == bfd_link_hash_common
-- && (newweak
-- || newfunc
-- || (!olddyn && bfd_link_executable (info))))))
-+ && (newweak || newfunc))))
- {
- *override = TRUE;
- newdef = FALSE;
-@@ -6710,6 +6707,8 @@ bfd_boolean
- bfd_elf_size_dynsym_hash_dynstr (bfd *output_bfd, struct bfd_link_info *info)
- {
- const struct elf_backend_data *bed;
-+ unsigned long section_sym_count;
-+ bfd_size_type dynsymcount;
-
- if (!is_elf_hash_table (info->hash))
- return TRUE;
-@@ -6717,24 +6716,30 @@ bfd_elf_size_dynsym_hash_dynstr (bfd *output_bfd, struct bfd_link_info *info)
- bed = get_elf_backend_data (output_bfd);
- (*bed->elf_backend_init_index_section) (output_bfd, info);
-
-+ /* Assign dynsym indices. In a shared library we generate a section
-+ symbol for each output section, which come first. Next come all
-+ of the back-end allocated local dynamic syms, followed by the rest
-+ of the global symbols.
-+
-+ This is usually not needed for static binaries, however backends
-+ can request to always do it, e.g. the MIPS backend uses dynamic
-+ symbol counts to lay out GOT, which will be produced in the
-+ presence of GOT relocations even in static binaries (holding fixed
-+ data in that case, to satisfy those relocations). */
-+
-+ if (elf_hash_table (info)->dynamic_sections_created
-+ || bed->always_renumber_dynsyms)
-+ dynsymcount = _bfd_elf_link_renumber_dynsyms (output_bfd, info,
-+ &section_sym_count);
-+
- if (elf_hash_table (info)->dynamic_sections_created)
- {
- bfd *dynobj;
- asection *s;
-- bfd_size_type dynsymcount;
-- unsigned long section_sym_count;
- unsigned int dtagcount;
-
- dynobj = elf_hash_table (info)->dynobj;
-
-- /* Assign dynsym indicies. In a shared library we generate a
-- section symbol for each output section, which come first.
-- Next come all of the back-end allocated local dynamic syms,
-- followed by the rest of the global symbols. */
--
-- dynsymcount = _bfd_elf_link_renumber_dynsyms (output_bfd, info,
-- &section_sym_count);
--
- /* Work out the size of the symbol version section. */
- s = bfd_get_linker_section (dynobj, ".gnu.version");
- BFD_ASSERT (s != NULL);
-@@ -12986,7 +12991,12 @@ elf_gc_sweep (bfd *abfd, struct bfd_link_info *info)
- elf_link_hash_traverse (elf_hash_table (info), elf_gc_sweep_symbol,
- &sweep_info);
-
-- _bfd_elf_link_renumber_dynsyms (abfd, info, &section_sym_count);
-+ /* We need to reassign dynsym indices now that symbols may have
-+ been removed. See the call in `bfd_elf_size_dynsym_hash_dynstr'
-+ for the details of the conditions used here. */
-+ if (elf_hash_table (info)->dynamic_sections_created
-+ || bed->always_renumber_dynsyms)
-+ _bfd_elf_link_renumber_dynsyms (abfd, info, &section_sym_count);
- return TRUE;
- }
-
-diff --git a/bfd/elfnn-riscv.c b/bfd/elfnn-riscv.c
-index ff25ebd..3c04507 100644
---- a/bfd/elfnn-riscv.c
-+++ b/bfd/elfnn-riscv.c
-@@ -52,10 +52,6 @@
- #define ELF_MAXPAGESIZE 0x1000
- #define ELF_COMMONPAGESIZE 0x1000
-
--/* The global pointer's symbol name. */
--
--#define GP_NAME "__global_pointer$"
--
- /* The RISC-V linker needs to keep track of the number of relocs that it
- decides to copy as dynamic relocs in check_relocs for each symbol.
- This is so that it can later discard them if they are found to be
-@@ -1467,7 +1463,7 @@ riscv_global_pointer_value (struct bfd_link_info *info)
- {
- struct bfd_link_hash_entry *h;
-
-- h = bfd_link_hash_lookup (info->hash, GP_NAME, FALSE, FALSE, TRUE);
-+ h = bfd_link_hash_lookup (info->hash, RISCV_GP_SYMBOL, FALSE, FALSE, TRUE);
- if (h == NULL || h->type != bfd_link_hash_defined)
- return 0;
-
-@@ -2818,7 +2814,8 @@ _bfd_riscv_relax_lui (bfd *abfd,
- /* If gp and the symbol are in the same output section, then
- consider only that section's alignment. */
- struct bfd_link_hash_entry *h =
-- bfd_link_hash_lookup (link_info->hash, GP_NAME, FALSE, FALSE, TRUE);
-+ bfd_link_hash_lookup (link_info->hash, RISCV_GP_SYMBOL, FALSE, FALSE,
-+ TRUE);
- if (h->u.def.section->output_section == sym_sec->output_section)
- max_alignment = (bfd_vma) 1 << sym_sec->output_section->alignment_power;
- }
-@@ -3205,6 +3202,19 @@ riscv_elf_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
- return TRUE;
- }
-
-+/* Set the right mach type. */
-+static bfd_boolean
-+riscv_elf_object_p (bfd *abfd)
-+{
-+ /* There are only two mach types in RISCV currently. */
-+ if (strcmp (abfd->xvec->name, "elf32-littleriscv") == 0)
-+ bfd_default_set_arch_mach (abfd, bfd_arch_riscv, bfd_mach_riscv32);
-+ else
-+ bfd_default_set_arch_mach (abfd, bfd_arch_riscv, bfd_mach_riscv64);
-+
-+ return TRUE;
-+}
-+
-
- #define TARGET_LITTLE_SYM riscv_elfNN_vec
- #define TARGET_LITTLE_NAME "elfNN-littleriscv"
-@@ -3230,6 +3240,7 @@ riscv_elf_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
- #define elf_backend_plt_sym_val riscv_elf_plt_sym_val
- #define elf_backend_grok_prstatus riscv_elf_grok_prstatus
- #define elf_backend_grok_psinfo riscv_elf_grok_psinfo
-+#define elf_backend_object_p riscv_elf_object_p
- #define elf_info_to_howto_rel NULL
- #define elf_info_to_howto riscv_info_to_howto_rela
- #define bfd_elfNN_bfd_relax_section _bfd_riscv_relax_section
-diff --git a/bfd/elfxx-mips.h b/bfd/elfxx-mips.h
-index fa5b5d2..274129b 100644
---- a/bfd/elfxx-mips.h
-+++ b/bfd/elfxx-mips.h
-@@ -196,3 +196,4 @@ literal_reloc_p (int r_type)
- #define elf_backend_post_process_headers _bfd_mips_post_process_headers
- #define elf_backend_compact_eh_encoding _bfd_mips_elf_compact_eh_encoding
- #define elf_backend_cant_unwind_opcode _bfd_mips_elf_cant_unwind_opcode
-+#define elf_backend_always_renumber_dynsyms TRUE
-diff --git a/bfd/elfxx-target.h b/bfd/elfxx-target.h
-index d063fb7..d07600c 100644
---- a/bfd/elfxx-target.h
-+++ b/bfd/elfxx-target.h
-@@ -126,6 +126,9 @@
- #ifndef elf_backend_extern_protected_data
- #define elf_backend_extern_protected_data 0
- #endif
-+#ifndef elf_backend_always_renumber_dynsyms
-+#define elf_backend_always_renumber_dynsyms FALSE
-+#endif
- #ifndef elf_backend_stack_align
- #define elf_backend_stack_align 16
- #endif
-@@ -866,7 +869,8 @@ static struct elf_backend_data elfNN_bed =
- elf_backend_no_page_alias,
- elf_backend_default_execstack,
- elf_backend_caches_rawsize,
-- elf_backend_extern_protected_data
-+ elf_backend_extern_protected_data,
-+ elf_backend_always_renumber_dynsyms
- };
-
- /* Forward declaration for use when initialising alternative_target field. */
+ hsh->stub_sec->size += size;
+@@ -2272,10 +2280,11 @@ elf32_hppa_size_dynamic_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
+ against the .got section. */
+ int gotalign = bfd_section_alignment (dynobj, htab->etab.sgot);
+ int pltalign = bfd_section_alignment (dynobj, sec);
++ int align = gotalign > 3 ? gotalign : 3;
+ bfd_size_type mask;
+
+- if (gotalign > pltalign)
+- (void) bfd_set_section_alignment (dynobj, sec, gotalign);
++ if (align > pltalign)
++ (void) bfd_set_section_alignment (dynobj, sec, align);
+ mask = ((bfd_size_type) 1 << gotalign) - 1;
+ sec->size = (sec->size + sizeof (plt_stub) + mask) & ~mask;
+ }
diff --git a/bfd/version.h b/bfd/version.h
-index eda06e4..a03012f 100644
+index c83a871701..14b15f3991 100644
--- a/bfd/version.h
+++ b/bfd/version.h
-@@ -1,4 +1,4 @@
--#define BFD_VERSION_DATE 20170302
-+#define BFD_VERSION_DATE 20170510
+@@ -16,7 +16,7 @@
+
+ In releases, the date is not included in either version strings or
+ sonames. */
+-#define BFD_VERSION_DATE 20191012
++#define BFD_VERSION_DATE 20191020
#define BFD_VERSION @bfd_version@
#define BFD_VERSION_STRING @bfd_version_package@ @bfd_version_string@
#define REPORT_BUGS_TO @report_bugs_to@
diff --git a/gas/ChangeLog b/gas/ChangeLog
-index fa9ecbe..d6ab8a1 100644
+index 75324bfaac..0955809b5b 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
-@@ -1,3 +1,68 @@
-+2017-04-03 Palmer Dabbelt <palmer@dabbelt.com>
-+
-+ * config/tc-riscv.c (riscv_clear_subsets): Cast argument to free to
-+ avoid const warnings.
-+
-+2017-03-30 Palmer Dabbelt <palmer@dabbelt.com>
-+
-+ * config/tc-riscv.c (riscv_clear_subsets): New function.
-+ (riscv_add_subset): Call riscv_clear_subsets and riscv_set_rvc to
-+ clear RVC when it's been previously set.
-+
-+2017-03-21 Palmer Dabbbelt <palmer@dabbelt.com>
-+
-+ * config/tc-riscv.c (md_show_usage): Remove defuct -m32, -m64,
-+ -msoft-float, -mhard-float, -mno-rvc, and -mrvc options; and don't
-+ print an invalid default ISA string.
-+ * doc/c-riscv.texi (OPTIONS): Add -fpic and -fno-pic options.
-+
-+2017-03-14 Kito Cheng <kito.cheng@gmail.com>
-+
-+ * config/tc-riscv.c (validate_riscv_insn): Add 'o' RVC immediate
-+ encoding format, which can accept 0-valued immediates.
-+ (riscv_ip): Likewise.
-+
-+2017-03-02 Kuan-Lin Chen <rufus@andestech.com>
-+
-+ * config/tc-riscv.h (HWARD2_USE_FIXED_ADVANCE_PC): New define.
-+
-+2017-03-02 Kuan-Lin Chen <rufus@andestech.com>
-+
-+ * config/tc-riscv.c (md_apply_fix): Set fx_frag and
-+ fx_next->fx_frag for CFA_advance_loc relocations.
-+
-+2017-03-02 Kuan-Lin Chen <rufus@andestech.com>
-+
-+ * config/tc-riscv.c (md_apply_fix): Compute the correct offsets
-+ for CFA relocations.
-+
-+2017-03-27 Alan Modra <amodra@gmail.com>
-+
-+ PR 21303
-+ * testsuite/gas/ppc/pr21303.d,
-+ * testsuite/gas/ppc/pr21303.s: New test
-+ * testsuite/gas/ppc/ppc.exp: Run it.
-+
-+2017-03-21 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
-+
-+ Backport from mainline
-+ 2017-03-21 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
-+
-+ * config/tc-s390.c (s390_parse_cpu): Remove S390_INSTR_FLAG_VX2
-+ from cpu_table. Remove vx2, and novx2 from cpu_flags.
-+
-+2017-03-08 Peter Bergner <bergner@vnet.ibm.com>
-+
-+ * testsuite/gas/ppc/altivec2.d (as): Use the -mpower8 option.
-+ (objdump): Use the -Mpower8 option.
-+
-+2017-03-08 Peter Bergner <bergner@vnet.ibm.com>
-+
-+ Apply from master.
-+ 2017-03-08 Peter Bergner <bergner@vnet.ibm.com>
-+ * testsuite/gas/ppc/power9.d <lnia> New test.
-+ * testsuite/gas/ppc/power9.s: Likewise.
-+
- 2017-03-02 Tristan Gingold <gingold@adacore.com>
-
- * configure: Regenerate.
-diff --git a/gas/config/tc-riscv.c b/gas/config/tc-riscv.c
-index ec5b0bb..88457c6 100644
---- a/gas/config/tc-riscv.c
-+++ b/gas/config/tc-riscv.c
-@@ -121,6 +121,18 @@ riscv_subset_supports (const char *feature)
- }
+@@ -1,3 +1,17 @@
++2019-10-14 Tamar Christina <tamar.christina@arm.com>
++
++ Backported from mainline.
++ 2019-09-24 Tamar Christina <tamar.christina@arm.com>
++
++ PR gas/24991
++ * config/tc-arm.c (out_of_range_p): New.
++ (md_apply_fix): Use it in BFD_RELOC_THUMB_PCREL_BRANCH9,
++ BFD_RELOC_THUMB_PCREL_BRANCH12, BFD_RELOC_THUMB_PCREL_BRANCH20,
++ BFD_RELOC_THUMB_PCREL_BRANCH23, BFD_RELOC_THUMB_PCREL_BRANCH25
++ * testsuite/gas/arm/pr24991.d: New test.
++ * testsuite/gas/arm/pr24991.l: New test.
++ * testsuite/gas/arm/pr24991.s: New test.
++
+ 2019-10-12 Nick Clifton <nickc@redhat.com>
+
+ Release 2.33.1
+diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
+index 9273bb5783..caabdbba90 100644
+--- a/gas/config/tc-arm.c
++++ b/gas/config/tc-arm.c
+@@ -106,6 +106,15 @@ enum arm_float_abi
+ should define CPU_DEFAULT here. */
+ #endif
- static void
-+riscv_clear_subsets (void)
-+{
-+ while (riscv_subsets != NULL)
-+ {
-+ struct riscv_subset *next = riscv_subsets->next;
-+ free ((void *) riscv_subsets->name);
-+ free (riscv_subsets);
-+ riscv_subsets = next;
-+ }
++/* Perform range checks on positive and negative overflows by checking if the
++ VALUE given fits within the range of an BITS sized immediate. */
++static bfd_boolean out_of_range_p (offsetT value, offsetT bits)
++ {
++ gas_assert (bits < (offsetT)(sizeof (value) * 8));
++ return (value & ~((1 << bits)-1))
++ && ((value & ~((1 << bits)-1)) != ~((1 << bits)-1));
+}
+
-+static void
- riscv_add_subset (const char *subset)
- {
- struct riscv_subset *s = xmalloc (sizeof *s);
-@@ -139,6 +151,8 @@ riscv_set_arch (const char *s)
- const char *extension = NULL;
- const char *p = s;
-
-+ riscv_clear_subsets();
-+
- if (strncmp (p, "rv32", 4) == 0)
- {
- xlen = 32;
-@@ -500,6 +514,7 @@ validate_riscv_insn (const struct riscv_opcode *opc)
- case 'c': break; /* RS1, constrained to equal sp */
- case 'i': used_bits |= ENCODE_RVC_SIMM3(-1U); break;
- case 'j': used_bits |= ENCODE_RVC_IMM (-1U); break;
-+ case 'o': used_bits |= ENCODE_RVC_IMM (-1U); break;
- case 'k': used_bits |= ENCODE_RVC_LW_IMM (-1U); break;
- case 'l': used_bits |= ENCODE_RVC_LD_IMM (-1U); break;
- case 'm': used_bits |= ENCODE_RVC_LWSP_IMM (-1U); break;
-@@ -1321,6 +1336,13 @@ rvc_imm_done:
- ip->insn_opcode |=
- ENCODE_RVC_LDSP_IMM (imm_expr->X_add_number);
- goto rvc_imm_done;
-+ case 'o':
-+ if (my_getSmallExpression (imm_expr, imm_reloc, s, p)
-+ || imm_expr->X_op != O_constant
-+ || !VALID_RVC_IMM (imm_expr->X_add_number))
-+ break;
-+ ip->insn_opcode |= ENCODE_RVC_IMM (imm_expr->X_add_number);
-+ goto rvc_imm_done;
- case 'K':
- if (my_getSmallExpression (imm_expr, imm_reloc, s, p)
- || imm_expr->X_op != O_constant
-@@ -1794,6 +1816,7 @@ riscv_after_parse_args (void)
- riscv_set_arch (xlen == 64 ? "rv64g" : "rv32g");
-
- /* Add the RVC extension, regardless of -march, to support .option rvc. */
-+ riscv_set_rvc (FALSE);
- if (riscv_subset_supports ("c"))
- riscv_set_rvc (TRUE);
- else
-@@ -1837,6 +1860,7 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
- unsigned int subtype;
- bfd_byte *buf = (bfd_byte *) (fixP->fx_frag->fr_literal + fixP->fx_where);
- bfd_boolean relaxable = FALSE;
-+ offsetT loc;
-
- /* Remember value for tc_gen_reloc. */
- fixP->fx_addnumber = *valP;
-@@ -1922,30 +1946,31 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
-
- case BFD_RELOC_RISCV_CFA:
- /* Load the byte to get the subtype. */
-- subtype = bfd_get_8 (NULL, &fixP->fx_frag->fr_literal[fixP->fx_where]);
-+ subtype = bfd_get_8 (NULL, &((fragS *) (fixP->fx_frag->fr_opcode))->fr_literal[fixP->fx_where]);
-+ loc = fixP->fx_frag->fr_fix - (subtype & 7);
- switch (subtype)
- {
- case DW_CFA_advance_loc1:
-- fixP->fx_where++;
-- fixP->fx_next->fx_where++;
-+ fixP->fx_where = loc + 1;
-+ fixP->fx_next->fx_where = loc + 1;
- fixP->fx_r_type = BFD_RELOC_RISCV_SET8;
- fixP->fx_next->fx_r_type = BFD_RELOC_RISCV_SUB8;
- break;
-
- case DW_CFA_advance_loc2:
- fixP->fx_size = 2;
-- fixP->fx_where++;
- fixP->fx_next->fx_size = 2;
-- fixP->fx_next->fx_where++;
-+ fixP->fx_where = loc + 1;
-+ fixP->fx_next->fx_where = loc + 1;
- fixP->fx_r_type = BFD_RELOC_RISCV_SET16;
- fixP->fx_next->fx_r_type = BFD_RELOC_RISCV_SUB16;
- break;
-
- case DW_CFA_advance_loc4:
- fixP->fx_size = 4;
-- fixP->fx_where++;
- fixP->fx_next->fx_size = 4;
-- fixP->fx_next->fx_where++;
-+ fixP->fx_where = loc;
-+ fixP->fx_next->fx_where = loc;
- fixP->fx_r_type = BFD_RELOC_RISCV_SET32;
- fixP->fx_next->fx_r_type = BFD_RELOC_RISCV_SUB32;
- break;
-@@ -1954,6 +1979,8 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
- if (subtype < 0x80 && (subtype & 0x40))
- {
- /* DW_CFA_advance_loc */
-+ fixP->fx_frag = (fragS *) fixP->fx_frag->fr_opcode;
-+ fixP->fx_next->fx_frag = fixP->fx_frag;
- fixP->fx_r_type = BFD_RELOC_RISCV_SET6;
- fixP->fx_next->fx_r_type = BFD_RELOC_RISCV_SUB6;
- }
-@@ -2069,7 +2096,6 @@ riscv_pre_output_hook (void)
- {
- if (frag->fr_type == rs_cfa)
- {
-- fragS *loc4_frag;
- expressionS exp;
-
- symbolS *add_symbol = frag->fr_symbol->sy_value.X_add_symbol;
-@@ -2080,8 +2106,7 @@ riscv_pre_output_hook (void)
- exp.X_add_number = 0;
- exp.X_op_symbol = op_symbol;
-
-- loc4_frag = (fragS *) frag->fr_opcode;
-- fix_new_exp (loc4_frag, (int) frag->fr_offset, 1, &exp, 0,
-+ fix_new_exp (frag, (int) frag->fr_offset, 1, &exp, 0,
- BFD_RELOC_RISCV_CFA);
- }
- }
-@@ -2455,15 +2480,10 @@ md_show_usage (FILE *stream)
- {
- fprintf (stream, _("\
- RISC-V options:\n\
-- -m32 assemble RV32 code\n\
-- -m64 assemble RV64 code (default)\n\
- -fpic generate position-independent code\n\
- -fno-pic don't generate position-independent code (default)\n\
-- -msoft-float don't use F registers for floating-point values\n\
-- -mhard-float use F registers for floating-point values (default)\n\
-- -mno-rvc disable the C extension for compressed instructions (default)\n\
-- -mrvc enable the C extension for compressed instructions\n\
-- -march=ISA set the RISC-V architecture, RV64IMAFD by default\n\
-+ -march=ISA set the RISC-V architecture\n\
-+ -mabi=ABI set the RISC-V ABI\n\
- "));
- }
-
-diff --git a/gas/config/tc-riscv.h b/gas/config/tc-riscv.h
-index ae8d60e..e92b387 100644
---- a/gas/config/tc-riscv.h
-+++ b/gas/config/tc-riscv.h
-@@ -112,4 +112,7 @@ extern int tc_riscv_regname_to_dw2regnum (char *);
- #define elf_tc_final_processing riscv_elf_final_processing
- extern void riscv_elf_final_processing (void);
-
-+/* Adjust debug_line after relaxation. */
-+#define DWARF2_USE_FIXED_ADVANCE_PC 1
-+
- #endif /* TC_RISCV */
-diff --git a/gas/config/tc-s390.c b/gas/config/tc-s390.c
-index 7c8087e..dccbe2c 100644
---- a/gas/config/tc-s390.c
-+++ b/gas/config/tc-s390.c
-@@ -291,7 +291,7 @@ s390_parse_cpu (const char * arg,
- { STRING_COMMA_LEN ("z13"), STRING_COMMA_LEN ("arch11"),
- S390_INSTR_FLAG_HTM | S390_INSTR_FLAG_VX },
- { STRING_COMMA_LEN ("arch12"), STRING_COMMA_LEN (""),
-- S390_INSTR_FLAG_HTM | S390_INSTR_FLAG_VX | S390_INSTR_FLAG_VX2 }
-+ S390_INSTR_FLAG_HTM | S390_INSTR_FLAG_VX }
- };
- static struct
- {
-@@ -303,9 +303,7 @@ s390_parse_cpu (const char * arg,
- { "htm", S390_INSTR_FLAG_HTM, TRUE },
- { "nohtm", S390_INSTR_FLAG_HTM, FALSE },
- { "vx", S390_INSTR_FLAG_VX, TRUE },
-- { "novx", S390_INSTR_FLAG_VX, FALSE },
-- { "vx2", S390_INSTR_FLAG_VX2, TRUE },
-- { "novx2", S390_INSTR_FLAG_VX2, FALSE }
-+ { "novx", S390_INSTR_FLAG_VX, FALSE }
- };
- unsigned int icpu;
- char *ilp_bak;
-diff --git a/gas/doc/c-riscv.texi b/gas/doc/c-riscv.texi
-index 0fa1b58..2efba4b 100644
---- a/gas/doc/c-riscv.texi
-+++ b/gas/doc/c-riscv.texi
-@@ -26,6 +26,14 @@ The following table lists all availiable RISC-V specific options
- @c man begin OPTIONS
- @table @gcctabopt
-
-+@cindex @samp{-fpic} option, RISC-V
-+@item -fpic
-+Generate position-independent code
-+
-+@cindex @samp{-fno-pic} option, RISC-V
-+@item -fno-pic
-+Don't generate position-independent code (default)
-+
- @cindex @samp{-march=ISA} option, RISC-V
- @item -march=ISA
- Select the base isa, as specified by ISA. For example -march=rv32ima.
-diff --git a/gas/testsuite/gas/ppc/altivec2.d b/gas/testsuite/gas/ppc/altivec2.d
-index fc10fb5..26f9afa 100644
---- a/gas/testsuite/gas/ppc/altivec2.d
-+++ b/gas/testsuite/gas/ppc/altivec2.d
-@@ -1,5 +1,5 @@
--#as: -maltivec
--#objdump: -dr -Maltivec
-+#as: -mpower8
-+#objdump: -dr -Mpower8
- #name: Altivec ISA 2.07 instructions
+ #ifndef FPU_DEFAULT
+ # ifdef TE_LINUX
+ # define FPU_DEFAULT FPU_ARCH_FPA
+@@ -28047,7 +28056,7 @@ md_apply_fix (fixS * fixP,
+ break;
+
+ case BFD_RELOC_THUMB_PCREL_BRANCH9: /* Conditional branch. */
+- if ((value & ~0xff) && ((value & ~0xff) != ~0xff))
++ if (out_of_range_p (value, 8))
+ as_bad_where (fixP->fx_file, fixP->fx_line, BAD_RANGE);
+
+ if (fixP->fx_done || !seg->use_rela_p)
+@@ -28059,7 +28068,7 @@ md_apply_fix (fixS * fixP,
+ break;
+
+ case BFD_RELOC_THUMB_PCREL_BRANCH12: /* Unconditional branch. */
+- if ((value & ~0x7ff) && ((value & ~0x7ff) != ~0x7ff))
++ if (out_of_range_p (value, 11))
+ as_bad_where (fixP->fx_file, fixP->fx_line, BAD_RANGE);
+
+ if (fixP->fx_done || !seg->use_rela_p)
+@@ -28070,6 +28079,7 @@ md_apply_fix (fixS * fixP,
+ }
+ break;
+
++ /* This relocation is misnamed, it should be BRANCH21. */
+ case BFD_RELOC_THUMB_PCREL_BRANCH20:
+ if (fixP->fx_addsy
+ && (S_GET_SEGMENT (fixP->fx_addsy) == seg)
+@@ -28080,7 +28090,7 @@ md_apply_fix (fixS * fixP,
+ /* Force a relocation for a branch 20 bits wide. */
+ fixP->fx_done = 0;
+ }
+- if ((value & ~0x1fffff) && ((value & ~0x0fffff) != ~0x0fffff))
++ if (out_of_range_p (value, 20))
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ _("conditional branch out of range"));
+
+@@ -28159,12 +28169,11 @@ md_apply_fix (fixS * fixP,
+ fixP->fx_r_type = BFD_RELOC_THUMB_PCREL_BRANCH23;
+ #endif
- .*
-diff --git a/gas/testsuite/gas/ppc/power9.d b/gas/testsuite/gas/ppc/power9.d
-index 9ba53d0..a67898f 100644
---- a/gas/testsuite/gas/ppc/power9.d
-+++ b/gas/testsuite/gas/ppc/power9.d
-@@ -312,8 +312,9 @@ Disassembly of section \.text:
- .*: (f1 31 9d 6f|6f 9d 31 f1) xscvdphp vs41,vs51
- .*: (f1 58 a7 6f|6f a7 58 f1) xvcvhpsp vs42,vs52
- .*: (f1 79 af 6f|6f af 79 f1) xvcvsphp vs43,vs53
--.*: (4c 60 00 04|04 00 60 4c) addpcis r3,0
--.*: (4c 60 00 04|04 00 60 4c) addpcis r3,0
-+.*: (4c 60 00 04|04 00 60 4c) lnia r3
-+.*: (4c 60 00 04|04 00 60 4c) lnia r3
-+.*: (4c 60 00 04|04 00 60 4c) lnia r3
- .*: (4c 80 00 05|05 00 80 4c) addpcis r4,1
- .*: (4c 80 00 05|05 00 80 4c) addpcis r4,1
- .*: (4c bf ff c4|c4 ff bf 4c) addpcis r5,-2
-diff --git a/gas/testsuite/gas/ppc/power9.s b/gas/testsuite/gas/ppc/power9.s
-index 27f1122..4e3530f 100644
---- a/gas/testsuite/gas/ppc/power9.s
-+++ b/gas/testsuite/gas/ppc/power9.s
-@@ -303,6 +303,7 @@ power9:
- xscvdphp 41,51
- xvcvhpsp 42,52
- xvcvsphp 43,53
-+ lnia 3
- addpcis 3,0
- subpcis 3,0
- addpcis 4,1
-diff --git a/gas/testsuite/gas/ppc/ppc.exp b/gas/testsuite/gas/ppc/ppc.exp
-index 86db455..55367ad 100644
---- a/gas/testsuite/gas/ppc/ppc.exp
-+++ b/gas/testsuite/gas/ppc/ppc.exp
-@@ -50,6 +50,7 @@ if { [istarget powerpc*-*-*] } then {
- run_dump_test "common"
- run_dump_test "476"
- run_dump_test "a2"
-+ run_dump_test "pr21303"
- if { ![istarget powerpc*le-*-*] } then {
- run_dump_test "vle"
- run_dump_test "vle-reloc"
-diff --git a/gas/testsuite/gas/ppc/pr21303.d b/gas/testsuite/gas/ppc/pr21303.d
+- if ((value & ~0x3fffff) && ((value & ~0x3fffff) != ~0x3fffff))
++ if (out_of_range_p (value, 22))
+ {
+ if (!(ARM_CPU_HAS_FEATURE (cpu_variant, arm_ext_v6t2)))
+ as_bad_where (fixP->fx_file, fixP->fx_line, BAD_RANGE);
+- else if ((value & ~0x1ffffff)
+- && ((value & ~0x1ffffff) != ~0x1ffffff))
++ else if (out_of_range_p (value, 24))
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ _("Thumb2 branch out of range"));
+ }
+@@ -28175,7 +28184,7 @@ md_apply_fix (fixS * fixP,
+ break;
+
+ case BFD_RELOC_THUMB_PCREL_BRANCH25:
+- if ((value & ~0x0ffffff) && ((value & ~0x0ffffff) != ~0x0ffffff))
++ if (out_of_range_p (value, 24))
+ as_bad_where (fixP->fx_file, fixP->fx_line, BAD_RANGE);
+
+ if (fixP->fx_done || !seg->use_rela_p)
+diff --git a/gas/testsuite/gas/arm/pr24991.d b/gas/testsuite/gas/arm/pr24991.d
new file mode 100644
-index 0000000..64761a4
+index 0000000000..2acca2d656
--- /dev/null
-+++ b/gas/testsuite/gas/ppc/pr21303.d
-@@ -0,0 +1,12 @@
-+#objdump: -d -Me200z4
-+#as: -a32 -mbig -me200z4
-+
-+.*
-+
-+Disassembly of section \.text:
++++ b/gas/testsuite/gas/arm/pr24991.d
+@@ -0,0 +1,4 @@
++#as: -march=armv7-a
++#source: pr24991.s
++#error_output: pr24991.l
+
-+0+ <\.text>:
-+ 0: 70 00 00 00 e_li r0,0
-+ 4: 7c 01 14 04 lbdcbx r0,r1,r2
-+ 8: 7c 01 14 44 lhdcbx r0,r1,r2
-+ c: 7c 01 14 84 lwdcbx r0,r1,r2
-diff --git a/gas/testsuite/gas/ppc/pr21303.s b/gas/testsuite/gas/ppc/pr21303.s
+diff --git a/gas/testsuite/gas/arm/pr24991.l b/gas/testsuite/gas/arm/pr24991.l
new file mode 100644
-index 0000000..890ba94
+index 0000000000..4fc58751c8
--- /dev/null
-+++ b/gas/testsuite/gas/ppc/pr21303.s
-@@ -0,0 +1,5 @@
-+ .text
-+ e_li 0, 0
-+ lbdcbx 0, 1, 2
-+ lhdcbx 0, 1, 2
-+ lwdcbx 0, 1, 2
-diff --git a/include/ChangeLog b/include/ChangeLog
-index af39f33..dddecfb 100644
---- a/include/ChangeLog
-+++ b/include/ChangeLog
-@@ -1,3 +1,58 @@
-+2017-04-03 Palmer Dabbelt <palmer@dabbelt.com>
-+
-+ * elf/riscv.h (RISCV_GP_SYMBOL): New define.
-+
-+2017-03-27 Andrew Waterman <andrew@sifive.com>
-+
-+ * opcode/riscv-opc.h (CSR_PMPCFG0): New define.
-+ (CSR_PMPCFG1): Likewise.
-+ (CSR_PMPCFG2): Likewise.
-+ (CSR_PMPCFG3): Likewise.
-+ (CSR_PMPADDR0): Likewise.
-+ (CSR_PMPADDR1): Likewise.
-+ (CSR_PMPADDR2): Likewise.
-+ (CSR_PMPADDR3): Likewise.
-+ (CSR_PMPADDR4): Likewise.
-+ (CSR_PMPADDR5): Likewise.
-+ (CSR_PMPADDR6): Likewise.
-+ (CSR_PMPADDR7): Likewise.
-+ (CSR_PMPADDR8): Likewise.
-+ (CSR_PMPADDR9): Likewise.
-+ (CSR_PMPADDR10): Likewise.
-+ (CSR_PMPADDR11): Likewise.
-+ (CSR_PMPADDR12): Likewise.
-+ (CSR_PMPADDR13): Likewise.
-+ (CSR_PMPADDR14): Likewise.
-+ (CSR_PMPADDR15): Likewise.
-+ (pmpcfg0): Declare register.
-+ (pmpcfg1): Likewise.
-+ (pmpcfg2): Likewise.
-+ (pmpcfg3): Likewise.
-+ (pmpaddr0): Likewise.
-+ (pmpaddr1): Likewise.
-+ (pmpaddr2): Likewise.
-+ (pmpaddr3): Likewise.
-+ (pmpaddr4): Likewise.
-+ (pmpaddr5): Likewise.
-+ (pmpaddr6): Likewise.
-+ (pmpaddr7): Likewise.
-+ (pmpaddr8): Likewise.
-+ (pmpaddr9): Likewise.
-+ (pmpaddr10): Likewise.
-+ (pmpaddr11): Likewise.
-+ (pmpaddr12): Likewise.
-+ (pmpaddr13): Likewise.
-+ (pmpaddr14): Likewise.
-+ (pmpaddr15): Likewise.
-+
-+2017-03-21 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
-+
-+ Backport from mainline
-+ 2017-03-21 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
-+
-+ * opcode/s390.h (S390_INSTR_FLAG_VX2): Remove.
-+ (S390_INSTR_FLAG_FACILITY_MASK): Adjust value.
-+
- 2017-02-28 Alan Modra <amodra@gmail.com>
-
- * elf/ppc64.h (R_PPC64_16DX_HA): New. Expand fake reloc comment.
-diff --git a/include/elf/riscv.h b/include/elf/riscv.h
-index 526bc11..daa4463 100644
---- a/include/elf/riscv.h
-+++ b/include/elf/riscv.h
-@@ -109,4 +109,7 @@ END_RELOC_NUMBERS (R_RISCV_max)
- /* File uses the quad-float ABI. */
- #define EF_RISCV_FLOAT_ABI_QUAD 0x0006
-
-+/* The name of the global pointer symbol. */
-+#define RISCV_GP_SYMBOL "__global_pointer$"
-+
- #endif /* _ELF_RISCV_H */
-diff --git a/include/opcode/riscv-opc.h b/include/opcode/riscv-opc.h
-index 9269c6b..f80037b 100644
---- a/include/opcode/riscv-opc.h
-+++ b/include/opcode/riscv-opc.h
-@@ -556,6 +556,26 @@
- #define CSR_MCAUSE 0x342
- #define CSR_MBADADDR 0x343
- #define CSR_MIP 0x344
-+#define CSR_PMPCFG0 0x3a0
-+#define CSR_PMPCFG1 0x3a1
-+#define CSR_PMPCFG2 0x3a2
-+#define CSR_PMPCFG3 0x3a3
-+#define CSR_PMPADDR0 0x3b0
-+#define CSR_PMPADDR1 0x3b1
-+#define CSR_PMPADDR2 0x3b2
-+#define CSR_PMPADDR3 0x3b3
-+#define CSR_PMPADDR4 0x3b4
-+#define CSR_PMPADDR5 0x3b5
-+#define CSR_PMPADDR6 0x3b6
-+#define CSR_PMPADDR7 0x3b7
-+#define CSR_PMPADDR8 0x3b8
-+#define CSR_PMPADDR9 0x3b9
-+#define CSR_PMPADDR10 0x3ba
-+#define CSR_PMPADDR11 0x3bb
-+#define CSR_PMPADDR12 0x3bc
-+#define CSR_PMPADDR13 0x3bd
-+#define CSR_PMPADDR14 0x3be
-+#define CSR_PMPADDR15 0x3bf
- #define CSR_TSELECT 0x7a0
- #define CSR_TDATA1 0x7a1
- #define CSR_TDATA2 0x7a2
-@@ -1014,6 +1034,26 @@ DECLARE_CSR(mepc, CSR_MEPC)
- DECLARE_CSR(mcause, CSR_MCAUSE)
- DECLARE_CSR(mbadaddr, CSR_MBADADDR)
- DECLARE_CSR(mip, CSR_MIP)
-+DECLARE_CSR(pmpcfg0, CSR_PMPCFG0)
-+DECLARE_CSR(pmpcfg1, CSR_PMPCFG1)
-+DECLARE_CSR(pmpcfg2, CSR_PMPCFG2)
-+DECLARE_CSR(pmpcfg3, CSR_PMPCFG3)
-+DECLARE_CSR(pmpaddr0, CSR_PMPADDR0)
-+DECLARE_CSR(pmpaddr1, CSR_PMPADDR1)
-+DECLARE_CSR(pmpaddr2, CSR_PMPADDR2)
-+DECLARE_CSR(pmpaddr3, CSR_PMPADDR3)
-+DECLARE_CSR(pmpaddr4, CSR_PMPADDR4)
-+DECLARE_CSR(pmpaddr5, CSR_PMPADDR5)
-+DECLARE_CSR(pmpaddr6, CSR_PMPADDR6)
-+DECLARE_CSR(pmpaddr7, CSR_PMPADDR7)
-+DECLARE_CSR(pmpaddr8, CSR_PMPADDR8)
-+DECLARE_CSR(pmpaddr9, CSR_PMPADDR9)
-+DECLARE_CSR(pmpaddr10, CSR_PMPADDR10)
-+DECLARE_CSR(pmpaddr11, CSR_PMPADDR11)
-+DECLARE_CSR(pmpaddr12, CSR_PMPADDR12)
-+DECLARE_CSR(pmpaddr13, CSR_PMPADDR13)
-+DECLARE_CSR(pmpaddr14, CSR_PMPADDR14)
-+DECLARE_CSR(pmpaddr15, CSR_PMPADDR15)
- DECLARE_CSR(tselect, CSR_TSELECT)
- DECLARE_CSR(tdata1, CSR_TDATA1)
- DECLARE_CSR(tdata2, CSR_TDATA2)
-diff --git a/include/opcode/s390.h b/include/opcode/s390.h
-index 7ce5616..2e07664 100644
---- a/include/opcode/s390.h
-+++ b/include/opcode/s390.h
-@@ -51,8 +51,7 @@ enum s390_opcode_cpu_val
-
- #define S390_INSTR_FLAG_HTM 0x2
- #define S390_INSTR_FLAG_VX 0x4
--#define S390_INSTR_FLAG_VX2 0x8
--#define S390_INSTR_FLAG_FACILITY_MASK 0xe
-+#define S390_INSTR_FLAG_FACILITY_MASK 0x6
-
- /* The opcode table is an array of struct s390_opcode. */
-
-diff --git a/ld/ChangeLog b/ld/ChangeLog
-index fd3e232..682ac6c 100644
---- a/ld/ChangeLog
-+++ b/ld/ChangeLog
-@@ -1,3 +1,30 @@
-+2017-04-24 H.J. Lu <hongjiu.lu@intel.com>
-+
-+ PR ld/20815
-+ * testsuite/ld-i386/vxworks2.sd: Add space for program headers.
-+
-+2017-03-28 Hans-Peter Nilsson <hp@axis.com>
-+
-+ PR ld/16044
-+ * testsuite/ld-cris/pr16044.d, testsuite/ld-cris/dso-1c.s,
-+ testsuite/ld-cris/dso-2b.s, testsuite/ld-cris/dso-4.s: New test.
-+
-+2017-04-10 H.J. Lu <hongjiu.lu@intel.com>
-+
-+ PR ld/19579
-+ PR ld/21306
-+ * testsuite/ld-elf/pr19579a.c (main): Updated.
-+
-+2017-04-05 Maciej W. Rozycki <macro@imgtec.com>
-+
-+ PR ld/21233
-+ * ldlang.c (insert_undefined): Set `mark' for ELF symbols.
-+
-+2017-03-07 Alan Modra <amodra@gmail.com>
-+
-+ * ldlang.c (open_input_bfds): Check that lang_assignment_statement
-+ is not an assert before referencing defsym.
-+
- 2017-03-02 Tristan Gingold <gingold@adacore.com>
-
- * configure: Regenerate.
-diff --git a/ld/ldlang.c b/ld/ldlang.c
-index dafc348..a8ff0a4 100644
---- a/ld/ldlang.c
-+++ b/ld/ldlang.c
-@@ -3377,7 +3377,8 @@ open_input_bfds (lang_statement_union_type *s, enum open_bfd_mode mode)
- #endif
- break;
- case lang_assignment_statement_enum:
-- if (s->assignment_statement.exp->assign.defsym)
-+ if (s->assignment_statement.exp->type.node_class != etree_assert
-+ && s->assignment_statement.exp->assign.defsym)
- /* This is from a --defsym on the command line. */
- exp_fold_tree_no_dot (s->assignment_statement.exp);
- break;
-@@ -3431,6 +3432,8 @@ insert_undefined (const char *name)
- {
- h->type = bfd_link_hash_undefined;
- h->u.undef.abfd = NULL;
-+ if (is_elf_hash_table (link_info.hash))
-+ ((struct elf_link_hash_entry *) h)->mark = 1;
- bfd_link_add_undef (link_info.hash, h);
- }
- }
-diff --git a/ld/testsuite/ld-cris/dso-1c.s b/ld/testsuite/ld-cris/dso-1c.s
-new file mode 100644
-index 0000000..92ad4ee
---- /dev/null
-+++ b/ld/testsuite/ld-cris/dso-1c.s
-@@ -0,0 +1,2 @@
-+ .include "dso-1.s"
-+ .hidden dsofn
-diff --git a/ld/testsuite/ld-cris/dso-2b.s b/ld/testsuite/ld-cris/dso-2b.s
-new file mode 100644
-index 0000000..f1fbf14
---- /dev/null
-+++ b/ld/testsuite/ld-cris/dso-2b.s
++++ b/gas/testsuite/gas/arm/pr24991.l
@@ -0,0 +1,2 @@
-+ .include "dso-2.s"
-+ .hidden dsofn
-diff --git a/ld/testsuite/ld-cris/dso-4.s b/ld/testsuite/ld-cris/dso-4.s
-new file mode 100644
-index 0000000..767a0d8
---- /dev/null
-+++ b/ld/testsuite/ld-cris/dso-4.s
-@@ -0,0 +1,6 @@
-+ .text
-+ .global export_2
-+ .type export_2,@function
-+export_2:
-+ .hidden dsofn
-+ move.d dsofn:GOTOFF,$r4
-diff --git a/ld/testsuite/ld-cris/pr16044.d b/ld/testsuite/ld-cris/pr16044.d
++[^:]*: Assembler messages:
++[^:]*:4: Error: conditional branch out of range
+diff --git a/gas/testsuite/gas/arm/pr24991.s b/gas/testsuite/gas/arm/pr24991.s
new file mode 100644
-index 0000000..e5d373d
+index 0000000000..27f8daff1c
--- /dev/null
-+++ b/ld/testsuite/ld-cris/pr16044.d
-@@ -0,0 +1,43 @@
-+#source: dso-4.s
-+#source: dso-2b.s
-+#source: dso-1c.s
-+#as: --pic --no-underscore --em=criself -I$srcdir/$subdir
-+#ld: --shared -m crislinux
-+#readelf: -s -r
-+
-+# PR 16044 is about a (compile-time-non-local) hidden function symbol,
-+# entered as an undef reference with a R_CRIS_32_PLT_GOTREL relocation
-+# referring to a hidden symbol, later defined. Here, we invalidly
-+# incremented the h->plt.refcount (from -1) as part of that relocation
-+# processing. There are some PLTGOT relocations. As there are no
-+# circumstances requiring a PLT entry for this symbol, its PLT entry
-+# can be eliminated and the PLTGOT relocations can be made to a static
-+# element in the GOT, relocated with the absolute-to-relative
-+# R_CRIS_RELATIVE relocation without symbol lookup. As part of
-+# eliminating unneeded PLT entries (and PLTGOT to "static" GOT
-+# elimination), a later pass noticed the inconsistency through an
-+# assert.
-+#
-+# The key points in this dump that may need future adjustments are the
-+# single dynamic relocation, that the dsofn symbol it points to, is
-+# local, its absence from the dynamic symbol table and that the
-+# relocation and symbol values match.
-+
-+Relocation section '\.rela\.dyn' at offset 0x[0-9a-f]+ contains 1 entries:
-+ Offset[ ]+Info[ ]+Type[ ]+Sym\.Value Sym\. Name \+ Addend
-+[0-9a-f]+ 0+[0-9a-f]+ R_CRIS_RELATIVE[ ]+184
-+
-+Symbol table '\.dynsym' contains 7 entries:
-+ +Num: +Value +Size +Type +Bind +Vis +Ndx +Name
-+ +0: 0+ +0 +NOTYPE +LOCAL +DEFAULT +UND
-+ +1: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +5
-+ +2: [0-9a-f]+ +0 +FUNC +GLOBAL +DEFAULT +5 export_1
-+ +3: [0-9a-f]+ +0 +NOTYPE +GLOBAL +DEFAULT +7 __bss_start
-+ +4: [0-9a-f]+ +0 +NOTYPE +GLOBAL +DEFAULT +7 _edata
-+ +5: [0-9a-f]+ +0 +NOTYPE +GLOBAL +DEFAULT +7 _end
-+ +6: [0-9a-f]+ +0 +FUNC +GLOBAL +DEFAULT +5 export_2
-+
-+Symbol table '\.symtab' contains [0-9]+ entries:
-+#...
-+ +[0-9]+: 0+184 +2 FUNC + LOCAL + DEFAULT + 5 dsofn
-+#...
-diff --git a/ld/testsuite/ld-elf/pr19579a.c b/ld/testsuite/ld-elf/pr19579a.c
-index e4a6eb1..69d0f35 100644
---- a/ld/testsuite/ld-elf/pr19579a.c
-+++ b/ld/testsuite/ld-elf/pr19579a.c
-@@ -9,7 +9,7 @@ extern int *bar_p (void);
- int
- main ()
- {
-- if (foo[0] == 0 && foo == foo_p () && bar[0] == 0 && bar == bar_p ())
-+ if (foo[0] == 0 && foo == foo_p () && bar[0] == -1 && bar == bar_p ())
- printf ("PASS\n");
- return 0;
- }
-diff --git a/ld/testsuite/ld-i386/vxworks2.sd b/ld/testsuite/ld-i386/vxworks2.sd
-index 5ff87d3..4f56f2a 100644
---- a/ld/testsuite/ld-i386/vxworks2.sd
-+++ b/ld/testsuite/ld-i386/vxworks2.sd
-@@ -6,7 +6,7 @@ Program Headers:
- Type .*
- PHDR .*
- #...
-- LOAD .* 0x00080000 0x00080000 .* R E 0x1000
-+ LOAD .* 0x0007f000 0x0007f000 .* R E 0x1000
- LOAD .* 0x00081000 0x00081000 .* RW 0x1000
- DYNAMIC .*
-
-diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog
-index 1ea126a..5dfe166 100644
---- a/opcodes/ChangeLog
-+++ b/opcodes/ChangeLog
-@@ -1,3 +1,67 @@
-+2017-05-01 Michael Clark <michaeljclark@mac.com>
-+
-+ * riscv-opc.c (riscv_opcodes) <call>: Use RA not T1 as a temporary
-+ register.
-+
-+2017-04-03 Palmer Dabbelt <palmer@dabbelt.com>
-+
-+ * riscv-dis.c (riscv_disassemble_insn): Change "_gp" to
-+ RISCV_GP_SYMBOL.
-+
-+2017-03-14 Kito Cheng <kito.cheng@gmail.com>
-+
-+ * riscv-opc.c (riscv_opcodes> <c.li>: Use the 'o' immediate encoding.
-+ <c.andi>: Likewise.
-+ <c.addiw> Likewise.
-+
-+2017-03-14 Kito Cheng <kito.cheng@gmail.com>
-+
-+ * riscv-opc.c (riscv_opcodes) <c.addi>: Use match_opcode.
-+
-+2017-03-13 Andrew Waterman <andrew@sifive.com>
-+
-+ * riscv-opc.c (riscv_opcodes) <srli/C>: Use match_opcode.
-+ <srl> Likewise.
-+ <srai> Likewise.
-+ <sra> Likewise.
-+
-+2017-03-27 Alan Modra <amodra@gmail.com>
-+
-+ PR 21303
-+ * ppc-dis.c (struct ppc_mopt): Comment.
-+ (ppc_opts <e200z4>): Move PPC_OPCODE_VLE from .sticky to .cpu.
-+
-+2017-03-21 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
-+
-+ Backport from mainline
-+ 2017-03-21 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
-+
-+ * s390-mkopc.c (main): Remove vx2 check.
-+ * s390-opc.txt: Remove vx2 instruction flags.
-+
-+2017-03-08 Peter Bergner <bergner@vnet.ibm.com>
-+
-+ * ppc-dis.c (ppc_opts) <altivec>: Do not use PPC_OPCODE_ALTIVEC2;
-+ <vsx>: Do not use PPC_OPCODE_VSX3;
-+
-+2017-03-08 Peter Bergner <bergner@vnet.ibm.com>
-+
-+ Apply from master.
-+ 2017-03-08 Peter Bergner <bergner@vnet.ibm.com>
-+ * ppc-opc.c (powerpc_opcodes) <lnia>: New extended mnemonic.
-+
-+2017-03-07 Alan Modra <amodra@gmail.com>
-+
-+ Apply from master
-+ 2017-03-06 Alan Modra <amodra@gmail.com>
-+ PR 21124
-+ * ppc-opc.c (extract_esync, extract_ls, extract_ral, extract_ram)
-+ (extract_raq, extract_ras, extract_rbx): New functions.
-+ (powerpc_operands): Use opposite corresponding insert function.
-+ (Q_MASK): Define.
-+ (powerpc_opcodes): Apply Q_MASK to all quad insns with even
-+ register restriction.
-+
- 2017-03-02 Tristan Gingold <gingold@adacore.com>
-
- * configure: Regenerate.
-diff --git a/opcodes/ppc-dis.c b/opcodes/ppc-dis.c
-index e0eff7a..baa7388 100644
---- a/opcodes/ppc-dis.c
-+++ b/opcodes/ppc-dis.c
-@@ -45,8 +45,19 @@ struct dis_private
- (((struct dis_private *) ((INFO)->private_data))->dialect)
-
- struct ppc_mopt {
-+ /* Option string, without -m or -M prefix. */
- const char *opt;
-+ /* CPU option flags. */
- ppc_cpu_t cpu;
-+ /* Flags that should stay on, even when combined with another cpu
-+ option. This should only be used for generic options like
-+ "-many" or "-maltivec" where it is reasonable to add some
-+ capability to another cpu selection. The added flags are sticky
-+ so that, for example, "-many -me500" and "-me500 -many" result in
-+ the same assembler or disassembler behaviour. Do not use
-+ "sticky" for specific cpus, as this will prevent that cpu's flags
-+ from overriding the defaults set in powerpc_init_dialect or a
-+ prior -m option. */
- ppc_cpu_t sticky;
- };
-
-@@ -93,7 +104,7 @@ struct ppc_mopt ppc_opts[] = {
- | PPC_OPCODE_A2),
- 0 },
- { "altivec", PPC_OPCODE_PPC,
-- PPC_OPCODE_ALTIVEC | PPC_OPCODE_ALTIVEC2 },
-+ PPC_OPCODE_ALTIVEC },
- { "any", 0,
- PPC_OPCODE_ANY },
- { "booke", PPC_OPCODE_PPC | PPC_OPCODE_BOOKE,
-@@ -108,8 +119,8 @@ struct ppc_mopt ppc_opts[] = {
- { "e200z4", (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE| PPC_OPCODE_SPE
- | PPC_OPCODE_ISEL | PPC_OPCODE_EFS | PPC_OPCODE_BRLOCK
- | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK | PPC_OPCODE_RFMCI
-- | PPC_OPCODE_E500 | PPC_OPCODE_E200Z4),
-- PPC_OPCODE_VLE },
-+ | PPC_OPCODE_E500 | PPC_OPCODE_VLE | PPC_OPCODE_E200Z4),
-+ 0 },
- { "e300", PPC_OPCODE_PPC | PPC_OPCODE_E300,
- 0 },
- { "e500", (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_SPE
-@@ -221,7 +232,7 @@ struct ppc_mopt ppc_opts[] = {
- | PPC_OPCODE_E500),
- PPC_OPCODE_VLE },
- { "vsx", PPC_OPCODE_PPC,
-- PPC_OPCODE_VSX | PPC_OPCODE_VSX3 },
-+ PPC_OPCODE_VSX },
- { "htm", PPC_OPCODE_PPC,
- PPC_OPCODE_HTM },
- };
-diff --git a/opcodes/ppc-opc.c b/opcodes/ppc-opc.c
-index 9ac779c..f7d1dcd 100644
---- a/opcodes/ppc-opc.c
-+++ b/opcodes/ppc-opc.c
-@@ -54,6 +54,7 @@ static long extract_bo (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_boe (unsigned long, long, ppc_cpu_t, const char **);
- static long extract_boe (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_esync (unsigned long, long, ppc_cpu_t, const char **);
-+static long extract_esync (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_dcmxs (unsigned long, long, ppc_cpu_t, const char **);
- static long extract_dcmxs (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_dxd (unsigned long, long, ppc_cpu_t, const char **);
-@@ -65,6 +66,7 @@ static long extract_fxm (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_li20 (unsigned long, long, ppc_cpu_t, const char **);
- static long extract_li20 (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_ls (unsigned long, long, ppc_cpu_t, const char **);
-+static long extract_ls (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_mbe (unsigned long, long, ppc_cpu_t, const char **);
- static long extract_mbe (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_mb6 (unsigned long, long, ppc_cpu_t, const char **);
-@@ -76,12 +78,17 @@ static long extract_nsi (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_oimm (unsigned long, long, ppc_cpu_t, const char **);
- static long extract_oimm (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_ral (unsigned long, long, ppc_cpu_t, const char **);
-+static long extract_ral (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_ram (unsigned long, long, ppc_cpu_t, const char **);
-+static long extract_ram (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_raq (unsigned long, long, ppc_cpu_t, const char **);
-+static long extract_raq (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_ras (unsigned long, long, ppc_cpu_t, const char **);
-+static long extract_ras (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_rbs (unsigned long, long, ppc_cpu_t, const char **);
- static long extract_rbs (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_rbx (unsigned long, long, ppc_cpu_t, const char **);
-+static long extract_rbx (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_rx (unsigned long, long, ppc_cpu_t, const char **);
- static long extract_rx (unsigned long, ppc_cpu_t, int *);
- static unsigned long insert_ry (unsigned long, long, ppc_cpu_t, const char **);
-@@ -462,7 +469,7 @@ const struct powerpc_operand powerpc_operands[] =
- /* The LS or WC field in an X (sync or wait) form instruction. */
- #define LS LIA + 1
- #define WC LS
-- { 0x3, 21, insert_ls, NULL, PPC_OPERAND_OPTIONAL },
-+ { 0x3, 21, insert_ls, extract_ls, PPC_OPERAND_OPTIONAL },
-
- /* The ME field in an M form instruction. */
- #define ME LS + 1
-@@ -519,24 +526,24 @@ const struct powerpc_operand powerpc_operands[] =
- value restrictions. */
- #define RAQ RA0 + 1
- #define RAX RAQ
-- { 0x1f, 16, insert_raq, NULL, PPC_OPERAND_GPR_0 },
-+ { 0x1f, 16, insert_raq, extract_raq, PPC_OPERAND_GPR_0 },
-
- /* The RA field in a D or X form instruction which is an updating
- load, which means that the RA field may not be zero and may not
- equal the RT field. */
- #define RAL RAQ + 1
-- { 0x1f, 16, insert_ral, NULL, PPC_OPERAND_GPR_0 },
-+ { 0x1f, 16, insert_ral, extract_ral, PPC_OPERAND_GPR_0 },
-
- /* The RA field in an lmw instruction, which has special value
- restrictions. */
- #define RAM RAL + 1
-- { 0x1f, 16, insert_ram, NULL, PPC_OPERAND_GPR_0 },
-+ { 0x1f, 16, insert_ram, extract_ram, PPC_OPERAND_GPR_0 },
-
- /* The RA field in a D or X form instruction which is an updating
- store or an updating floating point load, which means that the RA
- field may not be zero. */
- #define RAS RAM + 1
-- { 0x1f, 16, insert_ras, NULL, PPC_OPERAND_GPR_0 },
-+ { 0x1f, 16, insert_ras, extract_ras, PPC_OPERAND_GPR_0 },
-
- /* The RA field of the tlbwe, dccci and iccci instructions,
- which are optional. */
-@@ -557,7 +564,7 @@ const struct powerpc_operand powerpc_operands[] =
- /* The RB field in an lswx instruction, which has special value
- restrictions. */
- #define RBX RBS + 1
-- { 0x1f, 11, insert_rbx, NULL, PPC_OPERAND_GPR },
-+ { 0x1f, 11, insert_rbx, extract_rbx, PPC_OPERAND_GPR },
-
- /* The RB field of the dccci and iccci instructions, which are optional. */
- #define RBOPT RBX + 1
-@@ -580,6 +587,7 @@ const struct powerpc_operand powerpc_operands[] =
- which have special value restrictions. */
- #define RSQ RS + 1
- #define RTQ RSQ
-+#define Q_MASK (1 << 21)
- { 0x1e, 21, NULL, NULL, PPC_OPERAND_GPR },
-
- /* The RS field of the tlbwe instruction, which is optional. */
-@@ -694,7 +702,7 @@ const struct powerpc_operand powerpc_operands[] =
-
- /* The ESYNC field in an X (sync) form instruction. */
- #define ESYNC STRM + 1
-- { 0xf, 16, insert_esync, NULL, PPC_OPERAND_OPTIONAL },
-+ { 0xf, 16, insert_esync, extract_esync, PPC_OPERAND_OPTIONAL },
-
- /* The SV field in a POWER SC form instruction. */
- #define SV ESYNC + 1
-@@ -1533,6 +1541,22 @@ insert_ls (unsigned long insn,
- return insn | ((value & 0x3) << 21);
- }
-
-+static long
-+extract_ls (unsigned long insn,
-+ ppc_cpu_t dialect,
-+ int *invalid)
-+{
-+ unsigned long lvalue = (insn >> 21) & 3;
-+
-+ if (((insn >> 1) & 0x3ff) == 598)
-+ {
-+ unsigned long max_lvalue = (dialect & PPC_OPCODE_POWER4) ? 2 : 1;
-+ if (lvalue > max_lvalue)
-+ *invalid = 1;
-+ }
-+ return lvalue;
-+}
-+
- /* The 4-bit E field in a sync instruction that accepts 2 operands.
- If ESYNC is non-zero, then the L field must be either 0 or 1 and
- the complement of ESYNC-bit2. */
-@@ -1560,6 +1584,27 @@ insert_esync (unsigned long insn,
- return insn | ((value & 0xf) << 16);
- }
-
-+static long
-+extract_esync (unsigned long insn,
-+ ppc_cpu_t dialect,
-+ int *invalid)
-+{
-+ unsigned long ls = (insn >> 21) & 0x3;
-+ unsigned long lvalue = (insn >> 16) & 0xf;
-+
-+ if (lvalue == 0)
-+ {
-+ if (((dialect & PPC_OPCODE_E6500) != 0 && ls > 1)
-+ || ((dialect & PPC_OPCODE_POWER9) != 0 && ls > 2))
-+ *invalid = 1;
-+ }
-+ else if ((ls & ~0x1)
-+ || (((lvalue >> 1) & 0x1) ^ ls) == 0)
-+ *invalid = 1;
-+
-+ return lvalue;
-+}
-+
- /* The MB and ME fields in an M form instruction expressed as a single
- operand which is itself a bitmask. The extraction function always
- marks it as invalid, since we never want to recognize an
-@@ -1743,6 +1788,19 @@ insert_ral (unsigned long insn,
- return insn | ((value & 0x1f) << 16);
- }
-
-+static long
-+extract_ral (unsigned long insn,
-+ ppc_cpu_t dialect ATTRIBUTE_UNUSED,
-+ int *invalid)
-+{
-+ long rtvalue = (insn >> 21) & 0x1f;
-+ long ravalue = (insn >> 16) & 0x1f;
-+
-+ if (rtvalue == ravalue || ravalue == 0)
-+ *invalid = 1;
-+ return ravalue;
-+}
-+
- /* The RA field in an lmw instruction, which has special value
- restrictions. */
-
-@@ -1757,6 +1815,19 @@ insert_ram (unsigned long insn,
- return insn | ((value & 0x1f) << 16);
- }
-
-+static long
-+extract_ram (unsigned long insn,
-+ ppc_cpu_t dialect ATTRIBUTE_UNUSED,
-+ int *invalid)
-+{
-+ unsigned long rtvalue = (insn >> 21) & 0x1f;
-+ unsigned long ravalue = (insn >> 16) & 0x1f;
-+
-+ if (ravalue >= rtvalue)
-+ *invalid = 1;
-+ return ravalue;
-+}
-+
- /* The RA field in the DQ form lq or an lswx instruction, which have special
- value restrictions. */
-
-@@ -1773,6 +1844,19 @@ insert_raq (unsigned long insn,
- return insn | ((value & 0x1f) << 16);
- }
-
-+static long
-+extract_raq (unsigned long insn,
-+ ppc_cpu_t dialect ATTRIBUTE_UNUSED,
-+ int *invalid)
-+{
-+ unsigned long rtvalue = (insn >> 21) & 0x1f;
-+ unsigned long ravalue = (insn >> 16) & 0x1f;
-+
-+ if (ravalue == rtvalue)
-+ *invalid = 1;
-+ return ravalue;
-+}
-+
- /* The RA field in a D or X form instruction which is an updating
- store or an updating floating point load, which means that the RA
- field may not be zero. */
-@@ -1788,6 +1872,18 @@ insert_ras (unsigned long insn,
- return insn | ((value & 0x1f) << 16);
- }
-
-+static long
-+extract_ras (unsigned long insn,
-+ ppc_cpu_t dialect ATTRIBUTE_UNUSED,
-+ int *invalid)
-+{
-+ unsigned long ravalue = (insn >> 16) & 0x1f;
-+
-+ if (ravalue == 0)
-+ *invalid = 1;
-+ return ravalue;
-+}
-+
- /* The RB field in an X form instruction when it must be the same as
- the RS field in the instruction. This is used for extended
- mnemonics like mr. This operand is marked FAKE. The insertion
-@@ -1829,6 +1925,19 @@ insert_rbx (unsigned long insn,
- return insn | ((value & 0x1f) << 11);
- }
-
-+static long
-+extract_rbx (unsigned long insn,
-+ ppc_cpu_t dialect ATTRIBUTE_UNUSED,
-+ int *invalid)
-+{
-+ unsigned long rtvalue = (insn >> 21) & 0x1f;
-+ unsigned long rbvalue = (insn >> 11) & 0x1f;
-+
-+ if (rbvalue == rtvalue)
-+ *invalid = 1;
-+ return rbvalue;
-+}
++++ b/gas/testsuite/gas/arm/pr24991.s
+@@ -0,0 +1,5 @@
++ .arch armv7-a
++ .syntax unified
++ .thumb
++ beq .+ 0x124f80
+
- /* The SCI8 field is made up of SCL and {U,N}I8 fields. */
- static unsigned long
- insert_sci8 (unsigned long insn,
-@@ -2443,6 +2552,8 @@ extract_vleil (unsigned long insn,
- /* An DX form instruction. */
- #define DX(op, xop) (OP (op) | ((((unsigned long)(xop)) & 0x1f) << 1))
- #define DX_MASK DX (0x3f, 0x1f)
-+/* An DX form instruction with the D bits specified. */
-+#define NODX_MASK (DX_MASK | 0x1fffc1)
-
- /* An EVSEL form instruction. */
- #define EVSEL(op, xop) (OP (op) | (((unsigned long)(xop)) & 0xff) << 3)
-@@ -4155,6 +4266,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
-
- {"mcrf", XL(19,0), XLBB_MASK|(3<<21)|(3<<16), COM, PPCVLE, {BF, BFA}},
-
-+{"lnia", DX(19,2), NODX_MASK, POWER9, PPCVLE, {RT}},
- {"addpcis", DX(19,2), DX_MASK, POWER9, PPCVLE, {RT, DXD}},
- {"subpcis", DX(19,2), DX_MASK, POWER9, PPCVLE, {RT, NDXD}},
-
-@@ -4974,7 +5086,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
-
- {"stdux", X(31,181), X_MASK, PPC64, 0, {RS, RAS, RB}},
-
--{"stqcx.", XRC(31,182,1), X_MASK, POWER8, 0, {RSQ, RA0, RB}},
-+{"stqcx.", XRC(31,182,1), X_MASK|Q_MASK, POWER8, 0, {RSQ, RA0, RB}},
- {"wchkall", X(31,182), X_MASK, PPCA2, 0, {OBF}},
-
- {"stwux", X(31,183), X_MASK, PPCCOM, 0, {RS, RAS, RB}},
-@@ -5105,7 +5217,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
-
- {"mfapidi", X(31,275), X_MASK, BOOKE, E500|TITAN, {RT, RA}},
-
--{"lqarx", X(31,276), XEH_MASK, POWER8, 0, {RTQ, RAX, RBX, EH}},
-+{"lqarx", X(31,276), XEH_MASK|Q_MASK, POWER8, 0, {RTQ, RAX, RBX, EH}},
-
- {"lscbx", XRC(31,277,0), X_MASK, M601, 0, {RT, RA, RB}},
- {"lscbx.", XRC(31,277,1), X_MASK, M601, 0, {RT, RA, RB}},
-@@ -6052,7 +6164,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
-
- {"lhbrx", X(31,790), X_MASK, COM, 0, {RT, RA0, RB}},
-
--{"lfdpx", X(31,791), X_MASK, POWER6, POWER7, {FRTp, RA0, RB}},
-+{"lfdpx", X(31,791), X_MASK|Q_MASK, POWER6, POWER7, {FRTp, RA0, RB}},
- {"lfqx", X(31,791), X_MASK, POWER2, 0, {FRT, RA, RB}},
-
- {"sraw", XRC(31,792,0), X_MASK, PPCCOM, 0, {RA, RS, RB}},
-@@ -6167,7 +6279,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
-
- {"sthbrx", X(31,918), X_MASK, COM, 0, {RS, RA0, RB}},
-
--{"stfdpx", X(31,919), X_MASK, POWER6, POWER7, {FRSp, RA0, RB}},
-+{"stfdpx", X(31,919), X_MASK|Q_MASK, POWER6, POWER7, {FRSp, RA0, RB}},
- {"stfqx", X(31,919), X_MASK, POWER2, 0, {FRS, RA0, RB}},
-
- {"sraq", XRC(31,920,0), X_MASK, M601, 0, {RA, RS, RB}},
-@@ -6345,13 +6457,13 @@ const struct powerpc_opcode powerpc_opcodes[] = {
-
- {"stfdu", OP(55), OP_MASK, COM, PPCEFS|PPCVLE, {FRS, D, RAS}},
-
--{"lq", OP(56), OP_MASK, POWER4, PPC476|PPCVLE, {RTQ, DQ, RAQ}},
-+{"lq", OP(56), OP_MASK|Q_MASK, POWER4, PPC476|PPCVLE, {RTQ, DQ, RAQ}},
- {"psq_l", OP(56), OP_MASK, PPCPS, PPCVLE, {FRT,PSD,RA,PSW,PSQ}},
- {"lfq", OP(56), OP_MASK, POWER2, PPCVLE, {FRT, D, RA0}},
-
- {"lxsd", DSO(57,2), DS_MASK, PPCVSX3, PPCVLE, {VD, DS, RA0}},
- {"lxssp", DSO(57,3), DS_MASK, PPCVSX3, PPCVLE, {VD, DS, RA0}},
--{"lfdp", OP(57), OP_MASK, POWER6, POWER7|PPCVLE, {FRTp, DS, RA0}},
-+{"lfdp", OP(57), OP_MASK|Q_MASK, POWER6, POWER7|PPCVLE, {FRTp, DS, RA0}},
- {"psq_lu", OP(57), OP_MASK, PPCPS, PPCVLE, {FRT,PSD,RA,PSW,PSQ}},
- {"lfqu", OP(57), OP_MASK, POWER2, PPCVLE, {FRT, D, RA0}},
-
-@@ -6676,21 +6788,21 @@ const struct powerpc_opcode powerpc_opcodes[] = {
- {"stxv", DQX(61,5), DQX_MASK, PPCVSX3, PPCVLE, {XSQ6, DQ, RA0}},
- {"stxsd", DSO(61,2), DS_MASK, PPCVSX3, PPCVLE, {VS, DS, RA0}},
- {"stxssp", DSO(61,3), DS_MASK, PPCVSX3, PPCVLE, {VS, DS, RA0}},
--{"stfdp", OP(61), OP_MASK, POWER6, POWER7|PPCVLE, {FRSp, DS, RA0}},
-+{"stfdp", OP(61), OP_MASK|Q_MASK, POWER6, POWER7|PPCVLE, {FRSp, DS, RA0}},
- {"psq_stu", OP(61), OP_MASK, PPCPS, PPCVLE, {FRS,PSD,RA,PSW,PSQ}},
- {"stfqu", OP(61), OP_MASK, POWER2, PPCVLE, {FRS, D, RA}},
-
- {"std", DSO(62,0), DS_MASK, PPC64, PPCVLE, {RS, DS, RA0}},
- {"stdu", DSO(62,1), DS_MASK, PPC64, PPCVLE, {RS, DS, RAS}},
--{"stq", DSO(62,2), DS_MASK, POWER4, PPC476|PPCVLE, {RSQ, DS, RA0}},
-+{"stq", DSO(62,2), DS_MASK|Q_MASK, POWER4, PPC476|PPCVLE, {RSQ, DS, RA0}},
-
- {"fcmpu", X(63,0), XBF_MASK, COM, PPCEFS|PPCVLE, {BF, FRA, FRB}},
-
--{"daddq", XRC(63,2,0), X_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
--{"daddq.", XRC(63,2,1), X_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-+{"daddq", XRC(63,2,0), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-+{"daddq.", XRC(63,2,1), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-
--{"dquaq", ZRC(63,3,0), Z2_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp, RMC}},
--{"dquaq.", ZRC(63,3,1), Z2_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp, RMC}},
-+{"dquaq", ZRC(63,3,0), Z2_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp, RMC}},
-+{"dquaq.", ZRC(63,3,1), Z2_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp, RMC}},
-
- {"xsaddqp", XRC(63,4,0), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
- {"xsaddqpo", XRC(63,4,1), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
-@@ -6772,11 +6884,11 @@ const struct powerpc_opcode powerpc_opcodes[] = {
-
- {"fcmpo", X(63,32), XBF_MASK, COM, PPCEFS|PPCVLE, {BF, FRA, FRB}},
-
--{"dmulq", XRC(63,34,0), X_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
--{"dmulq.", XRC(63,34,1), X_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-+{"dmulq", XRC(63,34,0), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-+{"dmulq.", XRC(63,34,1), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-
--{"drrndq", ZRC(63,35,0), Z2_MASK, POWER6, PPCVLE, {FRTp, FRA, FRBp, RMC}},
--{"drrndq.", ZRC(63,35,1), Z2_MASK, POWER6, PPCVLE, {FRTp, FRA, FRBp, RMC}},
-+{"drrndq", ZRC(63,35,0), Z2_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRA, FRBp, RMC}},
-+{"drrndq.", ZRC(63,35,1), Z2_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRA, FRBp, RMC}},
-
- {"xsmulqp", XRC(63,36,0), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
- {"xsmulqpo", XRC(63,36,1), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
-@@ -6791,11 +6903,11 @@ const struct powerpc_opcode powerpc_opcodes[] = {
-
- {"mcrfs", X(63,64), XRB_MASK|(3<<21)|(3<<16), COM, PPCVLE, {BF, BFA}},
-
--{"dscliq", ZRC(63,66,0), Z_MASK, POWER6, PPCVLE, {FRTp, FRAp, SH16}},
--{"dscliq.", ZRC(63,66,1), Z_MASK, POWER6, PPCVLE, {FRTp, FRAp, SH16}},
-+{"dscliq", ZRC(63,66,0), Z_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, SH16}},
-+{"dscliq.", ZRC(63,66,1), Z_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, SH16}},
-
--{"dquaiq", ZRC(63,67,0), Z2_MASK, POWER6, PPCVLE, {TE, FRTp, FRBp, RMC}},
--{"dquaiq.", ZRC(63,67,1), Z2_MASK, POWER6, PPCVLE, {TE, FRTp, FRBp, RMC}},
-+{"dquaiq", ZRC(63,67,0), Z2_MASK|Q_MASK, POWER6, PPCVLE, {TE, FRTp, FRBp, RMC}},
-+{"dquaiq.", ZRC(63,67,1), Z2_MASK|Q_MASK, POWER6, PPCVLE, {TE, FRTp, FRBp, RMC}},
-
- {"mtfsb0", XRC(63,70,0), XRARB_MASK, COM, PPCVLE, {BT}},
- {"mtfsb0.", XRC(63,70,1), XRARB_MASK, COM, PPCVLE, {BT}},
-@@ -6803,11 +6915,11 @@ const struct powerpc_opcode powerpc_opcodes[] = {
- {"fmr", XRC(63,72,0), XRA_MASK, COM, PPCEFS|PPCVLE, {FRT, FRB}},
- {"fmr.", XRC(63,72,1), XRA_MASK, COM, PPCEFS|PPCVLE, {FRT, FRB}},
-
--{"dscriq", ZRC(63,98,0), Z_MASK, POWER6, PPCVLE, {FRTp, FRAp, SH16}},
--{"dscriq.", ZRC(63,98,1), Z_MASK, POWER6, PPCVLE, {FRTp, FRAp, SH16}},
-+{"dscriq", ZRC(63,98,0), Z_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, SH16}},
-+{"dscriq.", ZRC(63,98,1), Z_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, SH16}},
-
--{"drintxq", ZRC(63,99,0), Z2_MASK, POWER6, PPCVLE, {R, FRTp, FRBp, RMC}},
--{"drintxq.", ZRC(63,99,1), Z2_MASK, POWER6, PPCVLE, {R, FRTp, FRBp, RMC}},
-+{"drintxq", ZRC(63,99,0), Z2_MASK|Q_MASK, POWER6, PPCVLE, {R, FRTp, FRBp, RMC}},
-+{"drintxq.", ZRC(63,99,1), Z2_MASK|Q_MASK, POWER6, PPCVLE, {R, FRTp, FRBp, RMC}},
-
- {"xscpsgnqp", X(63,100), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
-
-@@ -6839,11 +6951,11 @@ const struct powerpc_opcode powerpc_opcodes[] = {
- {"dtstdcq", Z(63,194), Z_MASK, POWER6, PPCVLE, {BF, FRAp, DCM}},
- {"dtstdgq", Z(63,226), Z_MASK, POWER6, PPCVLE, {BF, FRAp, DGM}},
-
--{"drintnq", ZRC(63,227,0), Z2_MASK, POWER6, PPCVLE, {R, FRTp, FRBp, RMC}},
--{"drintnq.", ZRC(63,227,1), Z2_MASK, POWER6, PPCVLE, {R, FRTp, FRBp, RMC}},
-+{"drintnq", ZRC(63,227,0), Z2_MASK|Q_MASK, POWER6, PPCVLE, {R, FRTp, FRBp, RMC}},
-+{"drintnq.", ZRC(63,227,1), Z2_MASK|Q_MASK, POWER6, PPCVLE, {R, FRTp, FRBp, RMC}},
-
--{"dctqpq", XRC(63,258,0), X_MASK, POWER6, PPCVLE, {FRTp, FRB}},
--{"dctqpq.", XRC(63,258,1), X_MASK, POWER6, PPCVLE, {FRTp, FRB}},
-+{"dctqpq", XRC(63,258,0), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRB}},
-+{"dctqpq.", XRC(63,258,1), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRB}},
-
- {"fabs", XRC(63,264,0), XRA_MASK, COM, PPCEFS|PPCVLE, {FRT, FRB}},
- {"fabs.", XRC(63,264,1), XRA_MASK, COM, PPCEFS|PPCVLE, {FRT, FRB}},
-@@ -6851,8 +6963,8 @@ const struct powerpc_opcode powerpc_opcodes[] = {
- {"dctfixq", XRC(63,290,0), X_MASK, POWER6, PPCVLE, {FRT, FRBp}},
- {"dctfixq.", XRC(63,290,1), X_MASK, POWER6, PPCVLE, {FRT, FRBp}},
-
--{"ddedpdq", XRC(63,322,0), X_MASK, POWER6, PPCVLE, {SP, FRTp, FRBp}},
--{"ddedpdq.", XRC(63,322,1), X_MASK, POWER6, PPCVLE, {SP, FRTp, FRBp}},
-+{"ddedpdq", XRC(63,322,0), X_MASK|Q_MASK, POWER6, PPCVLE, {SP, FRTp, FRBp}},
-+{"ddedpdq.", XRC(63,322,1), X_MASK|Q_MASK, POWER6, PPCVLE, {SP, FRTp, FRBp}},
-
- {"dxexq", XRC(63,354,0), X_MASK, POWER6, PPCVLE, {FRT, FRBp}},
- {"dxexq.", XRC(63,354,1), X_MASK, POWER6, PPCVLE, {FRT, FRBp}},
-@@ -6881,14 +6993,14 @@ const struct powerpc_opcode powerpc_opcodes[] = {
- {"frim", XRC(63,488,0), XRA_MASK, POWER5, PPCVLE, {FRT, FRB}},
- {"frim.", XRC(63,488,1), XRA_MASK, POWER5, PPCVLE, {FRT, FRB}},
-
--{"dsubq", XRC(63,514,0), X_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
--{"dsubq.", XRC(63,514,1), X_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-+{"dsubq", XRC(63,514,0), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-+{"dsubq.", XRC(63,514,1), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-
- {"xssubqp", XRC(63,516,0), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
- {"xssubqpo", XRC(63,516,1), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
-
--{"ddivq", XRC(63,546,0), X_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
--{"ddivq.", XRC(63,546,1), X_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-+{"ddivq", XRC(63,546,0), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-+{"ddivq.", XRC(63,546,1), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRAp, FRBp}},
-
- {"xsdivqp", XRC(63,548,0), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
- {"xsdivqpo", XRC(63,548,1), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
-@@ -6917,11 +7029,11 @@ const struct powerpc_opcode powerpc_opcodes[] = {
- {"mtfsf.", XFL(63,711,1), XFL_MASK, POWER6|PPCA2|PPC476, PPCVLE, {FLM, FRB, XFL_L, W}},
- {"mtfsf.", XFL(63,711,1), XFL_MASK, COM, POWER6|PPCA2|PPC476|PPCEFS|PPCVLE, {FLM, FRB}},
-
--{"drdpq", XRC(63,770,0), X_MASK, POWER6, PPCVLE, {FRTp, FRBp}},
--{"drdpq.", XRC(63,770,1), X_MASK, POWER6, PPCVLE, {FRTp, FRBp}},
-+{"drdpq", XRC(63,770,0), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRBp}},
-+{"drdpq.", XRC(63,770,1), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRBp}},
-
--{"dcffixq", XRC(63,802,0), X_MASK, POWER6, PPCVLE, {FRTp, FRB}},
--{"dcffixq.", XRC(63,802,1), X_MASK, POWER6, PPCVLE, {FRTp, FRB}},
-+{"dcffixq", XRC(63,802,0), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRB}},
-+{"dcffixq.", XRC(63,802,1), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRB}},
-
- {"xsabsqp", XVA(63,804,0), XVA_MASK, PPCVSX3, PPCVLE, {VD, VB}},
- {"xsxexpqp", XVA(63,804,2), XVA_MASK, PPCVSX3, PPCVLE, {VD, VB}},
-@@ -6941,8 +7053,8 @@ const struct powerpc_opcode powerpc_opcodes[] = {
- {"fctidz.", XRC(63,815,1), XRA_MASK, PPC64, PPCVLE, {FRT, FRB}},
- {"fctidz.", XRC(63,815,1), XRA_MASK, PPC476, PPCVLE, {FRT, FRB}},
-
--{"denbcdq", XRC(63,834,0), X_MASK, POWER6, PPCVLE, {S, FRTp, FRBp}},
--{"denbcdq.", XRC(63,834,1), X_MASK, POWER6, PPCVLE, {S, FRTp, FRBp}},
-+{"denbcdq", XRC(63,834,0), X_MASK|Q_MASK, POWER6, PPCVLE, {S, FRTp, FRBp}},
-+{"denbcdq.", XRC(63,834,1), X_MASK|Q_MASK, POWER6, PPCVLE, {S, FRTp, FRBp}},
-
- {"xscvqpuwz", XVA(63,836,1), XVA_MASK, PPCVSX3, PPCVLE, {VD, VB}},
- {"xscvudqp", XVA(63,836,2), XVA_MASK, PPCVSX3, PPCVLE, {VD, VB}},
-@@ -6961,8 +7073,8 @@ const struct powerpc_opcode powerpc_opcodes[] = {
- {"fcfid.", XRC(63,846,1), XRA_MASK, PPC64, PPCVLE, {FRT, FRB}},
- {"fcfid.", XRC(63,846,1), XRA_MASK, PPC476, PPCVLE, {FRT, FRB}},
-
--{"diexq", XRC(63,866,0), X_MASK, POWER6, PPCVLE, {FRTp, FRA, FRBp}},
--{"diexq.", XRC(63,866,1), X_MASK, POWER6, PPCVLE, {FRTp, FRA, FRBp}},
-+{"diexq", XRC(63,866,0), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRA, FRBp}},
-+{"diexq.", XRC(63,866,1), X_MASK|Q_MASK, POWER6, PPCVLE, {FRTp, FRA, FRBp}},
-
- {"xsiexpqp", X(63,868), X_MASK, PPCVSX3, PPCVLE, {VD, VA, VB}},
-
-diff --git a/opcodes/riscv-dis.c b/opcodes/riscv-dis.c
-index 070c96e..bdc961c 100644
---- a/opcodes/riscv-dis.c
-+++ b/opcodes/riscv-dis.c
-@@ -383,7 +383,7 @@ riscv_disassemble_insn (bfd_vma memaddr, insn_t word, disassemble_info *info)
- pd->hi_addr[i] = -1;
-
- for (i = 0; i < info->symtab_size; i++)
-- if (strcmp (bfd_asymbol_name (info->symtab[i]), "_gp") == 0)
-+ if (strcmp (bfd_asymbol_name (info->symtab[i]), RISCV_GP_SYMBOL) == 0)
- pd->gp = bfd_asymbol_value (info->symtab[i]);
- }
- else
-diff --git a/opcodes/riscv-opc.c b/opcodes/riscv-opc.c
-index 867a026..8343198 100644
---- a/opcodes/riscv-opc.c
-+++ b/opcodes/riscv-opc.c
-@@ -147,7 +147,7 @@ const struct riscv_opcode riscv_opcodes[] =
- {"jal", "32C", "Ca", MATCH_C_JAL, MASK_C_JAL, match_opcode, INSN_ALIAS },
- {"jal", "I", "a", MATCH_JAL | (X_RA << OP_SH_RD), MASK_JAL | MASK_RD, match_opcode, INSN_ALIAS },
- {"call", "I", "d,c", (X_T1 << OP_SH_RS1), (int) M_CALL, match_never, INSN_MACRO },
--{"call", "I", "c", (X_T1 << OP_SH_RS1) | (X_RA << OP_SH_RD), (int) M_CALL, match_never, INSN_MACRO },
-+{"call", "I", "c", (X_RA << OP_SH_RS1) | (X_RA << OP_SH_RD), (int) M_CALL, match_never, INSN_MACRO },
- {"tail", "I", "c", (X_T1 << OP_SH_RS1), (int) M_CALL, match_never, INSN_MACRO },
- {"jump", "I", "c,s", 0, (int) M_CALL, match_never, INSN_MACRO },
- {"nop", "C", "", MATCH_C_ADDI, 0xffff, match_opcode, INSN_ALIAS },
-@@ -210,14 +210,14 @@ const struct riscv_opcode riscv_opcodes[] =
- {"sll", "C", "d,CU,C>", MATCH_C_SLLI, MASK_C_SLLI, match_rd_nonzero, INSN_ALIAS },
- {"sll", "I", "d,s,t", MATCH_SLL, MASK_SLL, match_opcode, 0 },
- {"sll", "I", "d,s,>", MATCH_SLLI, MASK_SLLI, match_opcode, INSN_ALIAS },
--{"srli", "C", "Cs,Cw,C>", MATCH_C_SRLI, MASK_C_SRLI, match_rd_nonzero, INSN_ALIAS },
-+{"srli", "C", "Cs,Cw,C>", MATCH_C_SRLI, MASK_C_SRLI, match_opcode, INSN_ALIAS },
- {"srli", "I", "d,s,>", MATCH_SRLI, MASK_SRLI, match_opcode, 0 },
--{"srl", "C", "Cs,Cw,C>", MATCH_C_SRLI, MASK_C_SRLI, match_rd_nonzero, INSN_ALIAS },
-+{"srl", "C", "Cs,Cw,C>", MATCH_C_SRLI, MASK_C_SRLI, match_opcode, INSN_ALIAS },
- {"srl", "I", "d,s,t", MATCH_SRL, MASK_SRL, match_opcode, 0 },
- {"srl", "I", "d,s,>", MATCH_SRLI, MASK_SRLI, match_opcode, INSN_ALIAS },
--{"srai", "C", "Cs,Cw,C>", MATCH_C_SRAI, MASK_C_SRAI, match_rd_nonzero, INSN_ALIAS },
-+{"srai", "C", "Cs,Cw,C>", MATCH_C_SRAI, MASK_C_SRAI, match_opcode, INSN_ALIAS },
- {"srai", "I", "d,s,>", MATCH_SRAI, MASK_SRAI, match_opcode, 0 },
--{"sra", "C", "Cs,Cw,C>", MATCH_C_SRAI, MASK_C_SRAI, match_rd_nonzero, INSN_ALIAS },
-+{"sra", "C", "Cs,Cw,C>", MATCH_C_SRAI, MASK_C_SRAI, match_opcode, INSN_ALIAS },
- {"sra", "I", "d,s,t", MATCH_SRA, MASK_SRA, match_opcode, 0 },
- {"sra", "I", "d,s,>", MATCH_SRAI, MASK_SRAI, match_opcode, INSN_ALIAS },
- {"sub", "C", "Cs,Cw,Ct", MATCH_C_SUB, MASK_C_SUB, match_opcode, INSN_ALIAS },
-@@ -562,10 +562,10 @@ const struct riscv_opcode riscv_opcodes[] =
- {"c.nop", "C", "", MATCH_C_ADDI, 0xffff, match_opcode, 0 },
- {"c.mv", "C", "d,CV", MATCH_C_MV, MASK_C_MV, match_c_add, 0 },
- {"c.lui", "C", "d,Cu", MATCH_C_LUI, MASK_C_LUI, match_c_lui, 0 },
--{"c.li", "C", "d,Cj", MATCH_C_LI, MASK_C_LI, match_rd_nonzero, 0 },
-+{"c.li", "C", "d,Co", MATCH_C_LI, MASK_C_LI, match_rd_nonzero, 0 },
- {"c.addi4spn","C", "Ct,Cc,CK", MATCH_C_ADDI4SPN, MASK_C_ADDI4SPN, match_opcode, 0 },
- {"c.addi16sp","C", "Cc,CL", MATCH_C_ADDI16SP, MASK_C_ADDI16SP, match_opcode, 0 },
--{"c.addi", "C", "d,Cj", MATCH_C_ADDI, MASK_C_ADDI, match_rd_nonzero, 0 },
-+{"c.addi", "C", "d,Cj", MATCH_C_ADDI, MASK_C_ADDI, match_opcode, 0 },
- {"c.add", "C", "d,CV", MATCH_C_ADD, MASK_C_ADD, match_c_add, 0 },
- {"c.sub", "C", "Cs,Ct", MATCH_C_SUB, MASK_C_SUB, match_opcode, 0 },
- {"c.and", "C", "Cs,Ct", MATCH_C_AND, MASK_C_AND, match_opcode, 0 },
-@@ -574,8 +574,8 @@ const struct riscv_opcode riscv_opcodes[] =
- {"c.slli", "C", "d,C>", MATCH_C_SLLI, MASK_C_SLLI, match_rd_nonzero, 0 },
- {"c.srli", "C", "Cs,C>", MATCH_C_SRLI, MASK_C_SRLI, match_opcode, 0 },
- {"c.srai", "C", "Cs,C>", MATCH_C_SRAI, MASK_C_SRAI, match_opcode, 0 },
--{"c.andi", "C", "Cs,Cj", MATCH_C_ANDI, MASK_C_ANDI, match_opcode, 0 },
--{"c.addiw", "64C", "d,Cj", MATCH_C_ADDIW, MASK_C_ADDIW, match_rd_nonzero, 0 },
-+{"c.andi", "C", "Cs,Co", MATCH_C_ANDI, MASK_C_ANDI, match_opcode, 0 },
-+{"c.addiw", "64C", "d,Co", MATCH_C_ADDIW, MASK_C_ADDIW, match_rd_nonzero, 0 },
- {"c.addw", "64C", "Cs,Ct", MATCH_C_ADDW, MASK_C_ADDW, match_opcode, 0 },
- {"c.subw", "64C", "Cs,Ct", MATCH_C_SUBW, MASK_C_SUBW, match_opcode, 0 },
- {"c.ldsp", "64C", "d,Cn(Cc)", MATCH_C_LDSP, MASK_C_LDSP, match_rd_nonzero, 0 },
-diff --git a/opcodes/s390-mkopc.c b/opcodes/s390-mkopc.c
-index 8e0b332..68c55a9 100644
---- a/opcodes/s390-mkopc.c
-+++ b/opcodes/s390-mkopc.c
-@@ -419,10 +419,6 @@ main (void)
- && (str[2] == 0 || str[2] == ',')) {
- flag_bits |= S390_INSTR_FLAG_VX;
- str += 2;
-- } else if (strncmp (str, "vx2", 3) == 0
-- && (str[3] == 0 || str[3] == ',')) {
-- flag_bits |= S390_INSTR_FLAG_VX2;
-- str += 3;
- } else {
- fprintf (stderr, "Couldn't parse flags string %s\n",
- flags_string);
-diff --git a/opcodes/s390-opc.txt b/opcodes/s390-opc.txt
-index b381587..51a17f3 100644
---- a/opcodes/s390-opc.txt
-+++ b/opcodes/s390-opc.txt
-@@ -1685,146 +1685,146 @@ b93c ppno RRE_RR "perform pseudorandom number operation" z13 zarch
- # Vector Enhancements Facility 1
-
- e70000000085 vbperm VRR_VVV "vector bit permute" arch12 zarch
--e70000006004 vllezlf VRX_VRRD "vector load logical word element and zero - left aligned" arch12 zarch vx2
--e700000000b8 vmsl VRR_VVVUU0V "vector multiply sum logical" arch12 zarch vx2
--e700030000b8 vmslg VRR_VVVU0VB "vector multiply sum logical double word" arch12 zarch vx2
--e7000000006c vnx VRR_VVV "vector not exclusive or" arch12 zarch vx2
-+e70000006004 vllezlf VRX_VRRD "vector load logical word element and zero - left aligned" arch12 zarch
-+e700000000b8 vmsl VRR_VVVUU0V "vector multiply sum logical" arch12 zarch
-+e700030000b8 vmslg VRR_VVVU0VB "vector multiply sum logical double word" arch12 zarch
-+e7000000006c vnx VRR_VVV "vector not exclusive or" arch12 zarch
- e7000000006e vnn VRR_VVV "vector nand" arch12 zarch
--e7000000006f voc VRR_VVV "vector or with complement" arch12 zarch vx2
--e70000000050 vpopctb VRR_VV "vector population count byte" arch12 zarch vx2
--e70000001050 vpopcth VRR_VV "vector population count halfword" arch12 zarch vx2
--e70000002050 vpopctf VRR_VV "vector population count word" arch12 zarch vx2
--e70000003050 vpopctg VRR_VV "vector population count double word" arch12 zarch vx2
--e700000020e3 vfasb VRR_VVV "vector fp add short" arch12 zarch vx2
--e700000820e3 wfasb VRR_VVV "scalar vector fp add scalar short" arch12 zarch vx2
--e700000840e3 wfaxb VRR_VVV "scalar vector fp add scalar extended" arch12 zarch vx2
--e700000020cb wfcsb VRR_VV "scalar vector fp compare scalar short" arch12 zarch vx2
--e700000040cb wfcxb VRR_VV "scalar vector fp compare scalar extended" arch12 zarch vx2
--e700000020ca wfksb VRR_VV "scalar vector fp compare and signal scalar short" arch12 zarch vx2
--e700000040ca wfkxb VRR_VV "scalar vector fp compare and signal scalar extended" arch12 zarch vx2
-+e7000000006f voc VRR_VVV "vector or with complement" arch12 zarch
-+e70000000050 vpopctb VRR_VV "vector population count byte" arch12 zarch
-+e70000001050 vpopcth VRR_VV "vector population count halfword" arch12 zarch
-+e70000002050 vpopctf VRR_VV "vector population count word" arch12 zarch
-+e70000003050 vpopctg VRR_VV "vector population count double word" arch12 zarch
-+e700000020e3 vfasb VRR_VVV "vector fp add short" arch12 zarch
-+e700000820e3 wfasb VRR_VVV "scalar vector fp add scalar short" arch12 zarch
-+e700000840e3 wfaxb VRR_VVV "scalar vector fp add scalar extended" arch12 zarch
-+e700000020cb wfcsb VRR_VV "scalar vector fp compare scalar short" arch12 zarch
-+e700000040cb wfcxb VRR_VV "scalar vector fp compare scalar extended" arch12 zarch
-+e700000020ca wfksb VRR_VV "scalar vector fp compare and signal scalar short" arch12 zarch
-+e700000040ca wfkxb VRR_VV "scalar vector fp compare and signal scalar extended" arch12 zarch
-
--e700000020e8 vfcesb VRR_VVV "vector fp compare equal short" arch12 zarch vx2
--e700001020e8 vfcesbs VRR_VVV "vector fp compare equal short" arch12 zarch vx2
--e700000820e8 wfcesb VRR_VVV "scalar vector fp compare equal scalar short" arch12 zarch vx2
--e700001820e8 wfcesbs VRR_VVV "scalar fp compare equal scalar short" arch12 zarch vx2
--e700000840e8 wfcexb VRR_VVV "scalar vector fp compare equal scalar extended" arch12 zarch vx2
--e700001840e8 wfcexbs VRR_VVV "scalar vector fp compare equal scalar extended" arch12 zarch vx2
-+e700000020e8 vfcesb VRR_VVV "vector fp compare equal short" arch12 zarch
-+e700001020e8 vfcesbs VRR_VVV "vector fp compare equal short" arch12 zarch
-+e700000820e8 wfcesb VRR_VVV "scalar vector fp compare equal scalar short" arch12 zarch
-+e700001820e8 wfcesbs VRR_VVV "scalar fp compare equal scalar short" arch12 zarch
-+e700000840e8 wfcexb VRR_VVV "scalar vector fp compare equal scalar extended" arch12 zarch
-+e700001840e8 wfcexbs VRR_VVV "scalar vector fp compare equal scalar extended" arch12 zarch
-
--e700000420e8 vfkesb VRR_VVV "vector fp compare and signal equal short" arch12 zarch vx2
--e700001420e8 vfkesbs VRR_VVV "vector fp compare and signal equal short" arch12 zarch vx2
--e700000c20e8 wfkesb VRR_VVV "scalar vector fp compare and signal equal scalar short" arch12 zarch vx2
--e700001c20e8 wfkesbs VRR_VVV "scalar fp compare and signal equal scalar short" arch12 zarch vx2
-+e700000420e8 vfkesb VRR_VVV "vector fp compare and signal equal short" arch12 zarch
-+e700001420e8 vfkesbs VRR_VVV "vector fp compare and signal equal short" arch12 zarch
-+e700000c20e8 wfkesb VRR_VVV "scalar vector fp compare and signal equal scalar short" arch12 zarch
-+e700001c20e8 wfkesbs VRR_VVV "scalar fp compare and signal equal scalar short" arch12 zarch
- e700000430e8 vfkedb VRR_VVV "vector fp compare and signal equal long" arch12 zarch vx
- e700001430e8 vfkedbs VRR_VVV "vector fp compare and signal equal long" arch12 zarch vx
- e700000c30e8 wfkedb VRR_VVV "vector fp compare and signal equal long" arch12 zarch vx
- e700001c30e8 wfkedbs VRR_VVV "vector fp compare and signal equal long" arch12 zarch vx
--e700000c40e8 wfkexb VRR_VVV "scalar vector fp compare and signal equal scalar extended" arch12 zarch vx2
--e700001c40e8 wfkexbs VRR_VVV "scalar vector fp compare and signal equal scalar extended" arch12 zarch vx2
-+e700000c40e8 wfkexb VRR_VVV "scalar vector fp compare and signal equal scalar extended" arch12 zarch
-+e700001c40e8 wfkexbs VRR_VVV "scalar vector fp compare and signal equal scalar extended" arch12 zarch
-
--e700000020eb vfchsb VRR_VVV "vector fp compare high short" arch12 zarch vx2
--e700001020eb vfchsbs VRR_VVV "vector fp compare high short" arch12 zarch vx2
--e700000820eb wfchsb VRR_VVV "scalar vector fp compare high scalar short" arch12 zarch vx2
--e700001820eb wfchsbs VRR_VVV "scalar vector fp compare high scalar short" arch12 zarch vx2
--e700000840eb wfchxb VRR_VVV "scalar vector fp compare high scalar extended" arch12 zarch vx2
--e700001840eb wfchxbs VRR_VVV "scalar vector fp compare high scalar extended" arch12 zarch vx2
-+e700000020eb vfchsb VRR_VVV "vector fp compare high short" arch12 zarch
-+e700001020eb vfchsbs VRR_VVV "vector fp compare high short" arch12 zarch
-+e700000820eb wfchsb VRR_VVV "scalar vector fp compare high scalar short" arch12 zarch
-+e700001820eb wfchsbs VRR_VVV "scalar vector fp compare high scalar short" arch12 zarch
-+e700000840eb wfchxb VRR_VVV "scalar vector fp compare high scalar extended" arch12 zarch
-+e700001840eb wfchxbs VRR_VVV "scalar vector fp compare high scalar extended" arch12 zarch
-
--e700000420eb vfkhsb VRR_VVV "vector fp compare and signal high short" arch12 zarch vx2
--e700001420eb vfkhsbs VRR_VVV "vector fp compare and signal high short" arch12 zarch vx2
--e700000c20eb wfkhsb VRR_VVV "scalar vector fp compare and signal high scalar short" arch12 zarch vx2
--e700001c20eb wfkhsbs VRR_VVV "scalar vector fp compare and signal high scalar short" arch12 zarch vx2
-+e700000420eb vfkhsb VRR_VVV "vector fp compare and signal high short" arch12 zarch
-+e700001420eb vfkhsbs VRR_VVV "vector fp compare and signal high short" arch12 zarch
-+e700000c20eb wfkhsb VRR_VVV "scalar vector fp compare and signal high scalar short" arch12 zarch
-+e700001c20eb wfkhsbs VRR_VVV "scalar vector fp compare and signal high scalar short" arch12 zarch
- e700000430eb vfkhdb VRR_VVV "vector fp compare and signal high long" arch12 zarch vx
- e700001430eb vfkhdbs VRR_VVV "vector fp compare and signal high long" arch12 zarch vx
- e700000c30eb wfkhdb VRR_VVV "vector fp compare and signal high long" arch12 zarch vx
- e700001c30eb wfkhdbs VRR_VVV "vector fp compare and signal high long" arch12 zarch vx
--e700000c40eb wfkhxb VRR_VVV "scalar vector fp compare and signal high scalar extended" arch12 zarch vx2
--e700001c40eb wfkhxbs VRR_VVV "scalar vector fp compare and signal high scalar extended" arch12 zarch vx2
-+e700000c40eb wfkhxb VRR_VVV "scalar vector fp compare and signal high scalar extended" arch12 zarch
-+e700001c40eb wfkhxbs VRR_VVV "scalar vector fp compare and signal high scalar extended" arch12 zarch
-
--e700000020ea vfchesb VRR_VVV "vector fp compare high or equal short" arch12 zarch vx2
--e700001020ea vfchesbs VRR_VVV "vector fp compare high or equal short" arch12 zarch vx2
--e700000820ea wfchesb VRR_VVV "scalar vector fp compare high or equal scalar short" arch12 zarch vx2
--e700001820ea wfchesbs VRR_VVV "scalar vector fp compare high or equal scalar short" arch12 zarch vx2
--e700000840ea wfchexb VRR_VVV "scalar vector fp compare high or equal scalar extended" arch12 zarch vx2
--e700001840ea wfchexbs VRR_VVV "scalar vector fp compare high or equal scalar extended" arch12 zarch vx2
-+e700000020ea vfchesb VRR_VVV "vector fp compare high or equal short" arch12 zarch
-+e700001020ea vfchesbs VRR_VVV "vector fp compare high or equal short" arch12 zarch
-+e700000820ea wfchesb VRR_VVV "scalar vector fp compare high or equal scalar short" arch12 zarch
-+e700001820ea wfchesbs VRR_VVV "scalar vector fp compare high or equal scalar short" arch12 zarch
-+e700000840ea wfchexb VRR_VVV "scalar vector fp compare high or equal scalar extended" arch12 zarch
-+e700001840ea wfchexbs VRR_VVV "scalar vector fp compare high or equal scalar extended" arch12 zarch
-
--e700000420ea vfkhesb VRR_VVV "vector fp compare and signal high or equal short" arch12 zarch vx2
--e700001420ea vfkhesbs VRR_VVV "vector fp compare and signal high or equal short" arch12 zarch vx2
--e700000c20ea wfkhesb VRR_VVV "scalar vector fp compare and signal high or equal scalar short" arch12 zarch vx2
--e700001c20ea wfkhesbs VRR_VVV "scalar vector fp compare and signal high or equal scalar short" arch12 zarch vx2
-+e700000420ea vfkhesb VRR_VVV "vector fp compare and signal high or equal short" arch12 zarch
-+e700001420ea vfkhesbs VRR_VVV "vector fp compare and signal high or equal short" arch12 zarch
-+e700000c20ea wfkhesb VRR_VVV "scalar vector fp compare and signal high or equal scalar short" arch12 zarch
-+e700001c20ea wfkhesbs VRR_VVV "scalar vector fp compare and signal high or equal scalar short" arch12 zarch
- e700000430ea vfkhedb VRR_VVV "vector fp compare and signal high or equal long" arch12 zarch vx
- e700001430ea vfkhedbs VRR_VVV "vector fp compare and signal high or equal long" arch12 zarch vx
- e700000c30ea wfkhedb VRR_VVV "vector fp compare and signal high or equal long" arch12 zarch vx
- e700001c30ea wfkhedbs VRR_VVV "vector fp compare and signal high or equal long" arch12 zarch vx
--e700000c40ea wfkhexb VRR_VVV "scalar vector fp compare and signal high or equal scalar extended" arch12 zarch vx2
--e700001c40ea wfkhexbs VRR_VVV "scalar vector fp compare and signal high or equal scalar extended" arch12 zarch vx2
-+e700000c40ea wfkhexb VRR_VVV "scalar vector fp compare and signal high or equal scalar extended" arch12 zarch
-+e700001c40ea wfkhexbs VRR_VVV "scalar vector fp compare and signal high or equal scalar extended" arch12 zarch
-
--e700000020e5 vfdsb VRR_VVV "vector fp divide short" arch12 zarch vx2
--e700000820e5 wfdsb VRR_VVV "scalar vector fp divide scalar short" arch12 zarch vx2
--e700000840e5 wfdxb VRR_VVV "scalar vector fp divide scalar extended" arch12 zarch vx2
--e700000020c7 vfisb VRR_VV0UU "vector load fp integer short" arch12 zarch vx2
--e700000820c7 wfisb VRR_VV0UU8 "scalar vector load fp integer scalar short" arch12 zarch vx2
--e700000840c7 wfixb VRR_VV0UU8 "scalar vector load fp integer scalar extended" arch12 zarch vx2
--e700000000c4 vfll VRR_VV0UU2 "vector fp load lengthened" arch12 zarch vx2
--e700000020c4 vflls VRR_VV "vector fp load lengthened" arch12 zarch vx2
--e700000820c4 wflls VRR_VV "scalar vector fp load lengthened short" arch12 zarch vx2
--e700000830c4 wflld VRR_VV "scalar vector fp load lengthened long" arch12 zarch vx2
--e700000000c5 vflr VRR_VV0UUU "vector fp load rounded" arch12 zarch vx2
--e700000030c5 vflrd VRR_VV0UU "vector fp load rounded long" arch12 zarch vx2
--e700000830c5 wflrd VRR_VV0UU8 "scalar vector fp load rounded long" arch12 zarch vx2
--e700000840c5 wflrx VRR_VV0UU8 "scalar vector fp load rounded extended" arch12 zarch vx2
--e700000000ef vfmax VRR_VVV0UUU "vector fp maximum" arch12 zarch vx2
--e700000020ef vfmaxsb VRR_VVV0U0 "vector fp maximum short" arch12 zarch vx2
--e700000030ef vfmaxdb VRR_VVV0U0 "vector fp maximum long" arch12 zarch vx2
--e700000820ef wfmaxsb VRR_VVV0U0 "scalar fp maximum scalar short" arch12 zarch vx2
--e700000830ef wfmaxdb VRR_VVV0U0 "scalar fp maximum scalar long" arch12 zarch vx2
--e700000840ef wfmaxxb VRR_VVV0U0 "scalar fp maximum scalar extended" arch12 zarch vx2
--e700000000ee vfmin VRR_VVV0UUU "vector fp minimum" arch12 zarch vx2
--e700000020ee vfminsb VRR_VVV0U0 "vector fp minimum short" arch12 zarch vx2
--e700000030ee vfmindb VRR_VVV0U0 "vector fp minimum long" arch12 zarch vx2
--e700000820ee wfminsb VRR_VVV0U0 "scalar fp minimum scalar short" arch12 zarch vx2
--e700000830ee wfmindb VRR_VVV0U0 "scalar fp minimum scalar long" arch12 zarch vx2
--e700000840ee wfminxb VRR_VVV0U0 "scalar fp minimum scalar extended" arch12 zarch vx2
--e700000020e7 vfmsb VRR_VVV "vector fp multiply short" arch12 zarch vx2
--e700000820e7 wfmsb VRR_VVV "scalar vector fp multiply scalar short" arch12 zarch vx2
--e700000840e7 wfmxb VRR_VVV "scalar vector fp multiply scalar extended" arch12 zarch vx2
--e7000200008f vfmasb VRR_VVVV "vector fp multiply and add short" arch12 zarch vx2
--e7000208008f wfmasb VRR_VVVV "scalar vector fp multiply and add scalar short" arch12 zarch vx2
--e7000408008f wfmaxb VRR_VVVV "scalar vector fp multiply and add scalar extended" arch12 zarch vx2
--e7000200008e vfmssb VRR_VVVV "vector fp multiply and subtract short" arch12 zarch vx2
--e7000208008e wfmssb VRR_VVVV "scalar vector fp multiply and subtract scalar short" arch12 zarch vx2
--e7000408008e wfmsxb VRR_VVVV "scalar vector fp multiply and subtract scalar extended" arch12 zarch vx2
--e7000000009f vfnma VRR_VVVU0UV "vector fp negative multiply and add" arch12 zarch vx2
--e7000200009f vfnmasb VRR_VVVV "vector fp negative multiply and add short" arch12 zarch vx2
--e7000208009f wfnmasb VRR_VVVV "scalar vector fp negative multiply and add scalar short" arch12 zarch vx2
--e7000300009f vfnmadb VRR_VVVV "vector fp negative multiply and add long" arch12 zarch vx2
--e7000308009f wfnmadb VRR_VVVV "scalar vector fp negative multiply and add scalar long" arch12 zarch vx2
--e7000408009f wfnmaxb VRR_VVVV "scalar vector fp negative multiply and add scalar extended" arch12 zarch vx2
--e7000000009e vfnms VRR_VVVU0UV "vector fp negative multiply and subtract" arch12 zarch vx2
--e7000200009e vfnmssb VRR_VVVV "vector fp negative multiply and subtract short" arch12 zarch vx2
--e7000208009e wfnmssb VRR_VVVV "scalar vector fp negative multiply and subtract scalar short" arch12 zarch vx2
--e7000300009e vfnmsdb VRR_VVVV "vector fp negative multiply and subtract long" arch12 zarch vx2
--e7000308009e wfnmsdb VRR_VVVV "scalar vector fp negative multiply and subtract scalar long" arch12 zarch vx2
--e7000408009e wfnmsxb VRR_VVVV "scalar vector fp negative multiply and subtract scalar extended" arch12 zarch vx2
--e700000020cc vfpsosb VRR_VV0U2 "vector fp perform sign operation short" arch12 zarch vx2
--e700000820cc wfpsosb VRR_VV0U2 "scalar vector fp perform sign operation scalar short" arch12 zarch vx2
--e700000020cc vflcsb VRR_VV "vector fp perform sign operation short" arch12 zarch vx2
--e700000820cc wflcsb VRR_VV "scalar vector fp perform sign operation scalar short" arch12 zarch vx2
--e700001020cc vflnsb VRR_VV "vector fp perform sign operation short" arch12 zarch vx2
--e700001820cc wflnsb VRR_VV "scalar vector fp perform sign operation scalar short" arch12 zarch vx2
--e700002020cc vflpsb VRR_VV "vector fp perform sign operation short" arch12 zarch vx2
--e700002820cc wflpsb VRR_VV "scalar vector fp perform sign operation scalar short" arch12 zarch vx2
--e700000840cc wfpsoxb VRR_VV0U2 "scalar vector fp perform sign operation scalar extended" arch12 zarch vx2
--e700000840cc wflcxb VRR_VV "scalar vector fp perform sign operation scalar extended" arch12 zarch vx2
--e700001840cc wflnxb VRR_VV "scalar vector fp perform sign operation scalar extended" arch12 zarch vx2
--e700002840cc wflpxb VRR_VV "scalar vector fp perform sign operation scalar extended" arch12 zarch vx2
--e700000020ce vfsqsb VRR_VV "vector fp square root short" arch12 zarch vx2
--e700000820ce wfsqsb VRR_VV "scalar vector fp square root scalar short" arch12 zarch vx2
--e700000840ce wfsqxb VRR_VV "scalar vector fp square root scalar extended" arch12 zarch vx2
--e700000020e2 vfssb VRR_VVV "vector fp subtract short" arch12 zarch vx2
--e700000820e2 wfssb VRR_VVV "scalar vector fp subtract scalar short" arch12 zarch vx2
--e700000840e2 wfsxb VRR_VVV "scalar vector fp subtract scalar extended" arch12 zarch vx2
--e7000000204a vftcisb VRI_VVU2 "vector fp test data class immediate short" arch12 zarch vx2
--e7000008204a wftcisb VRI_VVU2 "scalar vector fp test data class immediate scalar short" arch12 zarch vx2
--e7000008404a wftcixb VRI_VVU2 "scalar vector fp test data class immediate scalar extended" arch12 zarch vx2
-+e700000020e5 vfdsb VRR_VVV "vector fp divide short" arch12 zarch
-+e700000820e5 wfdsb VRR_VVV "scalar vector fp divide scalar short" arch12 zarch
-+e700000840e5 wfdxb VRR_VVV "scalar vector fp divide scalar extended" arch12 zarch
-+e700000020c7 vfisb VRR_VV0UU "vector load fp integer short" arch12 zarch
-+e700000820c7 wfisb VRR_VV0UU8 "scalar vector load fp integer scalar short" arch12 zarch
-+e700000840c7 wfixb VRR_VV0UU8 "scalar vector load fp integer scalar extended" arch12 zarch
-+e700000000c4 vfll VRR_VV0UU2 "vector fp load lengthened" arch12 zarch
-+e700000020c4 vflls VRR_VV "vector fp load lengthened" arch12 zarch
-+e700000820c4 wflls VRR_VV "scalar vector fp load lengthened short" arch12 zarch
-+e700000830c4 wflld VRR_VV "scalar vector fp load lengthened long" arch12 zarch
-+e700000000c5 vflr VRR_VV0UUU "vector fp load rounded" arch12 zarch
-+e700000030c5 vflrd VRR_VV0UU "vector fp load rounded long" arch12 zarch
-+e700000830c5 wflrd VRR_VV0UU8 "scalar vector fp load rounded long" arch12 zarch
-+e700000840c5 wflrx VRR_VV0UU8 "scalar vector fp load rounded extended" arch12 zarch
-+e700000000ef vfmax VRR_VVV0UUU "vector fp maximum" arch12 zarch
-+e700000020ef vfmaxsb VRR_VVV0U0 "vector fp maximum short" arch12 zarch
-+e700000030ef vfmaxdb VRR_VVV0U0 "vector fp maximum long" arch12 zarch
-+e700000820ef wfmaxsb VRR_VVV0U0 "scalar fp maximum scalar short" arch12 zarch
-+e700000830ef wfmaxdb VRR_VVV0U0 "scalar fp maximum scalar long" arch12 zarch
-+e700000840ef wfmaxxb VRR_VVV0U0 "scalar fp maximum scalar extended" arch12 zarch
-+e700000000ee vfmin VRR_VVV0UUU "vector fp minimum" arch12 zarch
-+e700000020ee vfminsb VRR_VVV0U0 "vector fp minimum short" arch12 zarch
-+e700000030ee vfmindb VRR_VVV0U0 "vector fp minimum long" arch12 zarch
-+e700000820ee wfminsb VRR_VVV0U0 "scalar fp minimum scalar short" arch12 zarch
-+e700000830ee wfmindb VRR_VVV0U0 "scalar fp minimum scalar long" arch12 zarch
-+e700000840ee wfminxb VRR_VVV0U0 "scalar fp minimum scalar extended" arch12 zarch
-+e700000020e7 vfmsb VRR_VVV "vector fp multiply short" arch12 zarch
-+e700000820e7 wfmsb VRR_VVV "scalar vector fp multiply scalar short" arch12 zarch
-+e700000840e7 wfmxb VRR_VVV "scalar vector fp multiply scalar extended" arch12 zarch
-+e7000200008f vfmasb VRR_VVVV "vector fp multiply and add short" arch12 zarch
-+e7000208008f wfmasb VRR_VVVV "scalar vector fp multiply and add scalar short" arch12 zarch
-+e7000408008f wfmaxb VRR_VVVV "scalar vector fp multiply and add scalar extended" arch12 zarch
-+e7000200008e vfmssb VRR_VVVV "vector fp multiply and subtract short" arch12 zarch
-+e7000208008e wfmssb VRR_VVVV "scalar vector fp multiply and subtract scalar short" arch12 zarch
-+e7000408008e wfmsxb VRR_VVVV "scalar vector fp multiply and subtract scalar extended" arch12 zarch
-+e7000000009f vfnma VRR_VVVU0UV "vector fp negative multiply and add" arch12 zarch
-+e7000200009f vfnmasb VRR_VVVV "vector fp negative multiply and add short" arch12 zarch
-+e7000208009f wfnmasb VRR_VVVV "scalar vector fp negative multiply and add scalar short" arch12 zarch
-+e7000300009f vfnmadb VRR_VVVV "vector fp negative multiply and add long" arch12 zarch
-+e7000308009f wfnmadb VRR_VVVV "scalar vector fp negative multiply and add scalar long" arch12 zarch
-+e7000408009f wfnmaxb VRR_VVVV "scalar vector fp negative multiply and add scalar extended" arch12 zarch
-+e7000000009e vfnms VRR_VVVU0UV "vector fp negative multiply and subtract" arch12 zarch
-+e7000200009e vfnmssb VRR_VVVV "vector fp negative multiply and subtract short" arch12 zarch
-+e7000208009e wfnmssb VRR_VVVV "scalar vector fp negative multiply and subtract scalar short" arch12 zarch
-+e7000300009e vfnmsdb VRR_VVVV "vector fp negative multiply and subtract long" arch12 zarch
-+e7000308009e wfnmsdb VRR_VVVV "scalar vector fp negative multiply and subtract scalar long" arch12 zarch
-+e7000408009e wfnmsxb VRR_VVVV "scalar vector fp negative multiply and subtract scalar extended" arch12 zarch
-+e700000020cc vfpsosb VRR_VV0U2 "vector fp perform sign operation short" arch12 zarch
-+e700000820cc wfpsosb VRR_VV0U2 "scalar vector fp perform sign operation scalar short" arch12 zarch
-+e700000020cc vflcsb VRR_VV "vector fp perform sign operation short" arch12 zarch
-+e700000820cc wflcsb VRR_VV "scalar vector fp perform sign operation scalar short" arch12 zarch
-+e700001020cc vflnsb VRR_VV "vector fp perform sign operation short" arch12 zarch
-+e700001820cc wflnsb VRR_VV "scalar vector fp perform sign operation scalar short" arch12 zarch
-+e700002020cc vflpsb VRR_VV "vector fp perform sign operation short" arch12 zarch
-+e700002820cc wflpsb VRR_VV "scalar vector fp perform sign operation scalar short" arch12 zarch
-+e700000840cc wfpsoxb VRR_VV0U2 "scalar vector fp perform sign operation scalar extended" arch12 zarch
-+e700000840cc wflcxb VRR_VV "scalar vector fp perform sign operation scalar extended" arch12 zarch
-+e700001840cc wflnxb VRR_VV "scalar vector fp perform sign operation scalar extended" arch12 zarch
-+e700002840cc wflpxb VRR_VV "scalar vector fp perform sign operation scalar extended" arch12 zarch
-+e700000020ce vfsqsb VRR_VV "vector fp square root short" arch12 zarch
-+e700000820ce wfsqsb VRR_VV "scalar vector fp square root scalar short" arch12 zarch
-+e700000840ce wfsqxb VRR_VV "scalar vector fp square root scalar extended" arch12 zarch
-+e700000020e2 vfssb VRR_VVV "vector fp subtract short" arch12 zarch
-+e700000820e2 wfssb VRR_VVV "scalar vector fp subtract scalar short" arch12 zarch
-+e700000840e2 wfsxb VRR_VVV "scalar vector fp subtract scalar extended" arch12 zarch
-+e7000000204a vftcisb VRI_VVU2 "vector fp test data class immediate short" arch12 zarch
-+e7000008204a wftcisb VRI_VVU2 "scalar vector fp test data class immediate scalar short" arch12 zarch
-+e7000008404a wftcixb VRI_VVU2 "scalar vector fp test data class immediate scalar extended" arch12 zarch
-
- # Miscellaneous Instruction Extensions Facility 2
-
-@@ -1843,28 +1843,28 @@ e30000000039 sgh RXY_RRRD "subtract halfword from 64 bit value" arch12 zarch
-
- # Vector packed decimal facility
-
--e60000000037 vlrlr VRS_RRDV "vector load rightmost with length" arch12 zarch vx2
--e60000000035 vlrl VSI_URDV "vector load rightmost with immediate length" arch12 zarch vx2
--e6000000003f vstrlr VRS_RRDV "vector store rightmost with length" arch12 zarch vx2
--e6000000003d vstrl VSI_URDV "vector store rightmost with immediate length" arch12 zarch vx2
--e60000000071 vap VRI_VVV0UU2 "vector add decimal" arch12 zarch vx2
--e60000000077 vcp VRR_0VV0U "vector compare decimal" arch12 zarch vx2
--e60000000050 vcvb VRR_RV0U "vector convert to binary 32 bit" arch12 zarch vx2
--e60000000052 vcvbg VRR_RV0U "vector convert to binary 64 bit" arch12 zarch vx2
--e60000000058 vcvd VRI_VR0UU "vector convert to decimal 32 bit" arch12 zarch vx2
--e6000000005a vcvdg VRI_VR0UU "vector convert to decimal 64 bit" arch12 zarch vx2
--e6000000007a vdp VRI_VVV0UU2 "vector divide decimal" arch12 zarch vx2
--e60000000049 vlip VRI_V0UU2 "vector load immediate decimal" arch12 zarch vx2
--e60000000078 vmp VRI_VVV0UU2 "vector multiply decimal" arch12 zarch vx2
--e60000000079 vmsp VRI_VVV0UU2 "vector multiply and shift decimal" arch12 zarch vx2
--e60000000034 vpkz VSI_URDV "vector pack zoned" arch12 zarch vx2
--e6000000005b vpsop VRI_VVUUU2 "vector perform sign operation decimal" arch12 zarch vx2
--e6000000007b vrp VRI_VVV0UU2 "vector remainder decimal" arch12 zarch vx2
--e6000000007e vsdp VRI_VVV0UU2 "vector shift and divide decimal" arch12 zarch vx2
--e60000000059 vsrp VRI_VVUUU2 "vector shift and round decimal" arch12 zarch vx2
--e60000000073 vsp VRI_VVV0UU2 "vector subtract decimal" arch12 zarch vx2
--e6000000005f vtp VRR_0V "vector test decimal" arch12 zarch vx2
--e6000000003c vupkz VSI_URDV "vector unpack zoned" arch12 zarch vx2
-+e60000000037 vlrlr VRS_RRDV "vector load rightmost with length" arch12 zarch
-+e60000000035 vlrl VSI_URDV "vector load rightmost with immediate length" arch12 zarch
-+e6000000003f vstrlr VRS_RRDV "vector store rightmost with length" arch12 zarch
-+e6000000003d vstrl VSI_URDV "vector store rightmost with immediate length" arch12 zarch
-+e60000000071 vap VRI_VVV0UU2 "vector add decimal" arch12 zarch
-+e60000000077 vcp VRR_0VV0U "vector compare decimal" arch12 zarch
-+e60000000050 vcvb VRR_RV0U "vector convert to binary 32 bit" arch12 zarch
-+e60000000052 vcvbg VRR_RV0U "vector convert to binary 64 bit" arch12 zarch
-+e60000000058 vcvd VRI_VR0UU "vector convert to decimal 32 bit" arch12 zarch
-+e6000000005a vcvdg VRI_VR0UU "vector convert to decimal 64 bit" arch12 zarch
-+e6000000007a vdp VRI_VVV0UU2 "vector divide decimal" arch12 zarch
-+e60000000049 vlip VRI_V0UU2 "vector load immediate decimal" arch12 zarch
-+e60000000078 vmp VRI_VVV0UU2 "vector multiply decimal" arch12 zarch
-+e60000000079 vmsp VRI_VVV0UU2 "vector multiply and shift decimal" arch12 zarch
-+e60000000034 vpkz VSI_URDV "vector pack zoned" arch12 zarch
-+e6000000005b vpsop VRI_VVUUU2 "vector perform sign operation decimal" arch12 zarch
-+e6000000007b vrp VRI_VVV0UU2 "vector remainder decimal" arch12 zarch
-+e6000000007e vsdp VRI_VVV0UU2 "vector shift and divide decimal" arch12 zarch
-+e60000000059 vsrp VRI_VVUUU2 "vector shift and round decimal" arch12 zarch
-+e60000000073 vsp VRI_VVV0UU2 "vector subtract decimal" arch12 zarch
-+e6000000005f vtp VRR_0V "vector test decimal" arch12 zarch
-+e6000000003c vupkz VSI_URDV "vector unpack zoned" arch12 zarch
-
- # Guarded storage facility
-
diff --git a/debian/patches/branch-version.diff b/debian/patches/branch-version.diff
index 57c9d4d..e6f509b 100644
--- a/debian/patches/branch-version.diff
+++ b/debian/patches/branch-version.diff
@@ -1,632 +1,4 @@
# DP: Don't bump the version when doing distro builds
-git diff 65a5565505619c451987c77f199d0d1b0a84349b 2870b1ba83fc0e0ee7eadf72d614a7ec4591b169
+git diff 04165950d1397154a784cd55da758d5c7a8d3457 b5624945ea67525c0ba4ffec7a9d3f9366bf9071
-Index: b/bfd/ChangeLog
-===================================================================
---- a/bfd/ChangeLog
-+++ b/bfd/ChangeLog
-@@ -6,15 +6,6 @@
-
- 2016-08-03 Tristan Gingold <gingold@adacore.com>
-
-- * version.m4: Bump version to 2.28.0
-- * configure: Regenerate.
--
--2016-08-03 Tristan Gingold <gingold@adacore.com>
--
-- * development.sh: Set development to true.
--
--2016-08-03 Tristan Gingold <gingold@adacore.com>
--
- * version.m4: Bump version to 2.28
- * configure: Regenerate.
-
-Index: b/bfd/configure
-===================================================================
---- a/bfd/configure
-+++ b/bfd/configure
-@@ -1,6 +1,6 @@
- #! /bin/sh
- # Guess values for system-dependent variables and create Makefiles.
--# Generated by GNU Autoconf 2.64 for bfd 2.28.0.
-+# Generated by GNU Autoconf 2.64 for bfd 2.28.
- #
- # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
- # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
-@@ -556,8 +556,8 @@ MAKEFLAGS=
- # Identity of this package.
- PACKAGE_NAME='bfd'
- PACKAGE_TARNAME='bfd'
--PACKAGE_VERSION='2.28.0'
--PACKAGE_STRING='bfd 2.28.0'
-+PACKAGE_VERSION='2.28'
-+PACKAGE_STRING='bfd 2.28'
- PACKAGE_BUGREPORT=''
- PACKAGE_URL=''
-
-@@ -1353,7 +1353,7 @@ if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
--\`configure' configures bfd 2.28.0 to adapt to many kinds of systems.
-+\`configure' configures bfd 2.28 to adapt to many kinds of systems.
-
- Usage: $0 [OPTION]... [VAR=VALUE]...
-
-@@ -1424,7 +1424,7 @@ fi
-
- if test -n "$ac_init_help"; then
- case $ac_init_help in
-- short | recursive ) echo "Configuration of bfd 2.28.0:";;
-+ short | recursive ) echo "Configuration of bfd 2.28:";;
- esac
- cat <<\_ACEOF
-
-@@ -1545,7 +1545,7 @@ fi
- test -n "$ac_init_help" && exit $ac_status
- if $ac_init_version; then
- cat <<\_ACEOF
--bfd configure 2.28.0
-+bfd configure 2.28
- generated by GNU Autoconf 2.64
-
- Copyright (C) 2009 Free Software Foundation, Inc.
-@@ -2187,7 +2187,7 @@ cat >config.log <<_ACEOF
- This file contains any messages produced by compilers while
- running configure, to aid debugging if configure makes a mistake.
-
--It was created by bfd $as_me 2.28.0, which was
-+It was created by bfd $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- $ $0 $@
-@@ -3996,7 +3996,7 @@ fi
-
- # Define the identity of the package.
- PACKAGE='bfd'
-- VERSION='2.28.0'
-+ VERSION='2.28'
-
-
- cat >>confdefs.h <<_ACEOF
-@@ -16576,7 +16576,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_wri
- # report actual input values of CONFIG_FILES etc. instead of their
- # values after options handling.
- ac_log="
--This file was extended by bfd $as_me 2.28.0, which was
-+This file was extended by bfd $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
-@@ -16640,7 +16640,7 @@ Report bugs to the package provider."
- _ACEOF
- cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_cs_version="\\
--bfd config.status 2.28.0
-+bfd config.status 2.28
- configured by $0, generated by GNU Autoconf 2.64,
- with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-
-Index: b/bfd/development.sh
-===================================================================
---- a/bfd/development.sh
-+++ b/bfd/development.sh
-@@ -16,4 +16,4 @@
- # along with this program. If not, see <http://www.gnu.org/licenses/>.
-
- # Controls whether to enable development-mode features by default.
--development=true
-+development=false
-Index: b/bfd/version.m4
-===================================================================
---- a/bfd/version.m4
-+++ b/bfd/version.m4
-@@ -1 +1 @@
--m4_define([BFD_VERSION], [2.28.0])
-+m4_define([BFD_VERSION], [2.28])
-Index: b/binutils/ChangeLog
-===================================================================
---- a/binutils/ChangeLog
-+++ b/binutils/ChangeLog
-@@ -2,10 +2,6 @@
-
- * configure: Regenerate.
-
--2016-08-03 Tristan Gingold <gingold@adacore.com>
--
-- * configure: Regenerate.
--
- 2016-07-01 Nick Clifton <nickc@redhat.com>
-
- * Import this patch from the mainline:
-Index: b/binutils/configure
-===================================================================
---- a/binutils/configure
-+++ b/binutils/configure
-@@ -1,6 +1,6 @@
- #! /bin/sh
- # Guess values for system-dependent variables and create Makefiles.
--# Generated by GNU Autoconf 2.64 for binutils 2.28.0.
-+# Generated by GNU Autoconf 2.64 for binutils 2.28.
- #
- # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
- # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
-@@ -556,8 +556,8 @@ MAKEFLAGS=
- # Identity of this package.
- PACKAGE_NAME='binutils'
- PACKAGE_TARNAME='binutils'
--PACKAGE_VERSION='2.28.0'
--PACKAGE_STRING='binutils 2.28.0'
-+PACKAGE_VERSION='2.28'
-+PACKAGE_STRING='binutils 2.28'
- PACKAGE_BUGREPORT=''
- PACKAGE_URL=''
-
-@@ -1337,7 +1337,7 @@ if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
--\`configure' configures binutils 2.28.0 to adapt to many kinds of systems.
-+\`configure' configures binutils 2.28 to adapt to many kinds of systems.
-
- Usage: $0 [OPTION]... [VAR=VALUE]...
-
-@@ -1408,7 +1408,7 @@ fi
-
- if test -n "$ac_init_help"; then
- case $ac_init_help in
-- short | recursive ) echo "Configuration of binutils 2.28.0:";;
-+ short | recursive ) echo "Configuration of binutils 2.28:";;
- esac
- cat <<\_ACEOF
-
-@@ -1529,7 +1529,7 @@ fi
- test -n "$ac_init_help" && exit $ac_status
- if $ac_init_version; then
- cat <<\_ACEOF
--binutils configure 2.28.0
-+binutils configure 2.28
- generated by GNU Autoconf 2.64
-
- Copyright (C) 2009 Free Software Foundation, Inc.
-@@ -2171,7 +2171,7 @@ cat >config.log <<_ACEOF
- This file contains any messages produced by compilers while
- running configure, to aid debugging if configure makes a mistake.
-
--It was created by binutils $as_me 2.28.0, which was
-+It was created by binutils $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- $ $0 $@
-@@ -3980,7 +3980,7 @@ fi
-
- # Define the identity of the package.
- PACKAGE='binutils'
-- VERSION='2.28.0'
-+ VERSION='2.28'
-
-
- cat >>confdefs.h <<_ACEOF
-@@ -15179,7 +15179,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_wri
- # report actual input values of CONFIG_FILES etc. instead of their
- # values after options handling.
- ac_log="
--This file was extended by binutils $as_me 2.28.0, which was
-+This file was extended by binutils $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
-@@ -15243,7 +15243,7 @@ Report bugs to the package provider."
- _ACEOF
- cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_cs_version="\\
--binutils config.status 2.28.0
-+binutils config.status 2.28
- configured by $0, generated by GNU Autoconf 2.64,
- with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-
-Index: b/gas/ChangeLog
-===================================================================
---- a/gas/ChangeLog
-+++ b/gas/ChangeLog
-@@ -2,10 +2,6 @@
-
- * configure: Regenerate.
-
--2016-08-03 Tristan Gingold <gingold@adacore.com>
--
-- * configure: Regenerate.
--
- 2016-07-01 Tristan Gingold <gingold@adacore.com>
-
- * configure: Regenerate.
-Index: b/gas/configure
-===================================================================
---- a/gas/configure
-+++ b/gas/configure
-@@ -1,6 +1,6 @@
- #! /bin/sh
- # Guess values for system-dependent variables and create Makefiles.
--# Generated by GNU Autoconf 2.64 for gas 2.28.0.
-+# Generated by GNU Autoconf 2.64 for gas 2.28.
- #
- # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
- # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
-@@ -556,8 +556,8 @@ MAKEFLAGS=
- # Identity of this package.
- PACKAGE_NAME='gas'
- PACKAGE_TARNAME='gas'
--PACKAGE_VERSION='2.28.0'
--PACKAGE_STRING='gas 2.28.0'
-+PACKAGE_VERSION='2.28'
-+PACKAGE_STRING='gas 2.28'
- PACKAGE_BUGREPORT=''
- PACKAGE_URL=''
-
-@@ -1328,7 +1328,7 @@ if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
--\`configure' configures gas 2.28.0 to adapt to many kinds of systems.
-+\`configure' configures gas 2.28 to adapt to many kinds of systems.
-
- Usage: $0 [OPTION]... [VAR=VALUE]...
-
-@@ -1399,7 +1399,7 @@ fi
-
- if test -n "$ac_init_help"; then
- case $ac_init_help in
-- short | recursive ) echo "Configuration of gas 2.28.0:";;
-+ short | recursive ) echo "Configuration of gas 2.28:";;
- esac
- cat <<\_ACEOF
-
-@@ -1521,7 +1521,7 @@ fi
- test -n "$ac_init_help" && exit $ac_status
- if $ac_init_version; then
- cat <<\_ACEOF
--gas configure 2.28.0
-+gas configure 2.28
- generated by GNU Autoconf 2.64
-
- Copyright (C) 2009 Free Software Foundation, Inc.
-@@ -1931,7 +1931,7 @@ cat >config.log <<_ACEOF
- This file contains any messages produced by compilers while
- running configure, to aid debugging if configure makes a mistake.
-
--It was created by gas $as_me 2.28.0, which was
-+It was created by gas $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- $ $0 $@
-@@ -3740,7 +3740,7 @@ fi
-
- # Define the identity of the package.
- PACKAGE='gas'
-- VERSION='2.28.0'
-+ VERSION='2.28'
-
-
- cat >>confdefs.h <<_ACEOF
-@@ -15137,7 +15137,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_wri
- # report actual input values of CONFIG_FILES etc. instead of their
- # values after options handling.
- ac_log="
--This file was extended by gas $as_me 2.28.0, which was
-+This file was extended by gas $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
-@@ -15201,7 +15201,7 @@ Report bugs to the package provider."
- _ACEOF
- cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_cs_version="\\
--gas config.status 2.28.0
-+gas config.status 2.28
- configured by $0, generated by GNU Autoconf 2.64,
- with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-
-Index: b/gprof/ChangeLog
-===================================================================
---- a/gprof/ChangeLog
-+++ b/gprof/ChangeLog
-@@ -2,10 +2,6 @@
-
- * configure: Regenerate.
-
--2016-08-03 Tristan Gingold <gingold@adacore.com>
--
-- * configure: Regenerate.
--
- 2016-07-01 Tristan Gingold <gingold@adacore.com>
-
- * configure: Regenerate.
-Index: b/gprof/configure
-===================================================================
---- a/gprof/configure
-+++ b/gprof/configure
-@@ -1,6 +1,6 @@
- #! /bin/sh
- # Guess values for system-dependent variables and create Makefiles.
--# Generated by GNU Autoconf 2.64 for gprof 2.28.0.
-+# Generated by GNU Autoconf 2.64 for gprof 2.28.
- #
- # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
- # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
-@@ -556,8 +556,8 @@ MAKEFLAGS=
- # Identity of this package.
- PACKAGE_NAME='gprof'
- PACKAGE_TARNAME='gprof'
--PACKAGE_VERSION='2.28.0'
--PACKAGE_STRING='gprof 2.28.0'
-+PACKAGE_VERSION='2.28'
-+PACKAGE_STRING='gprof 2.28'
- PACKAGE_BUGREPORT=''
- PACKAGE_URL=''
-
-@@ -1301,7 +1301,7 @@ if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
--\`configure' configures gprof 2.28.0 to adapt to many kinds of systems.
-+\`configure' configures gprof 2.28 to adapt to many kinds of systems.
-
- Usage: $0 [OPTION]... [VAR=VALUE]...
-
-@@ -1372,7 +1372,7 @@ fi
-
- if test -n "$ac_init_help"; then
- case $ac_init_help in
-- short | recursive ) echo "Configuration of gprof 2.28.0:";;
-+ short | recursive ) echo "Configuration of gprof 2.28:";;
- esac
- cat <<\_ACEOF
-
-@@ -1478,7 +1478,7 @@ fi
- test -n "$ac_init_help" && exit $ac_status
- if $ac_init_version; then
- cat <<\_ACEOF
--gprof configure 2.28.0
-+gprof configure 2.28
- generated by GNU Autoconf 2.64
-
- Copyright (C) 2009 Free Software Foundation, Inc.
-@@ -1843,7 +1843,7 @@ cat >config.log <<_ACEOF
- This file contains any messages produced by compilers while
- running configure, to aid debugging if configure makes a mistake.
-
--It was created by gprof $as_me 2.28.0, which was
-+It was created by gprof $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- $ $0 $@
-@@ -3652,7 +3652,7 @@ fi
-
- # Define the identity of the package.
- PACKAGE='gprof'
-- VERSION='2.28.0'
-+ VERSION='2.28'
-
-
- cat >>confdefs.h <<_ACEOF
-@@ -12743,7 +12743,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_wri
- # report actual input values of CONFIG_FILES etc. instead of their
- # values after options handling.
- ac_log="
--This file was extended by gprof $as_me 2.28.0, which was
-+This file was extended by gprof $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
-@@ -12807,7 +12807,7 @@ Report bugs to the package provider."
- _ACEOF
- cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_cs_version="\\
--gprof config.status 2.28.0
-+gprof config.status 2.28
- configured by $0, generated by GNU Autoconf 2.64,
- with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-
-Index: b/ld/ChangeLog
-===================================================================
---- a/ld/ChangeLog
-+++ b/ld/ChangeLog
-@@ -20,10 +20,6 @@
-
- * configure: Regenerate.
-
--2016-08-03 Tristan Gingold <gingold@adacore.com>
--
-- * configure: Regenerate.
--
- 2016-07-19 Roland McGrath <roland@hack.frob.com>
-
- * emulparams/aarch64elf.sh (GENERATE_PIE_SCRIPT): Set to yes.
-Index: b/ld/configure
-===================================================================
---- a/ld/configure
-+++ b/ld/configure
-@@ -1,6 +1,6 @@
- #! /bin/sh
- # Guess values for system-dependent variables and create Makefiles.
--# Generated by GNU Autoconf 2.64 for ld 2.28.0.
-+# Generated by GNU Autoconf 2.64 for ld 2.28.
- #
- # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
- # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
-@@ -556,8 +556,8 @@ MAKEFLAGS=
- # Identity of this package.
- PACKAGE_NAME='ld'
- PACKAGE_TARNAME='ld'
--PACKAGE_VERSION='2.28.0'
--PACKAGE_STRING='ld 2.28.0'
-+PACKAGE_VERSION='2.28'
-+PACKAGE_STRING='ld 2.28'
- PACKAGE_BUGREPORT=''
- PACKAGE_URL=''
-
-@@ -1353,7 +1353,7 @@ if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
--\`configure' configures ld 2.28.0 to adapt to many kinds of systems.
-+\`configure' configures ld 2.28 to adapt to many kinds of systems.
-
- Usage: $0 [OPTION]... [VAR=VALUE]...
-
-@@ -1424,7 +1424,7 @@ fi
-
- if test -n "$ac_init_help"; then
- case $ac_init_help in
-- short | recursive ) echo "Configuration of ld 2.28.0:";;
-+ short | recursive ) echo "Configuration of ld 2.28:";;
- esac
- cat <<\_ACEOF
-
-@@ -1549,7 +1549,7 @@ fi
- test -n "$ac_init_help" && exit $ac_status
- if $ac_init_version; then
- cat <<\_ACEOF
--ld configure 2.28.0
-+ld configure 2.28
- generated by GNU Autoconf 2.64
-
- Copyright (C) 2009 Free Software Foundation, Inc.
-@@ -2258,7 +2258,7 @@ cat >config.log <<_ACEOF
- This file contains any messages produced by compilers while
- running configure, to aid debugging if configure makes a mistake.
-
--It was created by ld $as_me 2.28.0, which was
-+It was created by ld $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- $ $0 $@
-@@ -4068,7 +4068,7 @@ fi
-
- # Define the identity of the package.
- PACKAGE='ld'
-- VERSION='2.28.0'
-+ VERSION='2.28'
-
-
- cat >>confdefs.h <<_ACEOF
-@@ -17769,7 +17769,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_wri
- # report actual input values of CONFIG_FILES etc. instead of their
- # values after options handling.
- ac_log="
--This file was extended by ld $as_me 2.28.0, which was
-+This file was extended by ld $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
-@@ -17833,7 +17833,7 @@ Report bugs to the package provider."
- _ACEOF
- cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_cs_version="\\
--ld config.status 2.28.0
-+ld config.status 2.28
- configured by $0, generated by GNU Autoconf 2.64,
- with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-
-Index: b/opcodes/ChangeLog
-===================================================================
---- a/opcodes/ChangeLog
-+++ b/opcodes/ChangeLog
-@@ -2,10 +2,6 @@
-
- * configure: Regenerate.
-
--2016-08-03 Tristan Gingold <gingold@adacore.com>
--
-- * configure: Regenerate.
--
- 2016-07-01 Tristan Gingold <gingold@adacore.com>
-
- * configure: Regenerate.
-Index: b/opcodes/configure
-===================================================================
---- a/opcodes/configure
-+++ b/opcodes/configure
-@@ -1,6 +1,6 @@
- #! /bin/sh
- # Guess values for system-dependent variables and create Makefiles.
--# Generated by GNU Autoconf 2.64 for opcodes 2.28.0.
-+# Generated by GNU Autoconf 2.64 for opcodes 2.28.
- #
- # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
- # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
-@@ -556,8 +556,8 @@ MAKEFLAGS=
- # Identity of this package.
- PACKAGE_NAME='opcodes'
- PACKAGE_TARNAME='opcodes'
--PACKAGE_VERSION='2.28.0'
--PACKAGE_STRING='opcodes 2.28.0'
-+PACKAGE_VERSION='2.28'
-+PACKAGE_STRING='opcodes 2.28'
- PACKAGE_BUGREPORT=''
- PACKAGE_URL=''
-
-@@ -1321,7 +1321,7 @@ if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
--\`configure' configures opcodes 2.28.0 to adapt to many kinds of systems.
-+\`configure' configures opcodes 2.28 to adapt to many kinds of systems.
-
- Usage: $0 [OPTION]... [VAR=VALUE]...
-
-@@ -1392,7 +1392,7 @@ fi
-
- if test -n "$ac_init_help"; then
- case $ac_init_help in
-- short | recursive ) echo "Configuration of opcodes 2.28.0:";;
-+ short | recursive ) echo "Configuration of opcodes 2.28:";;
- esac
- cat <<\_ACEOF
-
-@@ -1499,7 +1499,7 @@ fi
- test -n "$ac_init_help" && exit $ac_status
- if $ac_init_version; then
- cat <<\_ACEOF
--opcodes configure 2.28.0
-+opcodes configure 2.28
- generated by GNU Autoconf 2.64
-
- Copyright (C) 2009 Free Software Foundation, Inc.
-@@ -1909,7 +1909,7 @@ cat >config.log <<_ACEOF
- This file contains any messages produced by compilers while
- running configure, to aid debugging if configure makes a mistake.
-
--It was created by opcodes $as_me 2.28.0, which was
-+It was created by opcodes $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- $ $0 $@
-@@ -3718,7 +3718,7 @@ fi
-
- # Define the identity of the package.
- PACKAGE='opcodes'
-- VERSION='2.28.0'
-+ VERSION='2.28'
-
-
- cat >>confdefs.h <<_ACEOF
-@@ -13260,7 +13260,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_wri
- # report actual input values of CONFIG_FILES etc. instead of their
- # values after options handling.
- ac_log="
--This file was extended by opcodes $as_me 2.28.0, which was
-+This file was extended by opcodes $as_me 2.28, which was
- generated by GNU Autoconf 2.64. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
-@@ -13324,7 +13324,7 @@ Report bugs to the package provider."
- _ACEOF
- cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_cs_version="\\
--opcodes config.status 2.28.0
-+opcodes config.status 2.28
- configured by $0, generated by GNU Autoconf 2.64,
- with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-
diff --git a/debian/patches/gold-no-keep-files-mapped.diff b/debian/patches/gold-no-keep-files-mapped.diff
new file mode 100644
index 0000000..cdf1bf6
--- /dev/null
+++ b/debian/patches/gold-no-keep-files-mapped.diff
@@ -0,0 +1,16 @@
+# DP: gold on 32bit archs: Release mapped files after each pass.
+
+Index: b/gold/options.h
+===================================================================
+--- a/gold/options.h
++++ b/gold/options.h
+@@ -999,7 +999,8 @@ class General_options
+
+ // k
+
+- DEFINE_bool(keep_files_mapped, options::TWO_DASHES, '\0', true,
++ DEFINE_bool(keep_files_mapped, options::TWO_DASHES, '\0',
++ sizeof(void*) >= 8,
+ N_("Keep files mapped across passes"),
+ N_("Release mapped files after each pass"));
+
diff --git a/debian/patches/gold-sparc-fix.diff b/debian/patches/gold-sparc-fix.diff
deleted file mode 100644
index 6059819..0000000
--- a/debian/patches/gold-sparc-fix.diff
+++ /dev/null
@@ -1,44 +0,0 @@
-Return-Path: <jrtc27@jrtc27.com>
-Received: from Jamess-MacBook.local (global-184-8.nat-1.net.cam.ac.uk. [131.111.184.8])
- by smtp.gmail.com with ESMTPSA id h65sm4893155wrh.32.2017.04.28.09.13.06
- (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
- Fri, 28 Apr 2017 09:13:06 -0700 (PDT)
-Received: by Jamess-MacBook.local (Postfix, from userid 501)
- id 9CE3D18952FC; Fri, 28 Apr 2017 17:13:05 +0100 (BST)
-From: James Clarke <jrtc27@jrtc27.com>
-To: binutils@sourceware.org
-Cc: James Clarke <jrtc27@jrtc27.com>,
- John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>,
- Cary Coutant <ccoutant@gmail.com>,
- "Jose E. Marchesi" <jose.marchesi@oracle.com>
-Subject: [PATCH] gold: Fix assertion failure relaxing TLS for position-independent executables
-Date: Fri, 28 Apr 2017 17:12:14 +0100
-Message-Id: <20170428161214.83513-1-jrtc27@jrtc27.com>
-X-Mailer: git-send-email 2.12.2
-
-gold/
- PR gold/21444
- * gold.cc (Target_sparc::Relocate::relocate_tls): Local
- variables are final for position-independent executables. This
- has to be consistent with Target_sparc::Scan::local otherwise
- they will disagree as to whether local-exec is used.
----
- gold/sparc.cc | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/gold/sparc.cc b/gold/sparc.cc
-index a9cb93adda..54c7c33498 100644
---- a/gold/sparc.cc
-+++ b/gold/sparc.cc
-@@ -3730,7 +3730,7 @@ Target_sparc<size, big_endian>::Relocate::relocate_tls(
-
- const bool is_final =
- (gsym == NULL
-- ? !parameters->options().output_is_position_independent()
-+ ? !parameters->options().shared()
- : gsym->final_value_is_known());
- const tls::Tls_optimization optimized_type
- = optimize_tls_reloc(is_final, r_type);
---
-2.12.2
-
diff --git a/debian/patches/gprof-build.diff b/debian/patches/gprof-build.diff
index d26c5af..82377ee 100644
--- a/debian/patches/gprof-build.diff
+++ b/debian/patches/gprof-build.diff
@@ -11,6 +11,6 @@ Index: b/gprof/gconfig.in
-/* Version number of package */
-#undef VERSION
-
- /* Number of bits in a file offset, on hosts where this is settable. */
- #undef _FILE_OFFSET_BITS
-
+ /* Enable large inode numbers on Mac OS X 10.5. */
+ #ifndef _DARWIN_USE_64_BIT_INODE
+ # define _DARWIN_USE_64_BIT_INODE 1
diff --git a/debian/patches/i18n-fr.diff b/debian/patches/i18n-fr.diff
deleted file mode 100644
index 3366846..0000000
--- a/debian/patches/i18n-fr.diff
+++ /dev/null
@@ -1,13 +0,0 @@
-Index: b/bfd/po/fr.po
-===================================================================
---- a/bfd/po/fr.po
-+++ b/bfd/po/fr.po
-@@ -2890,7 +2890,7 @@ msgstr "%B: réadressage R_X86_64_GOTOFF
-
- #: elf64-x86-64.c:3523
- msgid "; recompile with -fPIC"
--msgstr "; recompilé avec -fPIC"
-+msgstr "; recompilez avec -fPIC"
-
- #: elf64-x86-64.c:3528
- msgid "%B: relocation %s against %s `%s' can not be used when making a shared object%s"
diff --git a/debian/patches/infinity-notes.diff b/debian/patches/infinity-notes.diff
new file mode 100644
index 0000000..db213df
--- /dev/null
+++ b/debian/patches/infinity-notes.diff
@@ -0,0 +1,183 @@
+# git clone https://gitlab.com/gbenson/binutils-gdb.git gdb/src
+# git diff 1f1c02597cc199227226251a2ea51fe5f44b4d6d ec7642f5d7ba9bdbc35f08f3ffa3c360bd4618d0
+
+--- a/include/elf/common.h
++++ b/include/elf/common.h
+@@ -717,6 +717,7 @@
+ #define NT_GNU_BUILD_ID 3 /* Generated by ld --build-id. */
+ #define NT_GNU_GOLD_VERSION 4 /* Generated by gold. */
+ #define NT_GNU_PROPERTY_TYPE_0 5 /* Generated by gcc. */
++#define NT_GNU_INFINITY 8995 /* Generated by i8c. */
+
+ #define NT_GNU_BUILD_ATTRIBUTE_OPEN 0x100
+ #define NT_GNU_BUILD_ATTRIBUTE_FUNC 0x101
+--- a/binutils/readelf.c
++++ b/binutils/readelf.c
+@@ -17339,6 +17339,8 @@ get_gnu_elf_note_type (unsigned e_type)
+ return _("NT_GNU_BUILD_ATTRIBUTE_OPEN");
+ case NT_GNU_BUILD_ATTRIBUTE_FUNC:
+ return _("NT_GNU_BUILD_ATTRIBUTE_FUNC");
++ case NT_GNU_INFINITY:
++ return _("NT_GNU_INFINITY (Infinity function)");
+ default:
+ {
+ static char buff[64];
+@@ -17829,6 +17831,133 @@ next:
+ printf ("\n");
+ }
+
++#define I8_CHUNK_SIGNATURE 1
++#define I8_CHUNK_STRINGS 4
++
++typedef enum
++{
++ I8_NOTE_OK,
++ I8_NOTE_CORRUPT,
++ I8_NOTE_UNHANDLED,
++}
++i8_err_e;
++
++static i8_err_e
++infinity_get_string (const char **result,
++ unsigned char **ptr, unsigned char *limit,
++ unsigned char *table_start,
++ unsigned char *table_limit)
++{
++ dwarf_vma offset;
++ unsigned int length;
++ const char *c;
++
++ /* Read the offset. */
++ if (*ptr > limit)
++ return I8_NOTE_CORRUPT;
++
++ offset = read_uleb128 (*ptr, &length, limit);
++ *ptr += length;
++ if (*ptr > limit)
++ return I8_NOTE_CORRUPT;
++
++ /* Get the string. */
++ *result = (const char *) (table_start + offset);
++
++ /* Check the result. */
++ for (c = *result; c < (const char *) table_limit; c++)
++ {
++ if (*c == '\0')
++ return I8_NOTE_OK;
++
++ if (*c < ' ' || *c > '~')
++ return I8_NOTE_UNHANDLED;
++ }
++
++ return I8_NOTE_CORRUPT;
++}
++
++static i8_err_e
++print_infinity_note (Elf_Internal_Note *pnote)
++{
++ unsigned char *ptr = (unsigned char *) pnote->descdata;
++ unsigned char *limit = ptr + pnote->descsz;
++ unsigned char *sig_start = NULL;
++ unsigned char *str_start = NULL;
++ unsigned char *sig_limit, *str_limit;
++ const char *provider, *name, *ptypes, *rtypes;
++ i8_err_e status;
++
++ /* Locate the info and string table chunks. */
++ while (ptr < limit)
++ {
++ dwarf_vma type_id, version, size;
++ unsigned int length;
++
++ type_id = read_uleb128 (ptr, &length, limit);
++ ptr += length;
++ if (ptr >= limit)
++ return I8_NOTE_CORRUPT;
++
++ version = read_uleb128 (ptr, &length, limit);
++ ptr += length;
++ if (ptr >= limit)
++ return I8_NOTE_CORRUPT;
++
++ size = read_uleb128 (ptr, &length, limit);
++ ptr += length;
++ if (ptr + size > limit)
++ return I8_NOTE_CORRUPT;
++
++ switch (type_id)
++ {
++ case I8_CHUNK_SIGNATURE:
++ if (sig_start != NULL || (version != 1 && version != 2))
++ return I8_NOTE_UNHANDLED;
++
++ sig_start = ptr;
++ sig_limit = ptr + size;
++ break;
++
++ case I8_CHUNK_STRINGS:
++ if (str_start != NULL || version != 1)
++ return I8_NOTE_UNHANDLED;
++
++ str_start = ptr;
++ str_limit = ptr + size;
++ break;
++ }
++
++ ptr += size;
++ }
++ if (sig_start == NULL || str_start == NULL)
++ return I8_NOTE_UNHANDLED;
++
++ ptr = sig_start;
++ status = infinity_get_string (&provider,
++ &ptr, sig_limit,
++ str_start, str_limit);
++ if (status != I8_NOTE_OK)
++ return status;
++ status = infinity_get_string (&name, &ptr, sig_limit,
++ str_start, str_limit);
++ if (status != I8_NOTE_OK)
++ return status;
++ status = infinity_get_string (&ptypes, &ptr, sig_limit,
++ str_start, str_limit);
++ if (status != I8_NOTE_OK)
++ return status;
++ status = infinity_get_string (&rtypes, &ptr, sig_limit,
++ str_start, str_limit);
++ if (status != I8_NOTE_OK)
++ return status;
++
++ printf (_(" Signature: %s::%s(%s)%s\n"),
++ provider, name, ptypes, rtypes);
++
++ return I8_NOTE_OK;
++}
++
+ static bfd_boolean
+ print_gnu_note (Filedata * filedata, Elf_Internal_Note *pnote)
+ {
+@@ -17946,6 +18075,24 @@ print_gnu_note (Filedata * filedata, Elf
+ printf ("\n");
+ }
+ break;
++
++ case NT_GNU_INFINITY:
++ {
++ switch (print_infinity_note (pnote))
++ {
++ case I8_NOTE_OK:
++ break;
++
++ case I8_NOTE_CORRUPT:
++ printf (_(" <corrupt note>\n"));
++ break;
++
++ case I8_NOTE_UNHANDLED:
++ printf (_(" <unhandled note>\n"));
++ break;
++ }
++ break;
++ }
+ }
+
+ return TRUE;
diff --git a/debian/patches/ld-new-dtags-by-default.diff b/debian/patches/ld-new-dtags-by-default.diff
deleted file mode 100644
index 3083370..0000000
--- a/debian/patches/ld-new-dtags-by-default.diff
+++ /dev/null
@@ -1,49 +0,0 @@
-# DP: ld: enable new dtags by default for linux/gnu targets
-
-From 9e3072ad67f8b6d092e9e4dbfc6f8c9141aabe0c Mon Sep 17 00:00:00 2001
-From: Mike Frysinger <vapier@gentoo.org>
-Date: Mon, 21 Jan 2013 08:21:45 +0000
-Subject: [PATCH] ld: enable new dtags by default for linux/gnu targets
-
-The "new" dtags options have been around for 14+ years now, so for Linux
-and GNU targets, enable them by default.
-
-2012-01-21 Mike Frysinger <vapier@gentoo.org>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_before_parse): Set
- link_info.new_dtags to TRUE for linux/gnu targets.
- * NEWS: Mention new dtags default.
-
-From 8d0bade12dbc53bfe61a63add17e7780618f1ac1 Mon Sep 17 00:00:00 2001
-From: Roland McGrath <roland@gnu.org>
-Date: Tue, 22 Jan 2013 22:07:34 +0000
-Subject: [PATCH] ld/ * emultempl/elf32.em
- (gld${EMULATION_NAME}_before_parse): Set new_dtags to TRUE for
- *-*-nacl* targets.
-
-2013-01-22 Roland McGrath <mcgrathr@google.com>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_before_parse): Set
- new_dtags to TRUE for *-*-nacl* targets.
-
-Index: b/ld/emultempl/elf32.em
-===================================================================
---- a/ld/emultempl/elf32.em
-+++ b/ld/emultempl/elf32.em
-@@ -106,6 +106,16 @@ gld${EMULATION_NAME}_before_parse (void)
- `if test -n "$CALL_NOP_BYTE" ; then echo link_info.call_nop_byte = $CALL_NOP_BYTE; fi`;
- link_info.check_relocs_after_open_input = `if test "x${CHECK_RELOCS_AFTER_OPEN_INPUT}" = xyes ; then echo TRUE ; else echo FALSE ; fi`;
- link_info.relro = DEFAULT_LD_Z_RELRO;
-+EOF
-+
-+case ${target} in
-+ *-*-linux-* | *-*-k*bsd*-* | *-*-gnu* | *-*-nacl*)
-+ fragment <<EOF
-+ link_info.new_dtags = TRUE;
-+EOF
-+ ;;
-+esac
-+fragment <<EOF
- }
-
- EOF
diff --git a/debian/patches/mips64-default-n64.diff b/debian/patches/mips64-default-n64.diff
index d079f4e..4428b31 100644
--- a/debian/patches/mips64-default-n64.diff
+++ b/debian/patches/mips64-default-n64.diff
@@ -1,8 +1,6 @@
-Index: b/bfd/config.bfd
-===================================================================
--- a/bfd/config.bfd
+++ b/bfd/config.bfd
-@@ -1182,11 +1182,21 @@ case "${targ}" in
+@@ -919,11 +919,21 @@ case "${targ}" in
targ_defvec=mips_elf32_be_vec
targ_selvecs="mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec mips_ecoff_be_vec mips_ecoff_le_vec"
;;
@@ -26,29 +24,23 @@ Index: b/bfd/config.bfd
targ_defvec=mips_elf32_ntrad_be_vec
targ_selvecs="mips_elf32_ntrad_le_vec mips_elf32_trad_be_vec mips_elf32_trad_le_vec mips_elf64_trad_be_vec mips_elf64_trad_le_vec"
;;
-Index: b/gas/configure.ac
-===================================================================
--- a/gas/configure.ac
+++ b/gas/configure.ac
-@@ -345,7 +345,10 @@ changequote([,])dnl
+@@ -377,6 +377,9 @@ changequote([,])dnl
esac
# Decide which ABI to target by default.
case ${target} in
-- mips64*-linux* | mips-sgi-irix6* | mips64*-freebsd* | mips64*-kfreebsd*-gnu)
+ mips*64*-linux-gnuabi64)
+ mips_default_abi=N64_ABI
+ ;;
-+ mips*64*-linux* | mips-sgi-irix6* | mips64*-freebsd* | mips64*-kfreebsd*-gnu)
+ mips64*-linux* | mips-sgi-irix6* | mips64*-freebsd* \
+ | mips64*-kfreebsd*-gnu | mips64*-ps2-elf*)
mips_default_abi=N32_ABI
- ;;
- mips*-linux* | mips*-freebsd* | mips*-kfreebsd*-gnu)
-Index: b/ld/configure.tgt
-===================================================================
--- a/ld/configure.tgt
+++ b/ld/configure.tgt
-@@ -518,10 +518,16 @@ mips*el-*-vxworks*) targ_emul=elf32elmip
+@@ -468,10 +468,16 @@ mips*el-*-vxworks*) targ_emul=elf32elmip
mips*-*-vxworks*) targ_emul=elf32ebmipvxworks
- targ_extra_emuls="elf32elmipvxworks" ;;
+ targ_extra_emuls="elf32elmipvxworks" ;;
mips*-*-windiss) targ_emul=elf32mipswindiss ;;
-mips64*el-*-linux-*) targ_emul=elf32ltsmipn32
+mips*64*el-*-linux-gnuabi64) targ_emul=elf64ltsmip
@@ -65,19 +57,15 @@ Index: b/ld/configure.tgt
targ_extra_emuls="elf32ltsmipn32 elf32btsmip elf32ltsmip elf64btsmip elf64ltsmip"
targ_extra_libpath=$targ_extra_emuls ;;
mips*el-*-linux-*) targ_emul=elf32ltsmip
-Index: b/gas/configure
-===================================================================
--- a/gas/configure
+++ b/gas/configure
-@@ -12380,7 +12380,10 @@ _ACEOF
+@@ -12778,6 +12778,9 @@ _ACEOF
esac
# Decide which ABI to target by default.
case ${target} in
-- mips64*-linux* | mips-sgi-irix6* | mips64*-freebsd* | mips64*-kfreebsd*-gnu)
+ mips*64*-linux-gnuabi64)
+ mips_default_abi=N64_ABI
+ ;;
-+ mips*64*-linux* | mips-sgi-irix6* | mips64*-freebsd* | mips64*-kfreebsd*-gnu)
+ mips64*-linux* | mips-sgi-irix6* | mips64*-freebsd* \
+ | mips64*-kfreebsd*-gnu | mips64*-ps2-elf*)
mips_default_abi=N32_ABI
- ;;
- mips*-linux* | mips*-freebsd* | mips*-kfreebsd*-gnu)
diff --git a/debian/patches/ppc-lib-search-order.diff b/debian/patches/ppc-lib-search-order.diff
deleted file mode 100644
index 8de7c01..0000000
--- a/debian/patches/ppc-lib-search-order.diff
+++ /dev/null
@@ -1,28 +0,0 @@
-# DP: Fix incorrect library search order on PowerPC, taken from the trunk.
-
-ld/
-
-2017-03-13 Alexey Neyman <stilor@att.net>
-
- * emulparams/elf32ppccommon.sh (LIBPATH_SUFFIX): Set from target
- cpu, not host.
-
---- a/ld/emulparams/elf32ppccommon.sh
-+++ b/ld/emulparams/elf32ppccommon.sh
-@@ -44,11 +44,11 @@ fi
-
- # Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first.
- # Similarly, look for 32 bit libraries in /lib32, /usr/lib32 etc.
--case "$host":"$EMULATION_NAME" in
-- *le-*:*64lppc*) LIBPATH_SUFFIX=64 ;;
-- *le-*:*32lppc*) LIBPATH_SUFFIX=32 ;;
-- *le-*:*64*) LIBPATH_SUFFIX=64be ;;
-- *le-*:*32*) LIBPATH_SUFFIX=32be ;;
-+case `echo "$target" | sed -e 's/-.*//'`:"$EMULATION_NAME" in
-+ *le:*64lppc*) LIBPATH_SUFFIX=64 ;;
-+ *le:*32lppc*) LIBPATH_SUFFIX=32 ;;
-+ *le:*64*) LIBPATH_SUFFIX=64be ;;
-+ *le:*32*) LIBPATH_SUFFIX=32be ;;
- *:*64lppc*) LIBPATH_SUFFIX=64le ;;
- *:*32lppc*) LIBPATH_SUFFIX=32le ;;
- *:*64*) LIBPATH_SUFFIX=64 ;;
diff --git a/debian/patches/pr21074-revert.diff b/debian/patches/pr21074-revert.diff
deleted file mode 100644
index a3a9f79..0000000
--- a/debian/patches/pr21074-revert.diff
+++ /dev/null
@@ -1,67 +0,0 @@
-# DP: Revert commit causing PR 21074.
-
-Index: b/gold/output.cc
-===================================================================
---- a/gold/output.cc
-+++ b/gold/output.cc
-@@ -4801,7 +4801,7 @@ Output_segment::first_section() const
- return (*p)->output_section();
- }
- }
-- return NULL;
-+ gold_unreachable();
- }
-
- // Return the number of Output_sections in an Output_segment.
-Index: b/gold/output.h
-===================================================================
---- a/gold/output.h
-+++ b/gold/output.h
-@@ -4741,7 +4741,6 @@ class Output_segment
- first_section_load_address() const
- {
- const Output_section* os = this->first_section();
-- gold_assert(os != NULL);
- return os->has_load_address() ? os->load_address() : os->address();
- }
-
-Index: b/gold/symtab.cc
-===================================================================
---- a/gold/symtab.cc
-+++ b/gold/symtab.cc
-@@ -3159,14 +3159,7 @@ Symbol_table::sized_write_globals(const
- break;
-
- case Symbol::IN_OUTPUT_SEGMENT:
-- {
-- Output_segment* oseg = sym->output_segment();
-- Output_section* osect = oseg->first_section();
-- if (osect == NULL)
-- shndx = elfcpp::SHN_ABS;
-- else
-- shndx = osect->out_shndx();
-- }
-+ shndx = elfcpp::SHN_ABS;
- break;
-
- case Symbol::IS_CONSTANT:
-Index: b/gold/ChangeLog-2016
-===================================================================
---- a/gold/ChangeLog-2016
-+++ b/gold/ChangeLog-2016
-@@ -87,15 +87,6 @@
- * testsuite/Makefile.in: Regenerate.
- * ver_test_8.sh: New test script.
-
--2016-12-21 Cary Coutant <ccoutant@gmail.com>
--
-- * output.cc (Output_segment::first_section): Return NULL if there are
-- no sections in the segment.
-- * output.h (Output_segment::first_section_load_address): Assert that
-- first section is not NULL.
-- * symtab.cc (Symbol_table::sized_write_globals): Attach linker-created
-- segment-relative symbols to first section of the segment.
--
- 2016-12-21 Alan Modra <amodra@gmail.com>
-
- * arm.cc: Fix comment chars with high bit set.
diff --git a/debian/patches/pr21135.diff b/debian/patches/pr21135.diff
deleted file mode 100644
index 88b358b..0000000
--- a/debian/patches/pr21135.diff
+++ /dev/null
@@ -1,106 +0,0 @@
-# DP: Fix PR binutils/21135, invalid read of section contents.
-
-From f055032e4e922f1e1a5e11026c7c2669fa2a7d19 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Mon, 13 Feb 2017 15:04:37 +0000
-Subject: [PATCH] Fix invalid read of section contents whilst processing a
- corrupt binary.
-
- PR binutils/21135
- * readelf.c (dump_section_as_bytes): Handle the case where
- uncompress_section_contents returns false.
- (dump_section_as_bytes, load_specific_debug_section): Likewise.
-
----
- binutils/ChangeLog | 6 ++++++
- binutils/readelf.c | 16 ++++++++++++----
- 2 files changed, 18 insertions(+), 4 deletions(-)
-
-2017-02-13 Nick Clifton <nickc@redhat.com>
-
- PR binutils/21135
- * readelf.c (dump_section_as_bytes): Handle the case where
- uncompress_section_contents returns false.
- (dump_section_as_bytes, load_specific_debug_section): Likewise.
-
-Index: b/binutils/readelf.c
-===================================================================
---- a/binutils/readelf.c
-+++ b/binutils/readelf.c
-@@ -12668,10 +12668,18 @@ dump_section_as_strings (Elf_Internal_Sh
- new_size -= 12;
- }
-
-- if (uncompressed_size
-- && uncompress_section_contents (& start,
-- uncompressed_size, & new_size))
-- num_bytes = new_size;
-+ if (uncompressed_size)
-+ {
-+ if (uncompress_section_contents (& start,
-+ uncompressed_size, & new_size))
-+ num_bytes = new_size;
-+ else
-+ {
-+ error (_("Unable to decompress section %s\n"),
-+ printable_section_name (section));
-+ return;
-+ }
-+ }
- }
-
- /* If the section being dumped has relocations against it the user might
-@@ -12802,10 +12810,18 @@ dump_section_as_bytes (Elf_Internal_Shdr
- new_size -= 12;
- }
-
-- if (uncompressed_size
-- && uncompress_section_contents (& start, uncompressed_size,
-- & new_size))
-- section_size = new_size;
-+ if (uncompressed_size)
-+ {
-+ if (uncompress_section_contents (& start, uncompressed_size,
-+ & new_size))
-+ section_size = new_size;
-+ else
-+ {
-+ error (_("Unable to decompress section %s\n"),
-+ printable_section_name (section));
-+ return;
-+ }
-+ }
- }
-
- if (relocate)
-@@ -12955,14 +12971,22 @@ load_specific_debug_section (enum dwarf_
- size -= 12;
- }
-
-- if (uncompressed_size
-- && uncompress_section_contents (&start, uncompressed_size,
-- &size))
-- {
-- /* Free the compressed buffer, update the section buffer
-- and the section size if uncompress is successful. */
-- free (section->start);
-- section->start = start;
-+ if (uncompressed_size)
-+ {
-+ if (uncompress_section_contents (&start, uncompressed_size,
-+ &size))
-+ {
-+ /* Free the compressed buffer, update the section buffer
-+ and the section size if uncompress is successful. */
-+ free (section->start);
-+ section->start = start;
-+ }
-+ else
-+ {
-+ error (_("Unable to decompress section %s\n"),
-+ printable_section_name (sec));
-+ return 0;
-+ }
- }
- section->size = size;
- }
diff --git a/debian/patches/pr21137.diff b/debian/patches/pr21137.diff
deleted file mode 100644
index b60ffb3..0000000
--- a/debian/patches/pr21137.diff
+++ /dev/null
@@ -1,112 +0,0 @@
-# DP: Fix PR binutils/21137, readelf writing to illegal addresses.
-
-From 03f7786e2f440b9892b1c34a58fb26222ce1b493 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Mon, 13 Feb 2017 13:08:32 +0000
-Subject: [PATCH] Fix readelf writing to illegal addresses whilst processing
- corrupt input files containing symbol-difference relocations.
-
- PR binutils/21137
- * readelf.c (target_specific_reloc_handling): Add end parameter.
- Check for buffer overflow before writing relocated values.
- (apply_relocations): Pass end to target_specific_reloc_handling.
----
- binutils/ChangeLog | 7 +++++++
- binutils/readelf.c | 30 +++++++++++++++++++++++++-----
- 2 files changed, 32 insertions(+), 5 deletions(-)
-
-2017-02-13 Nick Clifton <nickc@redhat.com>
-
- PR binutils/21137
- * readelf.c (target_specific_reloc_handling): Add end parameter.
- Check for buffer overflow before writing relocated values.
- (apply_relocations): Pass end to target_specific_reloc_handling.
-
-diff --git a/binutils/readelf.c b/binutils/readelf.c
-index b488714..e474f27 100644
---- a/binutils/readelf.c
-+++ b/binutils/readelf.c
-@@ -11591,6 +11591,7 @@ process_syminfo (FILE * file ATTRIBUTE_UNUSED)
- static bfd_boolean
- target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- unsigned char * start,
-+ unsigned char * end,
- Elf_Internal_Sym * symtab)
- {
- unsigned int reloc_type = get_reloc_type (reloc->r_info);
-@@ -11631,13 +11632,19 @@ target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- handle_sym_diff:
- if (saved_sym != NULL)
- {
-+ int reloc_size = reloc_type == 1 ? 4 : 2;
- bfd_vma value;
-
- value = reloc->r_addend
- + (symtab[get_reloc_symindex (reloc->r_info)].st_value
- - saved_sym->st_value);
-
-- byte_put (start + reloc->r_offset, value, reloc_type == 1 ? 4 : 2);
-+ if (start + reloc->r_offset + reloc_size >= end)
-+ /* PR 21137 */
-+ error (_("MSP430 sym diff reloc writes past end of section (%p vs %p)\n"),
-+ start + reloc->r_offset + reloc_size, end);
-+ else
-+ byte_put (start + reloc->r_offset, value, reloc_size);
-
- saved_sym = NULL;
- return TRUE;
-@@ -11668,13 +11675,18 @@ target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- case 2: /* R_MN10300_16 */
- if (saved_sym != NULL)
- {
-+ int reloc_size = reloc_type == 1 ? 4 : 2;
- bfd_vma value;
-
- value = reloc->r_addend
- + (symtab[get_reloc_symindex (reloc->r_info)].st_value
- - saved_sym->st_value);
-
-- byte_put (start + reloc->r_offset, value, reloc_type == 1 ? 4 : 2);
-+ if (start + reloc->r_offset + reloc_size >= end)
-+ error (_("MN10300 sym diff reloc writes past end of section (%p vs %p)\n"),
-+ start + reloc->r_offset + reloc_size, end);
-+ else
-+ byte_put (start + reloc->r_offset, value, reloc_size);
-
- saved_sym = NULL;
- return TRUE;
-@@ -11709,12 +11721,20 @@ target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- break;
-
- case 0x41: /* R_RL78_ABS32. */
-- byte_put (start + reloc->r_offset, value, 4);
-+ if (start + reloc->r_offset + 4 >= end)
-+ error (_("RL78 sym diff reloc writes past end of section (%p vs %p)\n"),
-+ start + reloc->r_offset + 2, end);
-+ else
-+ byte_put (start + reloc->r_offset, value, 4);
- value = 0;
- return TRUE;
-
- case 0x43: /* R_RL78_ABS16. */
-- byte_put (start + reloc->r_offset, value, 2);
-+ if (start + reloc->r_offset + 2 >= end)
-+ error (_("RL78 sym diff reloc writes past end of section (%p vs %p)\n"),
-+ start + reloc->r_offset + 2, end);
-+ else
-+ byte_put (start + reloc->r_offset, value, 2);
- value = 0;
- return TRUE;
-
-@@ -12340,7 +12360,7 @@ apply_relocations (void * file,
-
- reloc_type = get_reloc_type (rp->r_info);
-
-- if (target_specific_reloc_handling (rp, start, symtab))
-+ if (target_specific_reloc_handling (rp, start, end, symtab))
- continue;
- else if (is_none_reloc (reloc_type))
- continue;
---
-2.9.3
-
diff --git a/debian/patches/pr21139.diff b/debian/patches/pr21139.diff
deleted file mode 100644
index 0183594..0000000
--- a/debian/patches/pr21139.diff
+++ /dev/null
@@ -1,227 +0,0 @@
-# DP: Fix PR binutils/21139, read-after-free error in readelf.
-
-From f84ce13b6708801ca1d6289b7c4003e2f5a6d7f9 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Mon, 13 Feb 2017 14:03:22 +0000
-Subject: [PATCH] Fix read-after-free error in readelf when processing
- multiple, relocated sections in an MSP430 binary.
-
- PR binutils/21139
- * readelf.c (target_specific_reloc_handling): Add num_syms
- parameter. Check for symbol table overflow before accessing
- symbol value. If reloc pointer is NULL, discard all saved state.
- (apply_relocations): Pass num_syms to target_specific_reloc_handling.
- Call target_specific_reloc_handling with a NULL reloc pointer
- after processing all of the relocs.
----
- binutils/ChangeLog | 10 +++++
- binutils/readelf.c | 109 +++++++++++++++++++++++++++++++++++++++++------------
- 2 files changed, 94 insertions(+), 25 deletions(-)
-
-2017-02-13 Nick Clifton <nickc@redhat.com>
-
- PR binutils/21139
- * readelf.c (target_specific_reloc_handling): Add num_syms
- parameter. Check for symbol table overflow before accessing
- symbol value. If reloc pointer is NULL, discard all saved state.
- (apply_relocations): Pass num_syms to target_specific_reloc_handling.
- Call target_specific_reloc_handling with a NULL reloc pointer
- after processing all of the relocs.
-
-diff --git a/binutils/readelf.c b/binutils/readelf.c
-index e474f27..de961c4 100644
---- a/binutils/readelf.c
-+++ b/binutils/readelf.c
-@@ -11586,15 +11586,27 @@ process_syminfo (FILE * file ATTRIBUTE_UNUSED)
-
- /* Check to see if the given reloc needs to be handled in a target specific
- manner. If so then process the reloc and return TRUE otherwise return
-- FALSE. */
-+ FALSE.
-+
-+ If called with reloc == NULL, then this is a signal that reloc processing
-+ for the current section has finished, and any saved state should be
-+ discarded. */
-
- static bfd_boolean
- target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- unsigned char * start,
- unsigned char * end,
-- Elf_Internal_Sym * symtab)
-+ Elf_Internal_Sym * symtab,
-+ unsigned long num_syms)
- {
-- unsigned int reloc_type = get_reloc_type (reloc->r_info);
-+ unsigned int reloc_type = 0;
-+ unsigned long sym_index = 0;
-+
-+ if (reloc)
-+ {
-+ reloc_type = get_reloc_type (reloc->r_info);
-+ sym_index = get_reloc_symindex (reloc->r_info);
-+ }
-
- switch (elf_header.e_machine)
- {
-@@ -11603,6 +11615,12 @@ target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- {
- static Elf_Internal_Sym * saved_sym = NULL;
-
-+ if (reloc == NULL)
-+ {
-+ saved_sym = NULL;
-+ return TRUE;
-+ }
-+
- switch (reloc_type)
- {
- case 10: /* R_MSP430_SYM_DIFF */
-@@ -11610,7 +11628,12 @@ target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- break;
- /* Fall through. */
- case 21: /* R_MSP430X_SYM_DIFF */
-- saved_sym = symtab + get_reloc_symindex (reloc->r_info);
-+ /* PR 21139. */
-+ if (sym_index >= num_syms)
-+ error (_("MSP430 SYM_DIFF reloc contains invalid symbol index %lu\n"),
-+ sym_index);
-+ else
-+ saved_sym = symtab + sym_index;
- return TRUE;
-
- case 1: /* R_MSP430_32 or R_MSP430_ABS32 */
-@@ -11635,16 +11658,21 @@ target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- int reloc_size = reloc_type == 1 ? 4 : 2;
- bfd_vma value;
-
-- value = reloc->r_addend
-- + (symtab[get_reloc_symindex (reloc->r_info)].st_value
-- - saved_sym->st_value);
--
-- if (start + reloc->r_offset + reloc_size >= end)
-- /* PR 21137 */
-- error (_("MSP430 sym diff reloc writes past end of section (%p vs %p)\n"),
-- start + reloc->r_offset + reloc_size, end);
-+ if (sym_index >= num_syms)
-+ error (_("MSP430 reloc contains invalid symbol index %lu\n"),
-+ sym_index);
- else
-- byte_put (start + reloc->r_offset, value, reloc_size);
-+ {
-+ value = reloc->r_addend + (symtab[sym_index].st_value
-+ - saved_sym->st_value);
-+
-+ if (start + reloc->r_offset + reloc_size >= end)
-+ /* PR 21137 */
-+ error (_("MSP430 sym diff reloc writes past end of section (%p vs %p)\n"),
-+ start + reloc->r_offset + reloc_size, end);
-+ else
-+ byte_put (start + reloc->r_offset, value, reloc_size);
-+ }
-
- saved_sym = NULL;
- return TRUE;
-@@ -11664,13 +11692,24 @@ target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- {
- static Elf_Internal_Sym * saved_sym = NULL;
-
-+ if (reloc == NULL)
-+ {
-+ saved_sym = NULL;
-+ return TRUE;
-+ }
-+
- switch (reloc_type)
- {
- case 34: /* R_MN10300_ALIGN */
- return TRUE;
- case 33: /* R_MN10300_SYM_DIFF */
-- saved_sym = symtab + get_reloc_symindex (reloc->r_info);
-+ if (sym_index >= num_syms)
-+ error (_("MN10300_SYM_DIFF reloc contains invalid symbol index %lu\n"),
-+ sym_index);
-+ else
-+ saved_sym = symtab + sym_index;
- return TRUE;
-+
- case 1: /* R_MN10300_32 */
- case 2: /* R_MN10300_16 */
- if (saved_sym != NULL)
-@@ -11678,15 +11717,20 @@ target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- int reloc_size = reloc_type == 1 ? 4 : 2;
- bfd_vma value;
-
-- value = reloc->r_addend
-- + (symtab[get_reloc_symindex (reloc->r_info)].st_value
-- - saved_sym->st_value);
--
-- if (start + reloc->r_offset + reloc_size >= end)
-- error (_("MN10300 sym diff reloc writes past end of section (%p vs %p)\n"),
-- start + reloc->r_offset + reloc_size, end);
-+ if (sym_index >= num_syms)
-+ error (_("MN10300 reloc contains invalid symbol index %lu\n"),
-+ sym_index);
- else
-- byte_put (start + reloc->r_offset, value, reloc_size);
-+ {
-+ value = reloc->r_addend + (symtab[sym_index].st_value
-+ - saved_sym->st_value);
-+
-+ if (start + reloc->r_offset + reloc_size >= end)
-+ error (_("MN10300 sym diff reloc writes past end of section (%p vs %p)\n"),
-+ start + reloc->r_offset + reloc_size, end);
-+ else
-+ byte_put (start + reloc->r_offset, value, reloc_size);
-+ }
-
- saved_sym = NULL;
- return TRUE;
-@@ -11706,12 +11750,24 @@ target_specific_reloc_handling (Elf_Internal_Rela * reloc,
- static bfd_vma saved_sym2 = 0;
- static bfd_vma value;
-
-+ if (reloc == NULL)
-+ {
-+ saved_sym1 = saved_sym2 = 0;
-+ return TRUE;
-+ }
-+
- switch (reloc_type)
- {
- case 0x80: /* R_RL78_SYM. */
- saved_sym1 = saved_sym2;
-- saved_sym2 = symtab[get_reloc_symindex (reloc->r_info)].st_value;
-- saved_sym2 += reloc->r_addend;
-+ if (sym_index >= num_syms)
-+ error (_("RL78_SYM reloc contains invalid symbol index %lu\n"),
-+ sym_index);
-+ else
-+ {
-+ saved_sym2 = symtab[sym_index].st_value;
-+ saved_sym2 += reloc->r_addend;
-+ }
- return TRUE;
-
- case 0x83: /* R_RL78_OPsub. */
-@@ -12360,7 +12416,7 @@ apply_relocations (void * file,
-
- reloc_type = get_reloc_type (rp->r_info);
-
-- if (target_specific_reloc_handling (rp, start, end, symtab))
-+ if (target_specific_reloc_handling (rp, start, end, symtab, num_syms))
- continue;
- else if (is_none_reloc (reloc_type))
- continue;
-@@ -12456,6 +12512,9 @@ apply_relocations (void * file,
- }
-
- free (symtab);
-+ /* Let the target specific reloc processing code know that
-+ we have finished with these relocs. */
-+ target_specific_reloc_handling (NULL, NULL, NULL, NULL, 0);
-
- if (relocs_return)
- {
---
-2.9.3
-
diff --git a/debian/patches/pr21156.diff b/debian/patches/pr21156.diff
deleted file mode 100644
index 90e33d3..0000000
--- a/debian/patches/pr21156.diff
+++ /dev/null
@@ -1,156 +0,0 @@
-# DP: Fix PR binutils/21156, illegal memory accesses in readelf.
-
-From b814a36d3440de95f2ac6eaa4fc7935c322ea456 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Fri, 17 Feb 2017 15:59:45 +0000
-Subject: [PATCH] Fix illegal memory accesses in readelf when parsing a corrupt
- binary.
-
- PR binutils/21156
- * readelf.c (find_section_in_set): Test for invalid section
- indicies.
----
- binutils/ChangeLog | 6 ++++++
- binutils/readelf.c | 10 ++++++++--
- 2 files changed, 14 insertions(+), 2 deletions(-)
-
-2017-02-17 Nick Clifton <nickc@redhat.com>
-
- PR binutils/21156
- * readelf.c (find_section_in_set): Test for invalid section
- indicies.
-
-diff --git a/binutils/readelf.c b/binutils/readelf.c
-index ea9da7a..20df6f8 100644
---- a/binutils/readelf.c
-+++ b/binutils/readelf.c
-@@ -676,8 +676,14 @@ find_section_in_set (const char * name, unsigned int * set)
- if (set != NULL)
- {
- while ((i = *set++) > 0)
-- if (streq (SECTION_NAME (section_headers + i), name))
-- return section_headers + i;
-+ {
-+ /* See PR 21156 for a reproducer. */
-+ if (i >= elf_header.e_shnum)
-+ continue; /* FIXME: Should we issue an error message ? */
-+
-+ if (streq (SECTION_NAME (section_headers + i), name))
-+ return section_headers + i;
-+ }
- }
-
- return find_section (name);
---
-2.9.3
-
-From 43a444f9c5bfd44b4304eafd78338e21d54bea14 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Mon, 20 Feb 2017 14:40:39 +0000
-Subject: [PATCH] Fix another memory access error in readelf when parsing a
- corrupt binary.
-
- PR binutils/21156
- * dwarf.c (cu_tu_indexes_read): Move into...
- (load_cu_tu_indexes): ... here. Change the variable into
- tri-state. Change the function into boolean, returning
- false if the indicies could not be loaded.
- (find_cu_tu_set): Return NULL if the indicies could not be
- loaded.
----
- binutils/ChangeLog | 10 ++++++++++
- binutils/dwarf.c | 34 ++++++++++++++++++++--------------
- 2 files changed, 30 insertions(+), 14 deletions(-)
-
-2017-02-20 Nick Clifton <nickc@redhat.com>
-
- PR binutils/21156
- * dwarf.c (cu_tu_indexes_read): Move into...
- (load_cu_tu_indexes): ... here. Change the variable into
- tri-state. Change the function into boolean, returning
- false if the indicies could not be loaded.
- (find_cu_tu_set): Return NULL if the indicies could not be
- loaded.
-
-
-diff --git a/binutils/dwarf.c b/binutils/dwarf.c
-index 0184a7a..6d879c9 100644
---- a/binutils/dwarf.c
-+++ b/binutils/dwarf.c
-@@ -76,7 +76,6 @@ int dwarf_check = 0;
- as a zero-terminated list of section indexes comprising one set of debug
- sections from a .dwo file. */
-
--static int cu_tu_indexes_read = 0;
- static unsigned int *shndx_pool = NULL;
- static unsigned int shndx_pool_size = 0;
- static unsigned int shndx_pool_used = 0;
-@@ -99,7 +98,7 @@ static int tu_count = 0;
- static struct cu_tu_set *cu_sets = NULL;
- static struct cu_tu_set *tu_sets = NULL;
-
--static void load_cu_tu_indexes (void *file);
-+static bfd_boolean load_cu_tu_indexes (void *);
-
- /* Values for do_debug_lines. */
- #define FLAG_DEBUG_LINES_RAW 1
-@@ -2715,7 +2714,7 @@ load_debug_info (void * file)
- return num_debug_info_entries;
-
- /* If this is a DWARF package file, load the CU and TU indexes. */
-- load_cu_tu_indexes (file);
-+ (void) load_cu_tu_indexes (file);
-
- if (load_debug_section (info, file)
- && process_debug_info (&debug_displays [info].section, file, abbrev, 1, 0))
-@@ -7378,21 +7377,27 @@ process_cu_tu_index (struct dwarf_section *section, int do_display)
- section sets that we can use to associate a .debug_info.dwo section
- with its associated .debug_abbrev.dwo section in a .dwp file. */
-
--static void
-+static bfd_boolean
- load_cu_tu_indexes (void *file)
- {
-+ static int cu_tu_indexes_read = -1; /* Tri-state variable. */
-+
- /* If we have already loaded (or tried to load) the CU and TU indexes
- then do not bother to repeat the task. */
-- if (cu_tu_indexes_read)
-- return;
--
-- if (load_debug_section (dwp_cu_index, file))
-- process_cu_tu_index (&debug_displays [dwp_cu_index].section, 0);
--
-- if (load_debug_section (dwp_tu_index, file))
-- process_cu_tu_index (&debug_displays [dwp_tu_index].section, 0);
-+ if (cu_tu_indexes_read == -1)
-+ {
-+ cu_tu_indexes_read = TRUE;
-+
-+ if (load_debug_section (dwp_cu_index, file))
-+ if (! process_cu_tu_index (&debug_displays [dwp_cu_index].section, 0))
-+ cu_tu_indexes_read = FALSE;
-+
-+ if (load_debug_section (dwp_tu_index, file))
-+ if (! process_cu_tu_index (&debug_displays [dwp_tu_index].section, 0))
-+ cu_tu_indexes_read = FALSE;
-+ }
-
-- cu_tu_indexes_read = 1;
-+ return (bfd_boolean) cu_tu_indexes_read;
- }
-
- /* Find the set of sections that includes section SHNDX. */
-@@ -7402,7 +7407,8 @@ find_cu_tu_set (void *file, unsigned int shndx)
- {
- unsigned int i;
-
-- load_cu_tu_indexes (file);
-+ if (! load_cu_tu_indexes (file))
-+ return NULL;
-
- /* Find SHNDX in the shndx pool. */
- for (i = 0; i < shndx_pool_used; i++)
---
-2.9.3
-
diff --git a/debian/patches/pr21157.diff b/debian/patches/pr21157.diff
deleted file mode 100644
index a592fc9..0000000
--- a/debian/patches/pr21157.diff
+++ /dev/null
@@ -1,60 +0,0 @@
-# DP: Fix PR binutils/21157, handling of corrupt STABS enum type strings.
-
-From a2dea0b20bc66a4c287c3c50002b8c3b3e9d953a Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Tue, 14 Feb 2017 14:07:29 +0000
-Subject: [PATCH] Fix handling of corrupt STABS enum type strings.
-
- PR binutils/21157
- * stabs.c (parse_stab_enum_type): Check for corrupt NAME:VALUE
- pairs.
- (parse_number): Exit early if passed an empty string.
----
- binutils/ChangeLog | 7 +++++++
- binutils/stabs.c | 14 +++++++++++++-
- 2 files changed, 20 insertions(+), 1 deletion(-)
-
-2017-02-14 Nick Clifton <nickc@redhat.com>
-
- PR binutils/21157
- * stabs.c (parse_stab_enum_type): Check for corrupt NAME:VALUE
- pairs.
- (parse_number): Exit early if passed an empty string.
-
-diff --git a/binutils/stabs.c b/binutils/stabs.c
-index d3fc4af..3861f83 100644
---- a/binutils/stabs.c
-+++ b/binutils/stabs.c
-@@ -232,6 +232,10 @@ parse_number (const char **pp, bfd_boolean *poverflow)
-
- orig = *pp;
-
-+ /* Stop early if we are passed an empty string. */
-+ if (*orig == 0)
-+ return (bfd_vma) 0;
-+
- errno = 0;
- ul = strtoul (*pp, (char **) pp, 0);
- if (ul + 1 != 0 || errno == 0)
-@@ -1975,9 +1979,17 @@ parse_stab_enum_type (void *dhandle, const char **pp)
- bfd_signed_vma val;
-
- p = *pp;
-- while (*p != ':')
-+ while (*p != ':' && *p != 0)
- ++p;
-
-+ if (*p == 0)
-+ {
-+ bad_stab (orig);
-+ free (names);
-+ free (values);
-+ return DEBUG_TYPE_NULL;
-+ }
-+
- name = savestring (*pp, p - *pp);
-
- *pp = p + 1;
---
-2.9.3
-
diff --git a/debian/patches/pr21342.diff b/debian/patches/pr21342.diff
deleted file mode 100644
index 3c58ed5..0000000
--- a/debian/patches/pr21342.diff
+++ /dev/null
@@ -1,99 +0,0 @@
-# DP: Fix PR binutils/21342, null pointer dereferences when using a link built
-# DP: with clang.
-
-From ad32986fdf9da1c8748e47b8b45100398223dba8 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Tue, 4 Apr 2017 11:23:36 +0100
-Subject: [PATCH] Fix null pointer dereferences when using a link built with
- clang.
-
- PR binutils/21342
- * elflink.c (_bfd_elf_define_linkage_sym): Prevent null pointer
- dereference.
- (bfd_elf_final_link): Only initialize the extended symbol index
- section if there are extended symbol tables to list.
----
- bfd/ChangeLog | 8 ++++++++
- bfd/elflink.c | 35 +++++++++++++++++++++--------------
- 2 files changed, 29 insertions(+), 14 deletions(-)
-
-bfd/
-
-2017-04-04 Nick Clifton <nickc@redhat.com>
-
- PR binutils/21342
- * elflink.c (_bfd_elf_define_linkage_sym): Prevent null pointer
- dereference.
- (bfd_elf_final_link): Only initialize the extended symbol index
- section if there are extended symbol tables to list.
-
-
-diff --git a/bfd/elflink.c b/bfd/elflink.c
-index 776357f..9bf75c8 100644
---- a/bfd/elflink.c
-+++ b/bfd/elflink.c
-@@ -119,15 +119,18 @@ _bfd_elf_define_linkage_sym (bfd *abfd,
- defined in shared libraries can't be overridden, because we
- lose the link to the bfd which is via the symbol section. */
- h->root.type = bfd_link_hash_new;
-+ bh = &h->root;
- }
-+ else
-+ bh = NULL;
-
-- bh = &h->root;
- bed = get_elf_backend_data (abfd);
- if (!_bfd_generic_link_add_one_symbol (info, abfd, name, BSF_GLOBAL,
- sec, 0, NULL, FALSE, bed->collect,
- &bh))
- return NULL;
- h = (struct elf_link_hash_entry *) bh;
-+ BFD_ASSERT (h != NULL);
- h->def_regular = 1;
- h->non_elf = 0;
- h->root.linker_def = 1;
-@@ -12038,24 +12041,28 @@ bfd_elf_final_link (bfd *abfd, struct bfd_link_info *info)
- {
- /* Finish up and write out the symbol string table (.strtab)
- section. */
-- Elf_Internal_Shdr *symstrtab_hdr;
-+ Elf_Internal_Shdr *symstrtab_hdr = NULL;
- file_ptr off = symtab_hdr->sh_offset + symtab_hdr->sh_size;
-
-- symtab_shndx_hdr = & elf_symtab_shndx_list (abfd)->hdr;
-- if (symtab_shndx_hdr != NULL && symtab_shndx_hdr->sh_name != 0)
-+ if (elf_symtab_shndx_list (abfd))
- {
-- symtab_shndx_hdr->sh_type = SHT_SYMTAB_SHNDX;
-- symtab_shndx_hdr->sh_entsize = sizeof (Elf_External_Sym_Shndx);
-- symtab_shndx_hdr->sh_addralign = sizeof (Elf_External_Sym_Shndx);
-- amt = bfd_get_symcount (abfd) * sizeof (Elf_External_Sym_Shndx);
-- symtab_shndx_hdr->sh_size = amt;
-+ symtab_shndx_hdr = & elf_symtab_shndx_list (abfd)->hdr;
-
-- off = _bfd_elf_assign_file_position_for_section (symtab_shndx_hdr,
-- off, TRUE);
-+ if (symtab_shndx_hdr != NULL && symtab_shndx_hdr->sh_name != 0)
-+ {
-+ symtab_shndx_hdr->sh_type = SHT_SYMTAB_SHNDX;
-+ symtab_shndx_hdr->sh_entsize = sizeof (Elf_External_Sym_Shndx);
-+ symtab_shndx_hdr->sh_addralign = sizeof (Elf_External_Sym_Shndx);
-+ amt = bfd_get_symcount (abfd) * sizeof (Elf_External_Sym_Shndx);
-+ symtab_shndx_hdr->sh_size = amt;
-
-- if (bfd_seek (abfd, symtab_shndx_hdr->sh_offset, SEEK_SET) != 0
-- || (bfd_bwrite (flinfo.symshndxbuf, amt, abfd) != amt))
-- return FALSE;
-+ off = _bfd_elf_assign_file_position_for_section (symtab_shndx_hdr,
-+ off, TRUE);
-+
-+ if (bfd_seek (abfd, symtab_shndx_hdr->sh_offset, SEEK_SET) != 0
-+ || (bfd_bwrite (flinfo.symshndxbuf, amt, abfd) != amt))
-+ return FALSE;
-+ }
- }
-
- symstrtab_hdr = &elf_tdata (abfd)->strtab_hdr;
---
-2.9.3
-
diff --git a/debian/patches/pr21412.diff b/debian/patches/pr21412.diff
deleted file mode 100644
index c22e327..0000000
--- a/debian/patches/pr21412.diff
+++ /dev/null
@@ -1,180 +0,0 @@
-From bce964aa6c777d236fbd641f2bc7bb931cfe4bf3 Mon Sep 17 00:00:00 2001
-From: Alan Modra <amodra@gmail.com>
-Date: Sun, 23 Apr 2017 11:03:34 +0930
-Subject: [PATCH] PR 21412, get_reloc_section assumes .rel/.rela name for
- SHT_REL/RELA.
-
-This patch fixes an assumption made by code that runs for objcopy and
-strip, that SHT_REL/SHR_RELA sections are always named starting with a
-.rel/.rela prefix. I'm also modifying the interface for
-elf_backend_get_reloc_section, so any backend function just needs to
-handle name mapping.
-
- PR 21412
- * elf-bfd.h (struct elf_backend_data <get_reloc_section>): Change
- parameters and comment.
- (_bfd_elf_get_reloc_section): Delete.
- (_bfd_elf_plt_get_reloc_section): Declare.
- * elf.c (_bfd_elf_plt_get_reloc_section, elf_get_reloc_section):
- New functions. Don't blindly skip over assumed .rel/.rela prefix.
- Extracted from..
- (_bfd_elf_get_reloc_section): ..here. Delete.
- (assign_section_numbers): Call elf_get_reloc_section.
- * elf64-ppc.c (elf_backend_get_reloc_section): Define.
- * elfxx-target.h (elf_backend_get_reloc_section): Update.
----
- bfd/ChangeLog | 15 ++++++++++++++
- bfd/elf-bfd.h | 8 ++++---
- bfd/elf.c | 61 +++++++++++++++++++++++++++++++-----------------------
- bfd/elf64-ppc.c | 1 +
- bfd/elfxx-target.h | 2 +-
- 5 files changed, 57 insertions(+), 30 deletions(-)
-
-diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h
-index af377ee..4c0c9e8 100644
---- a/bfd/elf-bfd.h
-+++ b/bfd/elf-bfd.h
-@@ -1360,8 +1360,10 @@ struct elf_backend_data
- bfd_size_type (*maybe_function_sym) (const asymbol *sym, asection *sec,
- bfd_vma *code_off);
-
-- /* Return the section which RELOC_SEC applies to. */
-- asection *(*get_reloc_section) (asection *reloc_sec);
-+ /* Given NAME, the name of a relocation section stripped of its
-+ .rel/.rela prefix, return the section in ABFD to which the
-+ relocations apply. */
-+ asection *(*get_reloc_section) (bfd *abfd, const char *name);
-
- /* Called to set the sh_flags, sh_link and sh_info fields of OSECTION which
- has a type >= SHT_LOOS. Returns TRUE if the fields were initialised,
-@@ -2448,7 +2450,7 @@ extern bfd_boolean _bfd_elf_is_function_type (unsigned int);
- extern bfd_size_type _bfd_elf_maybe_function_sym (const asymbol *, asection *,
- bfd_vma *);
-
--extern asection *_bfd_elf_get_reloc_section (asection *);
-+extern asection *_bfd_elf_plt_get_reloc_section (bfd *, const char *);
-
- extern int bfd_elf_get_default_section_type (flagword);
-
-diff --git a/bfd/elf.c b/bfd/elf.c
-index 18b4bbe..dd1a41f 100644
---- a/bfd/elf.c
-+++ b/bfd/elf.c
-@@ -3538,17 +3538,39 @@ bfd_elf_set_group_contents (bfd *abfd, asection *sec, void *failedptrarg)
- H_PUT_32 (abfd, sec->flags & SEC_LINK_ONCE ? GRP_COMDAT : 0, loc);
- }
-
--/* Return the section which RELOC_SEC applies to. */
-+/* Given NAME, the name of a relocation section stripped of its
-+ .rel/.rela prefix, return the section in ABFD to which the
-+ relocations apply. */
-
- asection *
--_bfd_elf_get_reloc_section (asection *reloc_sec)
-+_bfd_elf_plt_get_reloc_section (bfd *abfd, const char *name)
-+{
-+ /* If a target needs .got.plt section, relocations in rela.plt/rel.plt
-+ section likely apply to .got.plt or .got section. */
-+ if (get_elf_backend_data (abfd)->want_got_plt
-+ && strcmp (name, ".plt") == 0)
-+ {
-+ asection *sec;
-+
-+ name = ".got.plt";
-+ sec = bfd_get_section_by_name (abfd, name);
-+ if (sec != NULL)
-+ return sec;
-+ name = ".got";
-+ }
-+
-+ return bfd_get_section_by_name (abfd, name);
-+}
-+
-+/* Return the section to which RELOC_SEC applies. */
-+
-+static asection *
-+elf_get_reloc_section (asection *reloc_sec)
- {
- const char *name;
- unsigned int type;
- bfd *abfd;
--
-- if (reloc_sec == NULL)
-- return NULL;
-+ const struct elf_backend_data *bed;
-
- type = elf_section_data (reloc_sec)->this_hdr.sh_type;
- if (type != SHT_REL && type != SHT_RELA)
-@@ -3556,28 +3578,15 @@ _bfd_elf_get_reloc_section (asection *reloc_sec)
-
- /* We look up the section the relocs apply to by name. */
- name = reloc_sec->name;
-- if (type == SHT_REL)
-- name += 4;
-- else
-- name += 5;
-+ if (strncmp (name, ".rel", 4) != 0)
-+ return NULL;
-+ name += 4;
-+ if (type == SHT_RELA && *name++ != 'a')
-+ return NULL;
-
-- /* If a target needs .got.plt section, relocations in rela.plt/rel.plt
-- section apply to .got.plt section. */
- abfd = reloc_sec->owner;
-- if (get_elf_backend_data (abfd)->want_got_plt
-- && strcmp (name, ".plt") == 0)
-- {
-- /* .got.plt is a linker created input section. It may be mapped
-- to some other output section. Try two likely sections. */
-- name = ".got.plt";
-- reloc_sec = bfd_get_section_by_name (abfd, name);
-- if (reloc_sec != NULL)
-- return reloc_sec;
-- name = ".got";
-- }
--
-- reloc_sec = bfd_get_section_by_name (abfd, name);
-- return reloc_sec;
-+ bed = get_elf_backend_data (abfd);
-+ return bed->get_reloc_section (abfd, name);
- }
-
- /* Assign all ELF section numbers. The dummy first section is handled here
-@@ -3841,7 +3850,7 @@ assign_section_numbers (bfd *abfd, struct bfd_link_info *link_info)
- if (s != NULL)
- d->this_hdr.sh_link = elf_section_data (s)->this_idx;
-
-- s = get_elf_backend_data (abfd)->get_reloc_section (sec);
-+ s = elf_get_reloc_section (sec);
- if (s != NULL)
- {
- d->this_hdr.sh_info = elf_section_data (s)->this_idx;
-diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c
-index fc69964..2e8f338 100644
---- a/bfd/elf64-ppc.c
-+++ b/bfd/elf64-ppc.c
-@@ -121,6 +121,7 @@ static bfd_vma opd_entry_value
- #define elf_backend_special_sections ppc64_elf_special_sections
- #define elf_backend_merge_symbol_attribute ppc64_elf_merge_symbol_attribute
- #define elf_backend_merge_symbol ppc64_elf_merge_symbol
-+#define elf_backend_get_reloc_section bfd_get_section_by_name
-
- /* The name of the dynamic interpreter. This is put in the .interp
- section. */
-diff --git a/bfd/elfxx-target.h b/bfd/elfxx-target.h
-index 6cc9f3f..2551267 100644
---- a/bfd/elfxx-target.h
-+++ b/bfd/elfxx-target.h
-@@ -715,7 +715,7 @@
- #endif
-
- #ifndef elf_backend_get_reloc_section
--#define elf_backend_get_reloc_section _bfd_elf_get_reloc_section
-+#define elf_backend_get_reloc_section _bfd_elf_plt_get_reloc_section
- #endif
-
- #ifndef elf_backend_copy_special_section_fields
---
-2.9.3
-
diff --git a/debian/patches/pr21414.diff b/debian/patches/pr21414.diff
deleted file mode 100644
index c49baec..0000000
--- a/debian/patches/pr21414.diff
+++ /dev/null
@@ -1,99 +0,0 @@
-From 7eacd66b086cabb1daab20890d5481894d4f56b2 Mon Sep 17 00:00:00 2001
-From: Alan Modra <amodra@gmail.com>
-Date: Sun, 23 Apr 2017 15:21:11 +0930
-Subject: [PATCH] PR 21414, null pointer deref of _bfd_elf_large_com_section
- sym
-
- PR 21414
- * section.c (GLOBAL_SYM_INIT): Make available in bfd.h.
- * elf.c (lcomm_sym): New.
- (_bfd_elf_large_com_section): Use lcomm_sym section symbol.
- * bfd-in2.h: Regenerate.
----
- bfd/ChangeLog | 8 ++++++++
- bfd/bfd-in2.h | 12 ++++++++++++
- bfd/elf.c | 6 ++++--
- bfd/section.c | 24 ++++++++++++------------
- 4 files changed, 36 insertions(+), 14 deletions(-)
-
-diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h
-index 1d73134..17a35c0 100644
---- a/bfd/bfd-in2.h
-+++ b/bfd/bfd-in2.h
-@@ -1839,6 +1839,18 @@ extern asection _bfd_std_section[4];
- { NULL }, { NULL } \
- }
-
-+/* We use a macro to initialize the static asymbol structures because
-+ traditional C does not permit us to initialize a union member while
-+ gcc warns if we don't initialize it.
-+ the_bfd, name, value, attr, section [, udata] */
-+#ifdef __STDC__
-+#define GLOBAL_SYM_INIT(NAME, SECTION) \
-+ { 0, NAME, 0, BSF_SECTION_SYM, SECTION, { 0 }}
-+#else
-+#define GLOBAL_SYM_INIT(NAME, SECTION) \
-+ { 0, NAME, 0, BSF_SECTION_SYM, SECTION }
-+#endif
-+
- void bfd_section_list_clear (bfd *);
-
- asection *bfd_get_section_by_name (bfd *abfd, const char *name);
-diff --git a/bfd/elf.c b/bfd/elf.c
-index dd1a41f..a08e0f8 100644
---- a/bfd/elf.c
-+++ b/bfd/elf.c
-@@ -11244,9 +11244,11 @@ _bfd_elf_get_synthetic_symtab (bfd *abfd,
-
- /* It is only used by x86-64 so far.
- ??? This repeats *COM* id of zero. sec->id is supposed to be unique,
-- but current usage would allow all of _bfd_std_section to be zero. t*/
-+ but current usage would allow all of _bfd_std_section to be zero. */
-+static const asymbol lcomm_sym
-+ = GLOBAL_SYM_INIT ("LARGE_COMMON", &_bfd_elf_large_com_section);
- asection _bfd_elf_large_com_section
-- = BFD_FAKE_SECTION (_bfd_elf_large_com_section, NULL,
-+ = BFD_FAKE_SECTION (_bfd_elf_large_com_section, &lcomm_sym,
- "LARGE_COMMON", 0, SEC_IS_COMMON);
-
- void
-diff --git a/bfd/section.c b/bfd/section.c
-index 4b3cf6a..28eee7f 100644
---- a/bfd/section.c
-+++ b/bfd/section.c
-@@ -738,20 +738,20 @@ CODE_FRAGMENT
- . { NULL }, { NULL } \
- . }
- .
-+.{* We use a macro to initialize the static asymbol structures because
-+. traditional C does not permit us to initialize a union member while
-+. gcc warns if we don't initialize it.
-+. the_bfd, name, value, attr, section [, udata] *}
-+.#ifdef __STDC__
-+.#define GLOBAL_SYM_INIT(NAME, SECTION) \
-+. { 0, NAME, 0, BSF_SECTION_SYM, SECTION, { 0 }}
-+.#else
-+.#define GLOBAL_SYM_INIT(NAME, SECTION) \
-+. { 0, NAME, 0, BSF_SECTION_SYM, SECTION }
-+.#endif
-+.
- */
-
--/* We use a macro to initialize the static asymbol structures because
-- traditional C does not permit us to initialize a union member while
-- gcc warns if we don't initialize it. */
-- /* the_bfd, name, value, attr, section [, udata] */
--#ifdef __STDC__
--#define GLOBAL_SYM_INIT(NAME, SECTION) \
-- { 0, NAME, 0, BSF_SECTION_SYM, SECTION, { 0 }}
--#else
--#define GLOBAL_SYM_INIT(NAME, SECTION) \
-- { 0, NAME, 0, BSF_SECTION_SYM, SECTION }
--#endif
--
- /* These symbols are global, not specific to any BFD. Therefore, anything
- that tries to change them is broken, and should be repaired. */
-
---
-2.9.3
-
diff --git a/debian/patches/pr21431.diff b/debian/patches/pr21431.diff
deleted file mode 100644
index 52159fc..0000000
--- a/debian/patches/pr21431.diff
+++ /dev/null
@@ -1,57 +0,0 @@
-From e63d123268f23a4cbc45ee55fb6dbc7d84729da3 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Wed, 26 Apr 2017 13:07:49 +0100
-Subject: [PATCH] Fix seg-fault attempting to compress a debug section in a
- corrupt binary.
-
- PR binutils/21431
- * compress.c (bfd_init_section_compress_status): Check the return
- value from bfd_malloc.
----
- bfd/ChangeLog | 6 ++++++
- bfd/compress.c | 19 +++++++++----------
- 2 files changed, 15 insertions(+), 10 deletions(-)
-
-diff --git a/bfd/compress.c b/bfd/compress.c
-index f881c07..c854a20 100644
---- a/bfd/compress.c
-+++ b/bfd/compress.c
-@@ -542,7 +542,6 @@ bfd_init_section_compress_status (bfd *abfd, sec_ptr sec)
- {
- bfd_size_type uncompressed_size;
- bfd_byte *uncompressed_buffer;
-- bfd_boolean ret;
-
- /* Error if not opened for read. */
- if (abfd->direction != read_direction
-@@ -558,18 +557,18 @@ bfd_init_section_compress_status (bfd *abfd, sec_ptr sec)
- /* Read in the full section contents and compress it. */
- uncompressed_size = sec->size;
- uncompressed_buffer = (bfd_byte *) bfd_malloc (uncompressed_size);
-+ /* PR 21431 */
-+ if (uncompressed_buffer == NULL)
-+ return FALSE;
-+
- if (!bfd_get_section_contents (abfd, sec, uncompressed_buffer,
- 0, uncompressed_size))
-- ret = FALSE;
-- else
-- {
-- uncompressed_size = bfd_compress_section_contents (abfd, sec,
-- uncompressed_buffer,
-- uncompressed_size);
-- ret = uncompressed_size != 0;
-- }
-+ return FALSE;
-
-- return ret;
-+ uncompressed_size = bfd_compress_section_contents (abfd, sec,
-+ uncompressed_buffer,
-+ uncompressed_size);
-+ return uncompressed_size != 0;
- }
-
- /*
---
-2.9.3
-
diff --git a/debian/patches/pr21432.diff b/debian/patches/pr21432.diff
deleted file mode 100644
index fe4fe60..0000000
--- a/debian/patches/pr21432.diff
+++ /dev/null
@@ -1,85 +0,0 @@
-From a941291cab71b9ac356e1c03968c177c03e602ab Mon Sep 17 00:00:00 2001
-From: Alan Modra <amodra@gmail.com>
-Date: Sat, 29 Apr 2017 14:48:16 +0930
-Subject: [PATCH] PR21432, buffer overflow in perform_relocation
-
-The existing reloc offset range tests didn't catch small negative
-offsets less than the size of the reloc field.
-
- PR 21432
- * reloc.c (reloc_offset_in_range): New function.
- (bfd_perform_relocation, bfd_install_relocation): Use it.
- (_bfd_final_link_relocate): Likewise.
----
- bfd/ChangeLog | 7 +++++++
- bfd/reloc.c | 32 ++++++++++++++++++++------------
- 2 files changed, 27 insertions(+), 12 deletions(-)
-
-diff --git a/bfd/reloc.c b/bfd/reloc.c
-index 9a04022..12520d1 100644
---- a/bfd/reloc.c
-+++ b/bfd/reloc.c
-@@ -538,6 +538,22 @@ bfd_check_overflow (enum complain_overflow how,
- return flag;
- }
-
-+/* HOWTO describes a relocation, at offset OCTET. Return whether the
-+ relocation field is within SECTION of ABFD. */
-+
-+static bfd_boolean
-+reloc_offset_in_range (reloc_howto_type *howto, bfd *abfd,
-+ asection *section, bfd_size_type octet)
-+{
-+ bfd_size_type octet_end = bfd_get_section_limit_octets (abfd, section);
-+ bfd_size_type reloc_size = bfd_get_reloc_size (howto);
-+
-+ /* The reloc field must be contained entirely within the section.
-+ Allow zero length fields (marker relocs or NONE relocs where no
-+ relocation will be performed) at the end of the section. */
-+ return octet <= octet_end && octet + reloc_size <= octet_end;
-+}
-+
- /*
- FUNCTION
- bfd_perform_relocation
-@@ -619,15 +635,9 @@ bfd_perform_relocation (bfd *abfd,
- if (howto == NULL)
- return bfd_reloc_undefined;
-
-- /* Is the address of the relocation really within the section?
-- Include the size of the reloc in the test for out of range addresses.
-- PR 17512: file: c146ab8b, 46dff27f, 38e53ebf. */
-+ /* Is the address of the relocation really within the section? */
- octets = reloc_entry->address * bfd_octets_per_byte (abfd);
-- if (octets + bfd_get_reloc_size (howto)
-- > bfd_get_section_limit_octets (abfd, input_section)
-- /* Check for an overly large offset which
-- masquerades as a negative value too. */
-- || (octets + bfd_get_reloc_size (howto) < bfd_get_reloc_size (howto)))
-+ if (!reloc_offset_in_range (howto, abfd, input_section, octets))
- return bfd_reloc_outofrange;
-
- /* Work out which section the relocation is targeted at and the
-@@ -1015,8 +1025,7 @@ bfd_install_relocation (bfd *abfd,
-
- /* Is the address of the relocation really within the section? */
- octets = reloc_entry->address * bfd_octets_per_byte (abfd);
-- if (octets + bfd_get_reloc_size (howto)
-- > bfd_get_section_limit_octets (abfd, input_section))
-+ if (!reloc_offset_in_range (howto, abfd, input_section, octets))
- return bfd_reloc_outofrange;
-
- /* Work out which section the relocation is targeted at and the
-@@ -1354,8 +1363,7 @@ _bfd_final_link_relocate (reloc_howto_type *howto,
- bfd_size_type octets = address * bfd_octets_per_byte (input_bfd);
-
- /* Sanity check the address. */
-- if (octets + bfd_get_reloc_size (howto)
-- > bfd_get_section_limit_octets (input_bfd, input_section))
-+ if (!reloc_offset_in_range (howto, input_bfd, input_section, octets))
- return bfd_reloc_outofrange;
-
- /* This function assumes that we are dealing with a basic relocation
---
-2.9.3
-
diff --git a/debian/patches/pr21434.diff b/debian/patches/pr21434.diff
deleted file mode 100644
index 0e6dc41..0000000
--- a/debian/patches/pr21434.diff
+++ /dev/null
@@ -1,33 +0,0 @@
-From 04b31182bf3f8a1a76e995bdfaaaab4c009b9cb2 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Wed, 26 Apr 2017 16:30:22 +0100
-Subject: [PATCH] Fix a seg-fault when processing a corrupt binary containing
- reloc(s) with negative addresses.
-
- PR binutils/21434
- * reloc.c (bfd_perform_relocation): Check for a negative address
- in the reloc.
----
- bfd/ChangeLog | 6 ++++++
- bfd/reloc.c | 5 ++++-
- 2 files changed, 10 insertions(+), 1 deletion(-)
-
-diff --git a/bfd/reloc.c b/bfd/reloc.c
-index 2791458..9a04022 100644
---- a/bfd/reloc.c
-+++ b/bfd/reloc.c
-@@ -624,7 +624,10 @@ bfd_perform_relocation (bfd *abfd,
- PR 17512: file: c146ab8b, 46dff27f, 38e53ebf. */
- octets = reloc_entry->address * bfd_octets_per_byte (abfd);
- if (octets + bfd_get_reloc_size (howto)
-- > bfd_get_section_limit_octets (abfd, input_section))
-+ > bfd_get_section_limit_octets (abfd, input_section)
-+ /* Check for an overly large offset which
-+ masquerades as a negative value too. */
-+ || (octets + bfd_get_reloc_size (howto) < bfd_get_reloc_size (howto)))
- return bfd_reloc_outofrange;
-
- /* Work out which section the relocation is targeted at and the
---
-2.9.3
-
diff --git a/debian/patches/pr21438.diff b/debian/patches/pr21438.diff
deleted file mode 100644
index 97886b2..0000000
--- a/debian/patches/pr21438.diff
+++ /dev/null
@@ -1,125 +0,0 @@
-From d949ff5607b9f595e0eed2ff15fbe5eb84eb3a34 Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Fri, 28 Apr 2017 10:28:04 +0100
-Subject: [PATCH] Fix heap-buffer overflow bugs caused when dumping debug
- information from a corrupt binary.
-
- PR binutils/21438
- * dwarf.c (process_extended_line_op): Do not assume that the
- string extracted from the section is NUL terminated.
- (fetch_indirect_string): If the string retrieved from the section
- is not NUL terminated, return an error message.
- (fetch_indirect_line_string): Likewise.
- (fetch_indexed_string): Likewise.
----
- binutils/ChangeLog | 10 +++++++++
- binutils/dwarf.c | 66 +++++++++++++++++++++++++++++++++++++++++-------------
- 2 files changed, 60 insertions(+), 16 deletions(-)
-
-Index: b/binutils/dwarf.c
-===================================================================
---- a/binutils/dwarf.c
-+++ b/binutils/dwarf.c
-@@ -472,15 +472,20 @@ process_extended_line_op (unsigned char
- printf (_(" Entry\tDir\tTime\tSize\tName\n"));
- printf (" %d\t", ++state_machine_regs.last_file_entry);
-
-- name = data;
-- data += strnlen ((char *) data, end - data) + 1;
-- printf ("%s\t", dwarf_vmatoa ("u", read_uleb128 (data, & bytes_read, end)));
-- data += bytes_read;
-- printf ("%s\t", dwarf_vmatoa ("u", read_uleb128 (data, & bytes_read, end)));
-- data += bytes_read;
-- printf ("%s\t", dwarf_vmatoa ("u", read_uleb128 (data, & bytes_read, end)));
-- data += bytes_read;
-- printf ("%s\n\n", name);
-+ {
-+ size_t l;
-+
-+ name = data;
-+ l = strnlen ((char *) data, end - data);
-+ data += len + 1;
-+ printf ("%s\t", dwarf_vmatoa ("u", read_uleb128 (data, & bytes_read, end)));
-+ data += bytes_read;
-+ printf ("%s\t", dwarf_vmatoa ("u", read_uleb128 (data, & bytes_read, end)));
-+ data += bytes_read;
-+ printf ("%s\t", dwarf_vmatoa ("u", read_uleb128 (data, & bytes_read, end)));
-+ data += bytes_read;
-+ printf ("%.*s\n\n", (int) l, name);
-+ }
-
- if (((unsigned int) (data - orig_data) != len) || data == end)
- warn (_("DW_LNE_define_file: Bad opcode length\n"));
-@@ -597,18 +602,28 @@ static const unsigned char *
- fetch_indirect_string (dwarf_vma offset)
- {
- struct dwarf_section *section = &debug_displays [str].section;
-+ const unsigned char * ret;
-
- if (section->start == NULL)
- return (const unsigned char *) _("<no .debug_str section>");
-
-- if (offset > section->size)
-+ if (offset >= section->size)
- {
- warn (_("DW_FORM_strp offset too big: %s\n"),
- dwarf_vmatoa ("x", offset));
- return (const unsigned char *) _("<offset is too big>");
- }
-
-- return (const unsigned char *) section->start + offset;
-+ ret = section->start + offset;
-+ /* Unfortunately we cannot rely upon the .debug_str section ending with a
-+ NUL byte. Since our caller is expecting to receive a well formed C
-+ string we test for the lack of a terminating byte here. */
-+ if (strnlen ((const char *) ret, section->size - offset)
-+ == section->size - offset)
-+ ret = (const unsigned char *)
-+ _("<no NUL byte at end of .debug_str section>");
-+
-+ return ret;
- }
-
- static const char *
-@@ -621,6 +636,7 @@ fetch_indexed_string (dwarf_vma idx, str
- struct dwarf_section *str_section = &debug_displays [str_sec_idx].section;
- dwarf_vma index_offset = idx * offset_size;
- dwarf_vma str_offset;
-+ const char * ret;
-
- if (index_section->start == NULL)
- return (dwo ? _("<no .debug_str_offsets.dwo section>")
-@@ -628,7 +644,7 @@ fetch_indexed_string (dwarf_vma idx, str
-
- if (this_set != NULL)
- index_offset += this_set->section_offsets [DW_SECT_STR_OFFSETS];
-- if (index_offset > index_section->size)
-+ if (index_offset >= index_section->size)
- {
- warn (_("DW_FORM_GNU_str_index offset too big: %s\n"),
- dwarf_vmatoa ("x", index_offset));
-@@ -641,14 +657,22 @@ fetch_indexed_string (dwarf_vma idx, str
-
- str_offset = byte_get (index_section->start + index_offset, offset_size);
- str_offset -= str_section->address;
-- if (str_offset > str_section->size)
-+ if (str_offset >= str_section->size)
- {
- warn (_("DW_FORM_GNU_str_index indirect offset too big: %s\n"),
- dwarf_vmatoa ("x", str_offset));
- return _("<indirect index offset is too big>");
- }
-
-- return (const char *) str_section->start + str_offset;
-+ ret = (const char *) str_section->start + str_offset;
-+ /* Unfortunately we cannot rely upon str_section ending with a NUL byte.
-+ Since our caller is expecting to receive a well formed C string we test
-+ for the lack of a terminating byte here. */
-+ if (strnlen (ret, str_section->size - str_offset)
-+ == str_section->size - str_offset)
-+ ret = (const char *) _("<no NUL byte at end of section>");
-+
-+ return ret;
- }
-
- static const char *
diff --git a/debian/patches/pr21440.diff b/debian/patches/pr21440.diff
deleted file mode 100644
index 4dcf83e..0000000
--- a/debian/patches/pr21440.diff
+++ /dev/null
@@ -1,36 +0,0 @@
-From 39ff1b79f687b65f4144ddb379f22587003443fb Mon Sep 17 00:00:00 2001
-From: Nick Clifton <nickc@redhat.com>
-Date: Tue, 2 May 2017 11:54:53 +0100
-Subject: [PATCH] Prevent memory exhaustion from a corrupt PE binary with an
- overlarge number of relocs.
-
- PR 21440
- * objdump.c (dump_relocs_in_section): Check for an excessive
- number of relocs before attempting to dump them.
----
- binutils/ChangeLog | 6 ++++++
- binutils/objdump.c | 8 ++++++++
- 2 files changed, 14 insertions(+)
-
-diff --git a/binutils/objdump.c b/binutils/objdump.c
-index bc61000..5972da1 100644
---- a/binutils/objdump.c
-+++ b/binutils/objdump.c
-@@ -3379,6 +3379,14 @@ dump_relocs_in_section (bfd *abfd,
- return;
- }
-
-+ if ((bfd_get_file_flags (abfd) & (BFD_IN_MEMORY | BFD_LINKER_CREATED)) == 0
-+ && relsize > get_file_size (bfd_get_filename (abfd)))
-+ {
-+ printf (" (too many: 0x%x)\n", section->reloc_count);
-+ bfd_set_error (bfd_error_file_truncated);
-+ bfd_fatal (bfd_get_filename (abfd));
-+ }
-+
- relpp = (arelent **) xmalloc (relsize);
- relcount = bfd_canonicalize_reloc (abfd, section, relpp, syms);
-
---
-2.9.3
-
diff --git a/debian/patches/pr70909.diff b/debian/patches/pr70909.diff
deleted file mode 100644
index abdf444..0000000
--- a/debian/patches/pr70909.diff
+++ /dev/null
@@ -1,343 +0,0 @@
-2017-03-08 Mark Wielaard <mark@klomp.org>
-
- PR demangler/70909
- PR demangler/67264
- * include/demangle.h: Add d_printing to struct demangle_component
- and pass struct demangle_component as non const.
-
-libiberty/
-
-2017-03-08 Mark Wielaard <mark@klomp.org>
-
- PR demangler/70909
- PR demangler/67264
- * cp-demangle.c: Fix endless recursion. Pass
- struct demangle_component as non const.
- (d_make_empty): Initialize variable.
- (d_print_comp_inner): Limit recursion.
- (d_print_comp): Decrement variable.
- * cp-demint.c (cplus_demangle_fill_component): Initialize
- variable.
- (cplus_demangle_fill_builtin_type): Likewise.
- (cplus_demangle_fill_operator): Likewise.
- * testsuite/demangle-expected: Add tests.
-
-
-Index: b/include/demangle.h
-===================================================================
---- a/include/demangle.h
-+++ b/include/demangle.h
-@@ -494,6 +494,11 @@ struct demangle_component
- /* The type of this component. */
- enum demangle_component_type type;
-
-+ /* Guard against recursive component printing.
-+ Initialize to zero. Private to d_print_comp.
-+ All other fields are final after initialization. */
-+ int d_printing;
-+
- union
- {
- /* For DEMANGLE_COMPONENT_NAME. */
-@@ -688,7 +693,7 @@ cplus_demangle_v3_components (const char
-
- extern char *
- cplus_demangle_print (int options,
-- const struct demangle_component *tree,
-+ struct demangle_component *tree,
- int estimated_length,
- size_t *p_allocated_size);
-
-@@ -708,7 +713,7 @@ cplus_demangle_print (int options,
-
- extern int
- cplus_demangle_print_callback (int options,
-- const struct demangle_component *tree,
-+ struct demangle_component *tree,
- demangle_callbackref callback, void *opaque);
-
- #ifdef __cplusplus
-Index: b/libiberty/testsuite/demangle-expected
-===================================================================
---- a/libiberty/testsuite/demangle-expected
-+++ b/libiberty/testsuite/demangle-expected
-@@ -4686,3 +4686,34 @@ void g<A>(S<&A::operator+>)
-
- _Z1gI1AEv1SIXadsrT_plEE
- void g<A>(S<&A::operator+>)
-+
-+#
-+# Test recursion PR67264
-+_Z1KIStcvT_E
-+_Z1KIStcvT_E
-+
-+_ZcvT_IIS0_EE
-+_ZcvT_IIS0_EE
-+
-+_ZcvT_IZcvT_E1fE
-+_ZcvT_IZcvT_E1fE
-+
-+_Z1gINcvT_EE
-+_Z1gINcvT_EE
-+
-+_ZcvT_ILZcvDTT_EEE
-+_ZcvT_ILZcvDTT_EEE
-+
-+_Z1gIJOOT_EEOT_c
-+_Z1gIJOOT_EEOT_c
-+
-+_Z1KMMMMMMMMMMMMMMMA_xooooooooooooooo
-+_Z1KMMMMMMMMMMMMMMMA_xooooooooooooooo
-+
-+_ZdvMMMMMMMMMMMMMrrrrA_DTdvfp_fp_Eededilfdfdfdfd
-+_ZdvMMMMMMMMMMMMMrrrrA_DTdvfp_fp_Eededilfdfdfdfd
-+#
-+# Test for Infinite Recursion PR70909
-+
-+_Z1MA_aMMMMA_MMA_MMMMMMMMSt1MS_o11T0000000000t2M0oooozoooo
-+_Z1MA_aMMMMA_MMA_MMMMMMMMSt1MS_o11T0000000000t2M0oooozoooo
-Index: b/libiberty/cp-demint.c
-===================================================================
---- a/libiberty/cp-demint.c
-+++ b/libiberty/cp-demint.c
-@@ -123,6 +123,7 @@ cplus_demangle_fill_component (struct de
- p->type = type;
- p->u.s_binary.left = left;
- p->u.s_binary.right = right;
-+ p->d_printing = 0;
-
- return 1;
- }
-@@ -146,6 +147,7 @@ cplus_demangle_fill_builtin_type (struct
- {
- p->type = DEMANGLE_COMPONENT_BUILTIN_TYPE;
- p->u.s_builtin.type = &cplus_demangle_builtin_types[i];
-+ p->d_printing = 0;
- return 1;
- }
- }
-@@ -172,6 +174,7 @@ cplus_demangle_fill_operator (struct dem
- {
- p->type = DEMANGLE_COMPONENT_OPERATOR;
- p->u.s_operator.op = &cplus_demangle_operators[i];
-+ p->d_printing = 0;
- return 1;
- }
- }
-Index: b/libiberty/cp-demangle.c
-===================================================================
---- a/libiberty/cp-demangle.c
-+++ b/libiberty/cp-demangle.c
-@@ -173,10 +173,10 @@ static struct demangle_component *d_mang
- static struct demangle_component *d_type (struct d_info *);
-
- #define cplus_demangle_print d_print
--static char *d_print (int, const struct demangle_component *, int, size_t *);
-+static char *d_print (int, struct demangle_component *, int, size_t *);
-
- #define cplus_demangle_print_callback d_print_callback
--static int d_print_callback (int, const struct demangle_component *,
-+static int d_print_callback (int, struct demangle_component *,
- demangle_callbackref, void *);
-
- #define cplus_demangle_init_info d_init_info
-@@ -265,7 +265,7 @@ struct d_print_mod
- in which they appeared in the mangled string. */
- struct d_print_mod *next;
- /* The modifier. */
-- const struct demangle_component *mod;
-+ struct demangle_component *mod;
- /* Whether this modifier was printed. */
- int printed;
- /* The list of templates which applies to this modifier. */
-@@ -531,7 +531,7 @@ static inline void d_append_string (stru
- static inline char d_last_char (struct d_print_info *);
-
- static void
--d_print_comp (struct d_print_info *, int, const struct demangle_component *);
-+d_print_comp (struct d_print_info *, int, struct demangle_component *);
-
- static void
- d_print_java_identifier (struct d_print_info *, const char *, int);
-@@ -540,25 +540,25 @@ static void
- d_print_mod_list (struct d_print_info *, int, struct d_print_mod *, int);
-
- static void
--d_print_mod (struct d_print_info *, int, const struct demangle_component *);
-+d_print_mod (struct d_print_info *, int, struct demangle_component *);
-
- static void
- d_print_function_type (struct d_print_info *, int,
-- const struct demangle_component *,
-+ struct demangle_component *,
- struct d_print_mod *);
-
- static void
- d_print_array_type (struct d_print_info *, int,
-- const struct demangle_component *,
-+ struct demangle_component *,
- struct d_print_mod *);
-
- static void
--d_print_expr_op (struct d_print_info *, int, const struct demangle_component *);
-+d_print_expr_op (struct d_print_info *, int, struct demangle_component *);
-
- static void d_print_cast (struct d_print_info *, int,
-- const struct demangle_component *);
-+ struct demangle_component *);
- static void d_print_conversion (struct d_print_info *, int,
-- const struct demangle_component *);
-+ struct demangle_component *);
-
- static int d_demangle_callback (const char *, int,
- demangle_callbackref, void *);
-@@ -924,6 +924,7 @@ d_make_empty (struct d_info *di)
- if (di->next_comp >= di->num_comps)
- return NULL;
- p = &di->comps[di->next_comp];
-+ p->d_printing = 0;
- ++di->next_comp;
- return p;
- }
-@@ -4246,7 +4247,7 @@ d_last_char (struct d_print_info *dpi)
- CP_STATIC_IF_GLIBCPP_V3
- int
- cplus_demangle_print_callback (int options,
-- const struct demangle_component *dc,
-+ struct demangle_component *dc,
- demangle_callbackref callback, void *opaque)
- {
- struct d_print_info dpi;
-@@ -4289,7 +4290,7 @@ cplus_demangle_print_callback (int optio
-
- CP_STATIC_IF_GLIBCPP_V3
- char *
--cplus_demangle_print (int options, const struct demangle_component *dc,
-+cplus_demangle_print (int options, struct demangle_component *dc,
- int estimate, size_t *palc)
- {
- struct d_growable_string dgs;
-@@ -4449,7 +4450,7 @@ d_args_length (struct d_print_info *dpi,
-
- static void
- d_print_subexpr (struct d_print_info *dpi, int options,
-- const struct demangle_component *dc)
-+ struct demangle_component *dc)
- {
- int simple = 0;
- if (dc->type == DEMANGLE_COMPONENT_NAME
-@@ -4525,9 +4526,9 @@ d_get_saved_scope (struct d_print_info *
-
- static int
- d_maybe_print_fold_expression (struct d_print_info *dpi, int options,
-- const struct demangle_component *dc)
-+ struct demangle_component *dc)
- {
-- const struct demangle_component *ops, *operator_, *op1, *op2;
-+ struct demangle_component *ops, *operator_, *op1, *op2;
- int save_idx;
-
- const char *fold_code = d_left (dc)->u.s_operator.op->code;
-@@ -4588,11 +4589,11 @@ d_maybe_print_fold_expression (struct d_
-
- static void
- d_print_comp_inner (struct d_print_info *dpi, int options,
-- const struct demangle_component *dc)
-+ struct demangle_component *dc)
- {
- /* Magic variable to let reference smashing skip over the next modifier
- without needing to modify *dc. */
-- const struct demangle_component *mod_inner = NULL;
-+ struct demangle_component *mod_inner = NULL;
-
- /* Variable used to store the current templates while a previously
- captured scope is used. */
-@@ -4977,7 +4978,7 @@ d_print_comp_inner (struct d_print_info
- case DEMANGLE_COMPONENT_RVALUE_REFERENCE:
- {
- /* Handle reference smashing: & + && = &. */
-- const struct demangle_component *sub = d_left (dc);
-+ struct demangle_component *sub = d_left (dc);
- if (!dpi->is_lambda_arg
- && sub->type == DEMANGLE_COMPONENT_TEMPLATE_PARAM)
- {
-@@ -5680,9 +5681,16 @@ d_print_comp_inner (struct d_print_info
-
- static void
- d_print_comp (struct d_print_info *dpi, int options,
-- const struct demangle_component *dc)
-+ struct demangle_component *dc)
- {
- struct d_component_stack self;
-+ if (dc == NULL || dc->d_printing > 1)
-+ {
-+ d_print_error (dpi);
-+ return;
-+ }
-+ else
-+ dc->d_printing++;
-
- self.dc = dc;
- self.parent = dpi->component_stack;
-@@ -5691,6 +5699,7 @@ d_print_comp (struct d_print_info *dpi,
- d_print_comp_inner (dpi, options, dc);
-
- dpi->component_stack = self.parent;
-+ dc->d_printing--;
- }
-
- /* Print a Java dentifier. For Java we try to handle encoded extended
-@@ -5832,7 +5841,7 @@ d_print_mod_list (struct d_print_info *d
-
- static void
- d_print_mod (struct d_print_info *dpi, int options,
-- const struct demangle_component *mod)
-+ struct demangle_component *mod)
- {
- switch (mod->type)
- {
-@@ -5924,7 +5933,7 @@ d_print_mod (struct d_print_info *dpi, i
-
- static void
- d_print_function_type (struct d_print_info *dpi, int options,
-- const struct demangle_component *dc,
-+ struct demangle_component *dc,
- struct d_print_mod *mods)
- {
- int need_paren;
-@@ -6002,7 +6011,7 @@ d_print_function_type (struct d_print_in
-
- static void
- d_print_array_type (struct d_print_info *dpi, int options,
-- const struct demangle_component *dc,
-+ struct demangle_component *dc,
- struct d_print_mod *mods)
- {
- int need_space;
-@@ -6056,7 +6065,7 @@ d_print_array_type (struct d_print_info
-
- static void
- d_print_expr_op (struct d_print_info *dpi, int options,
-- const struct demangle_component *dc)
-+ struct demangle_component *dc)
- {
- if (dc->type == DEMANGLE_COMPONENT_OPERATOR)
- d_append_buffer (dpi, dc->u.s_operator.op->name,
-@@ -6069,7 +6078,7 @@ d_print_expr_op (struct d_print_info *dp
-
- static void
- d_print_cast (struct d_print_info *dpi, int options,
-- const struct demangle_component *dc)
-+ struct demangle_component *dc)
- {
- d_print_comp (dpi, options, d_left (dc));
- }
-@@ -6078,7 +6087,7 @@ d_print_cast (struct d_print_info *dpi,
-
- static void
- d_print_conversion (struct d_print_info *dpi, int options,
-- const struct demangle_component *dc)
-+ struct demangle_component *dc)
- {
- struct d_print_template dpt;
-
diff --git a/debian/patches/series b/debian/patches/series
index 3af7896..6b85d81 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,5 +1,6 @@
branch-updates.diff
#branch-version.diff
+branch-no-development.diff
001_ld_makefile_patch.patch
002_gprof_profile_arcs.patch
003_gprof_see_also_monitor.patch
@@ -11,7 +12,7 @@ branch-updates.diff
129_multiarch_libpath.patch
130_gold_disable_testsuite_build.patch
131_ld_bootstrap_testsuite.patch
-135_bfd_version.patch
+135_bfd_soversion.patch
136_bfd_pic.patch
157_ar_scripts_with_tilde.patch
#158_ld_system_root.patch
@@ -25,27 +26,14 @@ aarch64-libpath.diff
#pr-ld-16428.diff
mips64-default-n64.diff
gold-mips.diff
-ld-new-dtags-by-default.diff
-pr21074-revert.diff
-i18n-fr.diff
+gold-no-keep-files-mapped.diff
+
+# trunk backports
+
+# experimental ...
+infinity-notes.diff
+#binutils-no-development.diff
-# patches taken from the trunk
-ppc-lib-search-order.diff
-pr21157.diff
-pr21137.diff
-pr21156.diff
-pr21139.diff
-pr21135.diff
-pr70909.diff
-pr21342.diff
-pr21412.diff
-pr21414.diff
-pr21431.diff
-pr21434.diff
-pr21432.diff
-pr21438.diff
-pr21440.diff
-gold-sparc-fix.diff
dyson-biarch.patch
dyson-pr14493-sol2.patch
diff --git a/debian/rules b/debian/rules
index 386391a..8b47f81 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,10 +1,10 @@
#!/usr/bin/make -f
-# debian/rules file - for binutils (2.20)
+# debian/rules file - for binutils (2.29)
# Based on sample debian/rules file - for GNU Hello (1.3).
# Copyright 1994,1995 by Ian Jackson.
# Copyright 1998-2007 James Troup.
-# Portions Copyright 2008-2015 Canonical Ltd.
-# Portions Copyright 2008-2015 Matthias Klose.
+# Portions Copyright 2008-2017 Canonical Ltd.
+# Portions Copyright 2008-2017 Matthias Klose.
# I hereby give you perpetual unlimited permission to copy,
# modify and relicense this file, provided that you do not remove
# my name from the file itself. (I assert my moral right of
@@ -13,7 +13,37 @@
###############################################################################
+vafilt = $(subst $(2)=,,$(filter $(2)=%,$(1)))
+DPKG_VARS := $(shell dpkg-architecture)
+DEB_BUILD_GNU_TYPE ?= $(call vafilt,$(DPKG_VARS),DEB_BUILD_GNU_TYPE)
+DEB_HOST_ARCH ?= $(call vafilt,$(DPKG_VARS),DEB_HOST_ARCH)
+DEB_HOST_GNU_CPU ?= $(call vafilt,$(DPKG_VARS),DEB_HOST_GNU_CPU)
+DEB_HOST_GNU_TYPE ?= $(call vafilt,$(DPKG_VARS),DEB_HOST_GNU_TYPE)
+DEB_HOST_MULTIARCH ?= $(call vafilt,$(DPKG_VARS),DEB_HOST_MULTIARCH)
+
+ifeq (,$(filter $(distrelease),lenny etch squeeze wheezy jessie))
+ ifeq ($(DEB_HOST_GNU_TYPE),i586-linux-gnu)
+ DEB_BUILD_GNU_TYPE = i686-linux-gnu
+ DEB_HOST_GNU_CPU = i686
+ DEB_HOST_GNU_TYPE = i686-linux-gnu
+ TRIPLET_SYMLINK = i586-linux-gnu
+ else ifeq ($(DEB_HOST_GNU_TYPE),i586-kfreebsd-gnu)
+ DEB_BUILD_GNU_TYPE = i686-kfreebsd-gnu
+ DEB_HOST_GNU_CPU = i686
+ DEB_HOST_GNU_TYPE = i686-kfreebsd-gnu
+ TRIPLET_SYMLINK = i586-kfreebsd-gnu
+ else ifeq ($(DEB_HOST_GNU_TYPE),i586-gnu)
+ DEB_BUILD_GNU_TYPE = i686-gnu
+ DEB_HOST_GNU_CPU = i686
+ DEB_HOST_GNU_TYPE = i686-gnu
+ TRIPLET_SYMLINK = i586-gnu
+ endif
+endif
+
p_bin = binutils
+p_com = $(p_bin)-common
+p_lib = lib$(p_bin)
+p_nat = $(p_bin)-$(subst _,-,$(DEB_HOST_GNU_TYPE))
p_dev = $(p_bin)-dev
p_mul = $(p_bin)-multiarch
p_mdev = $(p_mul)-dev
@@ -21,6 +51,14 @@ p_doc = $(p_bin)-doc
p_hppa64 = $(p_bin)-hppa64-linux-gnu
p_src = $(p_bin)-source
+p_hst = $(p_bin)-for-host
+p_bld = $(p_bin)-for-build
+
+p_cross = $(p_bin)-$(subst _,-,$(TARGET))
+
+# version used for p_bld/p_hst dependencies
+min_ver = 2.30-2
+
distribution := $(shell lsb_release -is)
distrelease := $(shell lsb_release -cs)
ifeq ($(distrelease),n/a)
@@ -38,6 +76,9 @@ endif
pwd := $(shell pwd)
d = debian/tmp
d_bin = $(d)
+d_com = debian/$(p_com)
+d_lib = debian/$(p_lib)
+d_nat = debian/$(p_nat)
d_dev = debian/$(p_dev)
d_mul = debian/$(p_mul)
d_mdev = debian/$(p_mdev)
@@ -45,79 +86,123 @@ d_doc = debian/$(p_doc)
d_hppa64 = debian/$(p_hppa64)
d_src = debian/$(p_src)
+d_hst = debian/$(p_hst)
+d_bld = debian/$(p_bld)
+
+d_cross = debian/$(p_cross)
+
install_dir = install -d -m 755
install_file = install -m 644
install_script = install -m 755
-install_binary = install -m 755 -s
-
-vafilt = $(subst $(2)=,,$(filter $(2)=%,$(1)))
-DPKG_VARS := $(shell dpkg-architecture)
-DEB_BUILD_GNU_TYPE ?= $(call vafilt,$(DPKG_VARS),DEB_BUILD_GNU_TYPE)
-DEB_HOST_ARCH ?= $(call vafilt,$(DPKG_VARS),DEB_HOST_ARCH)
-DEB_HOST_GNU_CPU ?= $(call vafilt,$(DPKG_VARS),DEB_HOST_GNU_CPU)
-DEB_HOST_GNU_TYPE ?= $(call vafilt,$(DPKG_VARS),DEB_HOST_GNU_TYPE)
-DEB_HOST_MULTIARCH ?= $(call vafilt,$(DPKG_VARS),DEB_HOST_MULTIARCH)
+install_binary = install -m 755 -s --strip-program="$(STRIP)"
-ifeq (,$(filter $(distrelease),lenny etch squeeze wheezy jessie))
- ifeq ($(DEB_HOST_GNU_TYPE),i586-linux-gnu)
- DEB_BUILD_GNU_TYPE = i686-linux-gnu
- DEB_HOST_GNU_CPU = i686
- DEB_HOST_GNU_TYPE = i686-linux-gnu
- TRIPLET_SYMLINK = i586-linux-gnu
- else ifeq ($(DEB_HOST_GNU_TYPE),i586-kfreebsd-gnu)
- DEB_BUILD_GNU_TYPE = i686-kfreebsd-gnu
- DEB_HOST_GNU_CPU = i686
- DEB_HOST_GNU_TYPE = i686-kfreebsd-gnu
- TRIPLET_SYMLINK = i586-kfreebsd-gnu
- else ifeq ($(DEB_HOST_GNU_TYPE),i586-gnu)
- DEB_BUILD_GNU_TYPE = i686-gnu
- DEB_HOST_GNU_CPU = i686
- DEB_HOST_GNU_TYPE = i686-gnu
- TRIPLET_SYMLINK = i586-gnu
- endif
-endif
+NATIVE_ARCHS ?= amd64 i386 arm64 armhf armel ppc64el s390x
+NATIVE_ARCHS += alpha hppa ia64 m68k powerpc ppc64 \
+ riscv64 sh4 sparc64 x32
+NATIVE_ARCHS += hurd-i386 kfreebsd-amd64 kfreebsd-i386
+NATIVE_ARCHS += mips mipsel mipsn32 mipsn32el mips64 mips64el
+NATIVE_ARCHS += mipsn32r6 mipsn32r6el mipsr6 mipsr6el mips64r6 mips64r6el
+#NATIVE_ARCHS += nios2 or1k s390 sparc
src_name := $(shell dpkg-parsechangelog -S Source)
ifeq ($(src_name),binutils)
with_native = yes
with_cross = yes
same_source = yes
- CROSS_ARCHS ?= s390x ppc64el powerpc arm64 armhf armel mips mipsel
- CROSS_ARCHS += alpha hppa m68k mips64 mips64el powerpcspe ppc64 sh4 sparc64
- CROSS_ARCHS += mipsn32 mipsn32el
- #CROSS_ARCHS += mipsr6 mipsr6el mipsn32r6 mipsn32r6el mips64r6 mips64r6el
- #CROSS_ARCHS += kfreebsd-amd64 kfreebsd-i386 hurd-i386
+ ifeq (,$(CROSS_ARCHS))
+ ifneq (,$(filter $(DEB_HOST_ARCH), amd64 i386 x32))
+ CROSS_ARCHS = s390x ppc64el arm64 armhf armel
+ CROSS_ARCHS += alpha hppa m68k
+ CROSS_ARCHS += powerpc ppc64 sh4 sparc64
+ CROSS_ARCHS += ia64 riscv64
+ CROSS_ARCHS += kfreebsd-amd64 kfreebsd-i386 hurd-i386
+ ifneq (,$(filter $(DEB_HOST_ARCH), i386 x32))
+ CROSS_ARCHS += amd64
+ endif
+ ifneq (,$(filter $(DEB_HOST_ARCH), amd64 x32))
+ CROSS_ARCHS += i386
+ endif
+ ifneq (,$(filter $(DEB_HOST_ARCH), amd64 i386))
+ CROSS_ARCHS += x32
+ endif
+ else ifeq ($(DEB_HOST_ARCH),arm64)
+ CROSS_ARCHS = armel armhf amd64 i386 ppc64el riscv64 s390x x32
+ else ifeq ($(DEB_HOST_ARCH),ppc64)
+ CROSS_ARCHS = ppc64el
+ else ifeq ($(DEB_HOST_ARCH),ppc64el)
+ CROSS_ARCHS = powerpc ppc64 amd64 i386 x32 arm64 armel armhf riscv64 s390x
+ else
+ CROSS_ARCHS =
+ endif
+ else
+ # c-t-b passes this one ...
+ CROSS_ARCHS := $(filter-out $(DEB_HOST_ARCH),$(CROSS_ARCHS))
+ endif
+else ifeq ($(src_name),binutils-mipsen)
+ with_native =
+ with_cross = yes
+ same_source =
+ ifeq (,$(CROSS_ARCHS))
+ ifneq (,$(filter $(DEB_HOST_ARCH), amd64 i386 x32))
+ CROSS_ARCHS = mips mipsel mips64el mips64 mipsn32 mipsn32el
+ CROSS_ARCHS += mipsr6 mipsr6el mipsn32r6 mipsn32r6el mips64r6 mips64r6el
+ else
+ CROSS_ARCHS =
+ endif
+ else
+ # c-t-b passes this one ...
+ CROSS_ARCHS := $(filter-out $(DEB_HOST_ARCH),$(CROSS_ARCHS))
+ endif
else
# binutils-ports ...
with_cross = yes
- CROSS_ARCHS ?= m68k sh4 mips64 mips64el
+ ifeq (,$(CROSS_ARCHS))
+ CROSS_ARCHS ?= m68k sh4 mips64 mips64el
+ endif
endif
ifneq (,$(filter $(DEB_HOST_ARCH),amd64 i386 x32 hppa))
with_hppa64 = yes
endif
-HOST_ARCHS_armhf = amd64 i386 x32 arm64
-HOST_ARCHS_armel = amd64 i386 x32 arm64
-HOST_ARCHS_arm64 = amd64 i386 x32
-HOST_ARCHS_mips = amd64 i386 x32
-HOST_ARCHS_mipsel = amd64 i386 x32
+with_multiarch := yes
+
+# disabled: no build-needed restriction used in the autopkg test
+ifeq (0,1)
+# only build the basic package when running the autopkg tests
+ifneq (,$(ADT_TEST_TRIGGERS))
+ # c-t-b sets CROSS_ARCHS which has to be respected, can't unset it here
+ #CROSS_ARCHS :=
+ with_hppa64 :=
+ with_multiarch :=
+endif
+endif
+
+HOST_ARCHS_armhf = amd64 i386 x32 arm64 ppc64el
+HOST_ARCHS_armel = amd64 i386 x32 arm64 ppc64el
+HOST_ARCHS_arm64 = amd64 i386 x32 ppc64el
HOST_ARCHS_powerpc = amd64 i386 x32 ppc64el
-HOST_ARCHS_ppc64el = amd64 i386 x32 ppc64
-HOST_ARCHS_s390x = amd64 i386 x32
+HOST_ARCHS_ppc64el = amd64 i386 x32 ppc64 arm64
+HOST_ARCHS_s390x = amd64 i386 x32 arm64 ppc64el
+HOST_ARCHS_amd64 = arm64 i386 ppc64el x32
+HOST_ARCHS_i386 = amd64 arm64 ppc64el x32
+HOST_ARCHS_ia64 = amd64 i386 x32
+HOST_ARCHS_riscv64 = amd64 i386 x32 arm64 ppc64el
HOST_ARCHS_alpha = amd64 i386 x32
HOST_ARCHS_hppa = amd64 i386 x32
HOST_ARCHS_m68k = amd64 i386 x32
-HOST_ARCHS_mips64 = amd64 i386 x32
-HOST_ARCHS_mips64el = amd64 i386 x32
-HOST_ARCHS_powerpcspe = amd64 i386 x32
HOST_ARCHS_ppc64 = amd64 i386 x32 ppc64el
HOST_ARCHS_sh4 = amd64 i386 x32
HOST_ARCHS_sparc64 = amd64 i386 x32
+HOST_ARCHS_x32 = amd64 arm64 i386 ppc64el
+HOST_ARCHS_mips = amd64 i386 x32
+HOST_ARCHS_mipsel = amd64 i386 x32
HOST_ARCHS_mipsn32 = amd64 i386 x32
HOST_ARCHS_mipsn32el = amd64 i386 x32
+HOST_ARCHS_mips64 = amd64 i386 x32
+HOST_ARCHS_mips64el = amd64 i386 x32
HOST_ARCHS_mipsr6 = amd64 i386 x32
HOST_ARCHS_mipsr6el = amd64 i386 x32
@@ -130,17 +215,6 @@ HOST_ARCHS_kfreebsd-amd64 = amd64 i386 x32
HOST_ARCHS_kfreebsd-i386 = amd64 i386 x32
HOST_ARCHS_hurd-i386 = amd64 i386 x32
-ifneq (,$(filter $(DEB_HOST_ARCH), amd64 i386 x32))
- #
-else ifeq ($(DEB_HOST_ARCH),arm64)
- CROSS_ARCHS = armel armhf
-else ifeq ($(DEB_HOST_ARCH),ppc64)
- CROSS_ARCHS = ppc64el
-else ifeq ($(DEB_HOST_ARCH),ppc64el)
- CROSS_ARCHS = powerpc ppc64
-else
- CROSS_ARCHS =
-endif
CROSS_ARCH = $(subst .,,$(suffix $@))
_gnu_type = $(shell dpkg-architecture -a$(1) -qDEB_HOST_GNU_TYPE -f 2>/dev/null)
_multiarch = $(shell dpkg-architecture -a$(1) -qDEB_HOST_MULTIARCH -f 2>/dev/null)
@@ -168,9 +242,11 @@ ifneq (,$(TARGET))
DPKG_TARGET_VARS := $(shell dpkg-architecture -f -t$(TARGET))
DEB_TARGET_MULTIARCH = $(call vafilt,$(DPKG_TARGET_VARS),DEB_HOST_MULTIARCH)
DEB_TARGET_ARCH = $(call vafilt,$(DPKG_TARGET_VARS),DEB_HOST_ARCH)
+ for_target = dpkg-architecture -f -t$(TARGET) -c
else
DEB_TARGET_MULTIARCH = $(DEB_HOST_MULTIARCH)
DEB_TARGET_ARCH = $(DEB_HOST_ARCH)
+ for_target =
endif
ifneq (,$(TARGET))
@@ -192,7 +268,7 @@ gold_targets = \
amd64 arm64 armel armhf i386 \
mips mipsel mipsn32 mipsn32el mips64 mips64el \
mipsr6 mipsr6el mipsn32r6 mipsn32r6el mips64r6 mips64r6el \
- powerpc powerpcspe ppc64 ppc64el sparc sparc64 \
+ powerpc ppc64 ppc64el sparc sparc64 s390x \
x32 kfreebsd-amd64 kfreebsd-i386 hurd-i386
ifneq (,$(filter $(DEB_HOST_ARCH), $(gold_targets)))
@@ -200,22 +276,13 @@ ifneq (,$(filter $(DEB_HOST_ARCH), $(gold_targets)))
gold_provides = -Vgold:Provides=binutils-gold
endif
-with_multiarch := yes
-
-CC = gcc
-CXX = g++
CFLAGS = -g -O2
CXXFLAGS = -g -O2
LDFLAGS =
-STRIP = strip --remove-section=.comment --remove-section=.note
-CROSS :=
-ifneq ($(DEB_BUILD_GNU_TYPE),$(DEB_HOST_GNU_TYPE))
- CROSS := $(DEB_HOST_GNU_TYPE)-
- CC = $(CROSS)gcc
- CXX = $(CROSS)g++
- STRIP= $(CURDIR)/debian/strip.cross
- install_binary = install -m 755 -s --strip-program="$(STRIP)"
-endif
+CROSS := $(DEB_HOST_GNU_TYPE)-
+CC = $(CROSS)gcc
+CXX = $(CROSS)g++
+STRIP = $(CROSS)strip --remove-section=.comment --remove-section=.note
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS = -g -O0
@@ -244,11 +311,12 @@ DEB_SVERSION := $(shell echo $(DEB_VERSION) | sed 's/+b[0-9][0-9]*$$//')
DEB_UPSTREAM := $(firstword $(subst -,$(SPACE),$(DEB_VERSION)))
VERSION := $(shell sed -n 's/^ *VERSION=\(.*\)/\1/p' bfd/configure | head -1 | tr -d \')
-DATE := $(shell sed -n 's/.* \([0-9]*\)$$/\1/p' bfd/version.h)
+#DATE := $(shell sed -n 's/.* \([0-9]*\)$$/\1/p' bfd/version.h)
ifneq (,$(DATE))
-# DATE_EXT := .$(DATE)
+ DATE_EXT := .$(DATE)
endif
BUILD_DATE := $(shell dpkg-parsechangelog | sed -n -e 's/^Date: //p')
+BUILD_DAY := $(shell date -Idate -u -d "$(BUILD_DATE)")
is_rc = yes
is_rc =
@@ -257,13 +325,16 @@ ifneq ($(DEB_UPSTREAM),$(VERSION)$(DATE_EXT))
$(error upstream ($(VERSION)$(DATE_EXT)) and debian ($(DEB_UPSTREAM)) version mismatch)
endif
-SINGLE_VERSION= $(VERSION)-system
-MULTI_VERSION = $(VERSION)-multiarch
-HPPA64_VERSION= $(VERSION)-hppa64
+SINGLE_VERSION= -system
+MULTI_VERSION = -multiarch
+HPPA64_VERSION= -hppa64
-ifeq (,$(filter $(distrelease),lenny etch squeeze wheezy dapper hardy jaunty karmic lucid maverick natty oneiric precise quantal raring saucy trusty utopic))
+ifeq (,$(filter $(distrelease),squeeze wheezy precise trusty))
DPKG_DEV = dpkg-dev (>= 1.17.11),
endif
+ifeq (,$(filter $(distrelease),squeeze wheezy stretch precise trusty xenial zesty artful))
+ DPKG_DEV = dpkg-dev (>= 1.19.0.5),
+endif
NJOBS =
# Support parallel=<n> in DEB_BUILD_OPTIONS (see #209008)
@@ -303,6 +374,12 @@ gfdl_toplevel_texinfo_files = \
gfdl_generated_files = \
bfd/doc/bfd.info
+programs = addr2line ar as c++filt elfedit gprof ld ld.bfd
+programs += nm objcopy objdump ranlib readelf size strings strip
+ifeq ($(with_gold),yes)
+programs += gold ld.gold dwp
+endif
+
########################################
CONFARGS = \
@@ -313,6 +390,7 @@ CONFARGS = \
--prefix=/$(PF) \
--enable-deterministic-archives \
--disable-compressed-debug-sections \
+ --enable-new-dtags \
--build=$(DEB_BUILD_GNU_TYPE) \
--host=$(DEB_HOST_GNU_TYPE) \
--with-pkgversion="GNU Binutils for $(distribution)"
@@ -449,12 +527,15 @@ CONFARGS_TARGET_aarch64 = --enable-targets=aarch64_be-linux-gnu
with_check := yes
ifneq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
- with_check := disabled through DEB_BUILD_OPTIONS
+ # override buildd admins to run the testsuite anyway ...
+ ifeq (,$(filter $(DEB_HOST_ARCH), m68k sh4))
+ with_check := disabled through DEB_BUILD_OPTIONS
+ endif
endif
+#with_check := disabled for this upload
ifneq (,$(filter $(DEB_HOST_ARCH), armel armhf mips mipsel sparc))
- ignore_regressions := regressions ignored on architecture $(DEB_HOST_ARCH)
+ ignore_regressions := regressions ignored on architecture $(DEB_HOST_ARCH)
endif
-
ignore_regressions := regressions ignored on architecture $(DEB_HOST_ARCH)
with_strip := yes
@@ -467,24 +548,6 @@ source_files = $(addprefix $(shell basename $(pwd))/, \
###############################################################################
-#################
-# patch targets #
-#################
-
-patch: stamps/patch
-stamps/patch:
-ifneq ($(PATCHED_SOURCES),yes)
- QUILT_PATCHES=$(CURDIR)/debian/patches \
- quilt --quiltrc /dev/null push -a || test $$? = 2
-endif
- @mkdir -p stamps
- touch $@
-
-unpatch:
- QUILT_PATCHES=$(CURDIR)/debian/patches \
- quilt --quiltrc /dev/null pop -a -R || test $$? = 2
- rm -rf .pc
-
update-patches:
export QUILT_PATCHES=$(CURDIR)/debian/patches; \
export QUILT_REFRESH_ARGS="--no-timestamps --no-index -pab"; \
@@ -497,16 +560,18 @@ update-patches:
# clean target #
################
-clean: unpatch
+clean:
$(checkdir)
rm -rf stamps
rm -rf builddir-*
rm -rf stamps
find . -name \*.gmo -o -name \*~ -o -name \*.info ! -name sysroff.info | xargs -r rm -f
- rm -f $(pwd)/test-summary*
- rm -rf $(d_bin) $(d_dev) $(d_mul) $(d_mdev) $(d_doc) $(d_hppa64) $(d_src)
- $(foreach ca,$(CROSS_ARCHS), rm -rf debian/binutils-$(shell echo $(call _gnu_type,$(ca)) | sed 's/_/-/g;s/i586/i686/'); )
- rm -rf debian/patched debian/tmp debian/files* debian/substvars
+ rm -f test-summary*
+ rm -rf $(d_bin) $(d_com) $(d_lib) $(d_lib)-dbg $(d_nat) $(d_nat)-dbg \
+ $(d_hst) $(d_dev) $(d_mul) $(d_mul)-dbg $(d_mdev) $(d_doc) \
+ $(d_hppa64) $(d_hppa64)-dbg $(d_src) $(d_bld)
+ $(foreach ca,$(CROSS_ARCHS), rm -rf debian/binutils-$(shell echo $(call _gnu_type,$(ca)) | sed 's/_/-/g;s/i586/i686/'){,-dbg}; )
+ rm -rf debian/tmp debian/files* debian/substvars
rm -f debian/*.orig debian/*.rej
rm -rf $(d_cross) debian/files debian/substvars
ifneq (,$(TARGET))
@@ -523,7 +588,8 @@ endif
stamps/control: debian/control.in $(if $(TARGET),debian/control.cross.in) $(if $(filter yes, $(with_cross)),debian/control.cross.in)
ifneq (,$(TARGET))
- sed "s/@dpkg_dev@/$(DPKG_DEV)/;/^$$/ q" < debian/control.in > debian/control
+ sed -n -e 's/@dpkg_dev@/$(DPKG_DEV)/;/^Package: binutils-for-build$$/q;p' \
+ < debian/control.in > debian/control
sed -e "s/@target@/$$(echo -n $(TARGET) | sed s/_/-/g)/" \
-e "s/@host_archs@/any/" \
-e 's/@binutils_alt_triplet@//' \
@@ -531,26 +597,19 @@ ifneq (,$(TARGET))
else
sed -e 's/@dpkg_dev@/$(DPKG_DEV)/' \
debian/control.in > debian/control
- ifeq ($(with_cross),yes)
- $(foreach ca,$(CROSS_ARCHS), \
+ $(foreach ca,$(NATIVE_ARCHS), \
sed \
- -e 's/@host_archs@/$(HOST_ARCHS_$(ca))/g' \
+ -e 's/@host_archs@/$(ca)$(if $(and $(filter yes,$(with_cross)),$(filter $(ca),$(DEB_HOST_ARCH) $(CROSS_ARCHS))), $(HOST_ARCHS_$(ca)))/g' \
-e 's/@target@/$(shell dpkg-architecture -a$(ca) -qDEB_HOST_GNU_TYPE 2>/dev/null | sed 's/_/-/g;s/i586/i686/')/g' \
-e 's/@binutils_alt_triplet@/$(if $(findstring i386,$(ca)),binutils-$(shell dpkg-architecture -a$(ca) -qDEB_HOST_GNU_TYPE 2>/dev/null | sed 's/i686/i586/g'))/g' \
debian/control.cross.in \
| $(if $(filter yes,$(same_source)), grep -v '^Built-Using', cat) \
>> debian/control; \
)
- endif
endif
@mkdir -p stamps
touch $@
-debian/strip.cross: debian/strip.cross.in
- sed -e "s/__TARGET__/$(CROSS)/" \
- < debian/strip.cross.in >> debian/strip.cross
- chmod 755 debian/strip.cross
-
#######################
# single-arch targets #
#######################
@@ -560,8 +619,9 @@ ifeq ($(with_gold),yes)
SINGLE_CONFARGS += --enable-ld=default --enable-gold
endif
-stamps/configure-single: stamps/patch
+stamps/configure-single:
$(checkdir)
+ env
@echo BEGIN $@
ifeq ($(with_check),yes)
@if echo "spawn true" | /usr/bin/expect -f - >/dev/null; then \
@@ -578,18 +638,16 @@ endif
mkdir builddir-single
cd builddir-single && env CC="$(CC)" CXX="$(CXX)" CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS)" \
$(call SET_MULTIARCH_ENV,$(DEB_HOST_ARCH)) \
- ../configure --with-sysroot=/ $(SINGLE_CONFARGS)
- $(MAKE) -C builddir-single configure-host
+ ../configure --with-sysroot=/ \
+ --libdir=/$(PF)/lib/$(DEB_HOST_MULTIARCH) \
+ $(SINGLE_CONFARGS)
+ @mkdir -p stamps
touch $@
stamps/build-single: stamps/configure-single
$(checkdir)
@echo BEGIN $@
- env MAKE="$(MAKE) VERSION=$(SINGLE_VERSION)" \
- $(call SET_MULTIARCH_ENV,$(DEB_HOST_ARCH)) \
- $(MAKE) -C builddir-single/bfd headers \
- LDFLAGS="-Wl,-z,relro"
- env MAKE="$(MAKE) VERSION=$(SINGLE_VERSION)" \
+ env BFD_SOVER_EXT="$(SINGLE_VERSION)" \
$(call SET_MULTIARCH_ENV,$(DEB_HOST_ARCH)) \
$(MAKE) $(NJOBS) -C builddir-single \
LDFLAGS="-Wl,-z,relro"
@@ -602,12 +660,20 @@ ifeq ($(with_check),yes)
builddir-single/gas/testsuite/gas.sum \
builddir-single/ld/ld.sum >> $(pwd)/test-summary
set -e; \
- if [ ! -f /usr/share/doc/binutils/test-summary.gz ]; then \
+ tsi=test-summary-installed; \
+ rm -f $$tsi; \
+ if [ -f /usr/share/doc/binutils/test-summary-$(DEB_HOST_ARCH).gz ]; then \
+ zcat /usr/share/doc/binutils/test-summary-$(DEB_HOST_ARCH).gz > $$tsi; \
+ elif [ -f /usr/share/doc/binutils/test-summary.gz ]; then \
+ zcat /usr/share/doc/binutils/test-summary.gz > $$tsi; \
+ elif [ -f /usr/share/doc/binutils/test-summary ]; then \
+ cat /usr/share/doc/binutils/test-summary > $$tsi; \
+ fi; \
+ if [ ! -f $$tsi ]; then \
echo "No test results available for the installed binutils version"; \
elif [ -x /usr/bin/python3 ]; then \
echo "Test results, compared with installed binutils:"; \
- zcat /usr/share/doc/binutils/test-summary.gz > test-summary-installed; \
- if python3 debian/test-suite-compare.py test-summary-installed test-summary; then \
+ if python3 debian/test-suite-compare.py $$tsi test-summary; then \
: ; \
elif [ -n "$(ignore_regressions)" ]; then \
echo "$(ignore_regressions)"; \
@@ -654,6 +720,7 @@ multiarch_targets = \
powerpc-linux-gnu \
powerpc64-linux-gnu \
powerpc64le-linux-gnu \
+ riscv64-linux-gnu \
s390-linux-gnu \
s390x-linux-gnu \
sh-linux-gnu \
@@ -669,7 +736,7 @@ ifeq ($(DEB_HOST_ARCH),sh4)
multiarch_targets := $(filter-out hppa-linux-gnu, $(multiarch_targets))
endif
-stamps/configure-multi: stamps/patch
+stamps/configure-multi:
$(checkdir)
@echo BEGIN $@
rm -rf stamps/configure-multi \
@@ -680,15 +747,15 @@ stamps/configure-multi: stamps/patch
$(call SET_MULTIARCH_ENV,$(DEB_HOST_ARCH)) \
../configure $(CONFARGS) \
--with-sysroot=/ \
+ --libdir=/$(PF)/lib/$(DEB_HOST_MULTIARCH) \
--enable-targets=$(subst $(SPACE),$(COMMA),$(multiarch_targets))
- $(MAKE) -C builddir-multi configure-host
+ @mkdir -p stamps
touch $@
stamps/build-multi: stamps/configure-multi
$(checkdir)
@echo BEGIN $@
- $(MAKE) -C builddir-multi/bfd headers
- env MAKE="$(MAKE) VERSION=$(MULTI_VERSION)" \
+ env BFD_SOVER_EXT="$(MULTI_VERSION)" \
$(call SET_MULTIARCH_ENV,$(DEB_HOST_ARCH)) \
$(MAKE) $(NJOBS) -C builddir-multi \
LDFLAGS="-Wl,-z,relro"
@@ -705,7 +772,7 @@ ifeq ($(with_gold),yes)
CROSS_CONFARGS += --enable-ld=default --enable-gold
endif
-stamps/configure.%: stamps/patch
+stamps/configure.%:
$(checkdir)
@echo BEGIN $@
rm -rf $@ builddir-$*
@@ -717,14 +784,16 @@ stamps/configure.%: stamps/patch
$(CROSS_CONFARGS) \
$(CONFARGS_TARGET_$(*)) \
--with-sysroot=/ \
+ --libdir=/$(PF)/lib/$(call _multiarch,$*) \
$(if $(filter $*, $(gold_targets)),--enable-ld=default --enable-gold,--disable-gold) \
--target=$(CROSS_GNU_TYPE)
+ @mkdir -p stamps
touch $@
stamps/build.%: stamps/configure.%
$(checkdir)
@echo BEGIN $@
- env MAKE="$(MAKE) VERSION=$(VERSION)-$*" \
+ env BFD_SOVER_EXT="-$*" \
$(call SET_MULTIARCH_ENV,$*) \
$(MAKE) -C builddir-$* $(NJOBS) \
CFLAGS="$(CFLAGS)" \
@@ -738,17 +807,38 @@ ifeq ($(with_check),yes)
cat builddir-$*/binutils/binutils.sum \
builddir-$*/gas/testsuite/gas.sum \
builddir-$*/ld/ld.sum >> test-summary-$*
+ set -e; \
+ tsi=test-summary-$*-installed; \
+ rm -f $$tsi; \
+ if [ -f /usr/share/doc/$(P_CROSS)/test-summary.gz ]; then \
+ zcat /usr/share/doc/$(P_CROSS)/test-summary.gz > $$tsi; \
+ elif [ -f /usr/share/doc/binutils/test-summary-$*.gz ]; then \
+ zcat /usr/share/doc/binutils/test-summary-$*.gz > $$tsi; \
+ fi; \
+ if [ ! -f $$tsi ]; then \
+ echo "No test results available for the installed $(P_CROSS) version"; \
+ elif [ -x /usr/bin/python3 ]; then \
+ echo "Test results, compared with installed binutils:"; \
+ if python3 debian/test-suite-compare.py $$tsi test-summary-$*; then \
+ : ; \
+ elif [ -n "$(ignore_regressions)" ]; then \
+ echo "$(ignore_regressions)"; \
+ else \
+ false; \
+ fi; \
+ else \
+ echo "python3 not installed, not comparing test results."; \
+ fi
endif
endif
touch $@
-stamps/install.%: stamps/build.% $(if $(CROSS),debian/strip.cross)
+stamps/install.%: stamps/build.%
$(checkdir)
@echo BEGIN $@
rm -rf $(D_CROSS)
env MAKE="$(MAKE) VERSION=$(VERSION)-$*" \
- $(MAKE) -C builddir-$* prefix=$(pwd)/$(D_CROSS)/$(PF) \
- mandir=$(pwd)/$(D_CROSS)/$(PF)/share/man install
+ $(MAKE) -C builddir-$* DESTDIR=$(CURDIR)/$(D_CROSS) install
rm -rf \
$(D_CROSS)/$(PF)/share/info \
@@ -765,6 +855,13 @@ stamps/install.%: stamps/build.% $(if $(CROSS),debian/strip.cross)
mv $$d_src/$$lib.a $$d_dst/$${lib}-$(VERSION)-$*.a; \
ln -sf ../../../lib/$(DEB_HOST_MULTIARCH)/$$lib-$(VERSION)-$*.a $$d_src/$$lib.a; \
done
+
+ : # replace hard links with soft links
+ for i in $(D_CROSS)/usr/$(CROSS_GNU_TYPE)/bin/*; do \
+ ln -sf ../../bin/$(CROSS_GNU_TYPE)-$$(basename $$i) $$i; \
+ done
+ ln -sf $(CROSS_GNU_TYPE)-ld.bfd $(D_CROSS)/usr/bin/$(CROSS_GNU_TYPE)-ld
+
$(call strip_package, $(P_CROSS),$(D_CROSS),.)
chmod ugo-x $(D_CROSS)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.so
@@ -807,25 +904,17 @@ stamps/install.%: stamps/build.% $(if $(CROSS),debian/strip.cross)
: # remove RPATH
chrpath -k -d $$(file $(D_CROSS)/usr/bin/*|awk -F: '/ ELF/ {print $$1}')
- ln -sf $(CROSS_GNU_TYPE)-ld.bfd $(D_CROSS)/usr/bin/$(CROSS_GNU_TYPE)-ld
-
- : # replace hard links with soft links
- for i in $(D_CROSS)/usr/$(CROSS_GNU_TYPE)/bin/*; do \
- ln -sf ../../bin/$(CROSS_GNU_TYPE)-$$(basename $$i) $$i; \
- done
-# temporary i586-* symlinks for stretch/sid
+ifneq (,$(filter $(distrelease),lenny etch squeeze wheezy jessie stretch))
+ : # temporary i586-* symlinks for stretch
compat=$$(echo $(CROSS_GNU_TYPE) | sed 's/i686/i586/'); \
case "$(CROSS_GNU_TYPE)" in i686-*) \
- for i in \
- addr2line ar as c++filt elfedit gprof ld ld.bfd \
- $(if $(filter $*, $(gold_targets)),ld.gold dwp) \
- nm objcopy objdump ranlib readelf size strings strip; \
- do \
+ for i in $(programs); do \
ln -sf $(CROSS_GNU_TYPE)-$$i $(D_CROSS)/$(PF)/bin/$$compat-$$i; \
ln -sf $(CROSS_GNU_TYPE)-$$i.1.gz $(D_CROSS)/$(PF)/share/man/man1/$$compat-$$i.1.gz; \
done; \
esac
+endif
touch $@
###############################################################################
@@ -834,7 +923,7 @@ stamps/install.%: stamps/build.% $(if $(CROSS),debian/strip.cross)
# hppa64 target #
#################
-stamps/configure-hppa64: stamps/patch
+stamps/configure-hppa64:
$(checkdir)
@echo BEGIN $@
rm -rf stamps/configure-hppa64 \
@@ -843,15 +932,15 @@ stamps/configure-hppa64: stamps/patch
cd builddir-hppa64 \
&& env CC="$(CC)" CXX="$(CXX)" CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS)" ../configure \
$(filter-out --enable-targets=%, $(CONFARGS)) \
+ --libdir=/$(PF)/lib/hppa64-linux-gnu \
--target=hppa64-linux-gnu
- $(MAKE) -C builddir-hppa64 configure-host
+ @mkdir -p stamps
touch $@
stamps/build-hppa64: stamps/configure-hppa64
$(checkdir)
@echo BEGIN $@
- $(MAKE) -C builddir-hppa64/bfd headers
- env MAKE="$(MAKE) VERSION=$(HPPA64_VERSION)" \
+ env BFD_SOVER_EXT="$(HPPA64_VERSION)" \
$(MAKE) $(NJOBS) -C builddir-hppa64 \
LDFLAGS="-Wl,-z,relro"
touch $@
@@ -877,10 +966,10 @@ ifeq ($(with_cross),yes)
build_stamps += $(foreach ca,$(CROSS_ARCHS), stamps/build.$(ca))
endif
ifneq (,$(TARGET))
- ifneq (,$(findstring static-cross,$(DEB_BUILD_OPTIONS)))
- build_stamps = stamps/build-static-cross
- else
- build_stamps = stamps/build-cross
+ ifeq ($(TARGET),hppa64-linux-gnu)
+ build_stamps = stamps/build-hppa64
+ else
+ build_stamps = stamps/build.$(DEB_TARGET_ARCH)
endif
endif
ifeq ($(BACKPORT),true)
@@ -909,10 +998,10 @@ ifeq ($(with_cross),yes)
endif
ifneq (,$(TARGET))
- ifneq (,$(findstring static-cross,$(DEB_BUILD_OPTIONS)))
- install_stamps = stamps/install-static-cross
- else
- install_stamp = stamps/install-cross
+ ifeq ($(TARGET),hppa64-linux-gnu)
+ install_stamp = stamps/install-hppa64
+ else
+ install_stamp = stamps/install.$(DEB_TARGET_ARCH)
endif
else
install_stamp = stamps/install
@@ -921,11 +1010,11 @@ ifeq ($(BACKPORT),true)
install_stamps :=
endif
install: $(install_stamp)
-stamps/install: checkroot stamps/build $(install_stamps) $(if $(CROSS),debian/strip.cross)
+stamps/install: checkroot stamps/build $(install_stamps)
$(checkdir)
- rm -fr $(d_bin) $(d_dev) $(d_mul) $(d_mdev) $(d_doc) $(d_src)
- $(install_dir) $(d_bin) $(d_dev) $(d_mul) $(d_mdev) $(d_doc) $(d_src)
+ rm -fr $(d_bin) $(d_com) $(d_lib) $(d_nat) $(d_dev) $(d_mul) $(d_mdev) $(d_doc) $(d_src) $(d_bld)
+ $(install_dir) $(d_bin) $(d_com) $(d_lib) $(d_nat) $(d_dev) $(d_mul) $(d_mdev) $(d_doc) $(d_src) $(d_bld)
: # install binutils and -dev stuff
env MAKE="$(MAKE) VERSION=$(SINGLE_VERSION)" \
@@ -933,9 +1022,23 @@ stamps/install: checkroot stamps/build $(install_stamps) $(if $(CROSS),debian/st
CFLAGS="$(CFLAGS)" \
CXXFLAGS="$(CXXFLAGS)" \
LDFLAGS="$(LDFLAGS)" \
- prefix=$(pwd)/$(d_bin)/$(PF) \
- mandir=$(pwd)/$(d_bin)/$(PF)/share/man \
- infodir=$(pwd)/$(d_doc)/$(PF)/share/info install
+ DESTDIR=$(CURDIR)/$(d_bin) install
+
+ $(install_dir) $(d_com)/$(PF)/share
+ mv $(d_bin)/$(PF)/share/locale $(d_com)/$(PF)/share/locale
+
+ $(install_dir) $(d_doc)/$(PF)/share
+ mv $(d_bin)/$(PF)/share/info $(d_doc)/$(PF)/share/info
+
+ $(install_dir) $(d_nat)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
+ mv $(d_bin)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/ldscripts \
+ $(d_nat)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/.
+
+ $(install_dir) $(d_com)/$(PF)/share/man
+ mv $(d_bin)/$(PF)/share/man/man1 $(d_com)/$(PF)/share/man/.
+ for f in $(d_com)/$(PF)/share/man/man1/*.1; do \
+ sed -i -e '/^\.TH /s/[0-9]*-[0-9]*-[0-9]*/$(BUILD_DAY)/' $$f; \
+ done
ifeq (illumos,$(DEB_HOST_ARCH_OS))
ln -sf ld $(pwd)/$(d_bin)/$(PF)/bin/ld_sol2
@@ -948,13 +1051,11 @@ endif
ifeq ($(with_multiarch),yes)
: # now install binutils-multiarch stuff
env MAKE="$(MAKE) VERSION=$(MULTI_VERSION)" \
- $(MAKE) -C builddir-multi \
+ $(MAKE) -C builddir-multi \
CFLAGS="$(CFLAGS)" \
CXXFLAGS="$(CXXFLAGS)" \
LDFLAGS="$(LDFLAGS)" \
- prefix=$(pwd)/$(d_mul)/$(PF) \
- mandir=$(pwd)/$(d_mul)/$(PF)/share/man \
- infodir=$(pwd)/$(d_doc)/$(PF)/share/info install
+ DESTDIR=$(CURDIR)/$(d_mul) install
endif
: # fix bfd.h, removing the safety inclusion guard
@@ -979,12 +1080,9 @@ endif
: # We don't need to distribute everything in binutils and -dev
rm -rf $(d_bin)/$(PF)/include/obstack.h
- rm -f $(d_bin)/$(PF)/man/man1/configure.1
rm -f $(d_doc)/$(PF)/share/info/configure.* $(d_doc)/$(PF)/share/info/standards.*
- : # *sigh*, bugs.debian.org/213524
- rm -f $(d_doc)/$(PF)/share/info/dir*
-ifneq (,$(filter $(DEB_HOST_ARCH),powerpc powerpcspe ppc64 ppc64el))
+ifneq (,$(filter $(DEB_HOST_ARCH),powerpc ppc64 ppc64el))
rm -f $(d_bin)/$(PF)/bin/embedspu
endif
@@ -1009,102 +1107,44 @@ ifeq ($(with_multiarch),yes)
rm -f $(d_mul)/$(PF)/bin/ld.bfd
rm -f $(d_mul)/$(PF)/bin/ld.gold
- ifneq (,$(filter $(DEB_HOST_ARCH),powerpc powerpcspe ppc64 ppc64el))
+ ifneq (,$(filter $(DEB_HOST_ARCH),powerpc ppc64 ppc64el))
rm -f $(d_mul)/$(PF)/bin/embedspu
endif
-
-# FIXME: the search paths for this config isn't correctly generated
- ifeq (0,1)
- : # move $(p_mul)'s ldscripts into $(p_bin)
- for i in $(d_mul)/$(PF)/lib/ldscripts/*; do \
- b=$$(basename $$i); \
- if [ -f $(d_bin)/$(PF)/lib/ldscripts/$$b ]; then \
- if diff -u $(d_bin)/$(PF)/lib/ldscripts/$$b $$i; then \
- rm -f $$i; \
- else \
- echo "ERROR: files differ: $$b"; \
- fi; \
- else \
- mv $$i $(d_bin)/$(PF)/lib/ldscripts/.; \
- fi; \
- done
- : # $(p_mul)'s ldscript should be empty
- -ls -l $(d_mul)/$(PF)/lib/ldscripts
- rm -rf $(d_mul)/$(PF)/lib/ldscripts
- else
- rm -rf $(d_mul)/$(PF)/lib/ldscripts
- endif
+ rm -rf $(d_mul)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/ldscripts
endif
-ifeq ($(with_hppa64),yes)
- : # move $(p_hppa64)'s ldscripts into $(p_bin)
- for i in $(d_hppa64)/$(PF)/lib/ldscripts/*; do \
- b=$$(basename $$i); \
- if [ -f $(d_bin)/$(PF)/lib/ldscripts/$$b ]; then \
- if diff -u $(d_bin)/$(PF)/lib/ldscripts/$$b $$i; then \
- rm -f $$i; \
- else \
- echo "ERROR: files differ: $$b"; \
- fi; \
- else \
- mv $$i $(d_bin)/$(PF)/lib/ldscripts/.; \
- fi; \
- done
- : # $(p_hppa64)'s ldscripts should be empty
- -ls -l $(d_hppa64)/$(PF)/lib/ldscripts
- rm -rf $(d_hppa64)/$(PF)/lib/ldscripts
-endif
-
-# FIXME: some of these ldscripts are built for different cross targets
-# and differ ...
-ifeq (0,1)
- : # move cross ldscripts into $(p_bin)
- for i in debian/binutils-*-*-*/$(PF)/lib/ldscripts/*; do \
- b=$$(basename $$i); \
- if [ -f $(d_bin)/$(PF)/lib/ldscripts/$$b ]; then \
- if diff -u $(d_bin)/$(PF)/lib/ldscripts/$$b $$i; then \
- rm -f $$i; \
- else \
- echo "ERROR: files differ: $$b"; \
- fi; \
- else \
- echo "ERROR: $$i should already exist"; \
- mv $$i $(d_bin)/$(PF)/lib/ldscripts/.; \
- fi; \
- done
- : # cross's ldscripts should be empty
- -ls -l debian/binutils-*-*-*/$(PF)/lib/ldscripts
- rm -rf debian/binutils-*-*-*/$(PF)/lib/ldscripts debian/binutils-*-gnu/$(PF)/lib/ldscripts
-else
- rm -rf debian/binutils-*-*-*/$(PF)/lib/ldscripts debian/binutils-*-gnu/$(PF)/lib/ldscripts
-endif
+# rm -rf debian/binutils-*-*-*/$(PF)/lib/$(DEB_HOST_MULTIARCH)/ldscripts \
+# debian/binutils-*-gnu/$(PF)/lib/$(DEB_HOST_MULTIARCH)/ldscripts
$(install_dir) $(d_dev)/$(PF)/include
mv $(d_bin)/$(PF)/include/* $(d_dev)/$(PF)/include/
- $(install_dir) $(d_bin)/$(PF)/lib/$(DEB_HOST_MULTIARCH) $(d_dev)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
- mv $(d_bin)/$(PF)/lib/*.a $(d_bin)/$(PF)/lib/libbfd.so $(d_bin)/$(PF)/lib/libopcodes.so \
- $(d_dev)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
- mv $(d_bin)/$(PF)/lib/*.so \
- $(d_bin)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
+ $(install_dir) $(d_lib)/$(PF)/lib/$(DEB_HOST_MULTIARCH) $(d_dev)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
+ mv $(d_bin)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.a \
+ $(d_bin)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libbfd.so \
+ $(d_bin)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libopcodes.so \
+ $(d_dev)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
+ mv $(d_bin)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.so \
+ $(d_lib)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
ifeq ($(with_multiarch),yes)
$(install_dir) $(d_mul)/$(PF)/lib/$(DEB_HOST_MULTIARCH) $(d_mdev)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
- mv $(d_mul)/$(PF)/lib/libbfd.so \
+ mv $(d_mul)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libbfd.so \
$(d_mdev)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libbfd-multiarch.so
- mv $(d_mul)/$(PF)/lib/libopcodes.so \
+ mv $(d_mul)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libopcodes.so \
$(d_mdev)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libopcodes-multiarch.so
- mv $(d_mul)/$(PF)/lib/*.so \
- $(d_mul)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/
- rm -f $(d_mul)/$(PF)/lib/*.la $(d_mul)/$(PF)/lib/*.a
- rm -f $(d_mul)/$(PF)/lib*/libiberty*
+ rm -f $(d_mul)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.la \
+ $(d_mul)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.a
+ rm -f $(d_mul)/$(PF)/lib*/$(DEB_HOST_MULTIARCH)/libiberty*
endif
: # Get rid of .la files since libtool obviously has no idea about transient paths
- rm -f $(d_bin)/$(PF)/lib/*.la
+ rm -f $(d_bin)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.la
- chmod ugo-x $(d_bin)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.so
- $(call strip_package, $(p_bin), $(d_bin))
+ chmod ugo-x $(d_lib)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.so
+ifeq ($(with_native),yes)
+ $(call strip_package, $(p_lib), $(d_lib))
+endif
ifeq ($(with_multiarch),yes)
chmod ugo-x $(d_mul)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.so
$(call strip_package, $(p_mul), $(d_mul))
@@ -1119,7 +1159,7 @@ endif
rm -rf $(d_bin)/$(PF)/$(DEB_HOST_GNU_TYPE)
: # Remove windows related manpages
- rm -f $(d_bin)/$(PF)/share/man/man1/{dlltool,nlmconv,windmc,windres}.1
+ rm -f $(d_com)/$(PF)/share/man/man1/{dlltool,nlmconv,windmc,windres}.1
ifeq ($(with_multiarch),yes)
rm -rf $(d_mul)/$(PF)/$(DEB_HOST_GNU_TYPE)
@@ -1128,25 +1168,31 @@ endif
rm -f $(d_bin)/$(PF)/bin/ld.bfd
mv $(d_bin)/$(PF)/bin/ld $(d_bin)/$(PF)/bin/ld.bfd
- mv $(d_bin)/$(PF)/share/man/man1/ld.1 \
- $(d_bin)/$(PF)/share/man/man1/ld.bfd.1
- ln -sf ld.bfd $(d_bin)/$(PF)/bin/ld
- ln -sf $(DEB_HOST_GNU_TYPE)-ld.bfd $(d_bin)/$(PF)/bin/$(DEB_HOST_GNU_TYPE)-ld
- ln -sf ld.bfd.1.gz $(d_bin)/$(PF)/share/man/man1/ld.1.gz
- ln -sf $(DEB_HOST_GNU_TYPE)-ld.bfd.1.gz $(d_bin)/$(PF)/share/man/man1/$(DEB_HOST_GNU_TYPE)-ld.1.gz
+ mv $(d_com)/$(PF)/share/man/man1/ld.1 \
+ $(d_com)/$(PF)/share/man/man1/ld.bfd.1
+ ln -sf $(DEB_HOST_GNU_TYPE)-ld.bfd $(d_bin)/$(PF)/bin/ld
+ $(install_dir) $(d_com)/$(PF)/share/man/man1
+ ln -sf ld.bfd.1.gz $(d_com)/$(PF)/share/man/man1/ld.1.gz
ifeq ($(with_gold),yes)
ln -s ld.gold $(d_bin)/$(PF)/bin/gold
ifeq ($(DEB_BUILD_GNU_TYPE),$(DEB_HOST_GNU_TYPE))
+ find debian -name '*gold' -o -name '*dwp'
if which help2man >/dev/null 2>&1; then \
- help2man -N -n 'The GNU ELF linker' $(d_bin)/$(PF)/bin/ld.gold \
- | sed 's,$(d_bin)/$(PF)/bin/,,g' > debian/ld.gold.1; \
- help2man -N -n 'The DWARF packaging utility' $(d_bin)/$(PF)/bin/dwp \
- | sed 's,$(d_bin)/$(PF)/bin/,,g' > debian/dwp.1; \
+ help2man -N -n 'The GNU ELF linker' \
+ $(d_bin)/$(PF)/bin/ld.gold \
+ | sed -e 's,debian/.*-ld.gold,ld.gold,g' \
+ -e 's/$(DEB_HOST_GNU_TYPE)-//g' \
+ > debian/ld.gold.1; \
+ help2man -N -n 'The DWARF packaging utility' \
+ $(d_bin)/$(PF)/bin/dwp \
+ | sed -e 's,debian/.*-dwp,dwp,g' \
+ -e 's/$(DEB_HOST_GNU_TYPE)-//g' \
+ > debian/dwp.1; \
fi
endif
- cp debian/dwp.1 $(d_bin)/$(PF)/share/man/man1/
- cp debian/ld.gold.1 $(d_bin)/$(PF)/share/man/man1/
- ln -s ld.gold.1.gz $(d_bin)/$(PF)/share/man/man1/gold.1.gz
+ cp debian/dwp.1 $(d_com)/$(PF)/share/man/man1/
+ cp debian/ld.gold.1 $(d_com)/$(PF)/share/man/man1/
+ ln -s ld.gold.1.gz $(d_com)/$(PF)/share/man/man1/gold.1.gz
: # install a symlink for the gold linker
$(install_dir) $(d_bin)/$(PF)/lib/gold-ld
@@ -1161,18 +1207,19 @@ endif
: # Rename non-prefixed binaries to $(DEB_HOST_GNU_TYPE)- prefixed binaries
: # and provide symlinks to the prefixed binaries.
- for i in \
- addr2line ar as c++filt elfedit gprof ld ld.bfd \
- $(if $(with_gold),ld.gold dwp) \
- nm objcopy objdump ranlib readelf size strings strip; \
- do \
- mv $(d_bin)/$(PF)/bin/$$i $(d_bin)/$(PF)/bin/$(DEB_HOST_GNU_TYPE)-$$i; \
+ $(install_dir) $(d_nat)/$(PF)/bin $(d_nat)/$(PF)/share/man/man1
+ for i in $(programs); do \
+ mv $(d_bin)/$(PF)/bin/$$i $(d_nat)/$(PF)/bin/$(DEB_HOST_GNU_TYPE)-$$i; \
ln -sf $(DEB_HOST_GNU_TYPE)-$$i $(d_bin)/$(PF)/bin/$$i; \
- mv $(d_bin)/$(PF)/share/man/man1/$$i.1 $(d_bin)/$(PF)/share/man/man1/$(DEB_HOST_GNU_TYPE)-$$i.1; \
- ln -sf $(DEB_HOST_GNU_TYPE)-$$i.1.gz $(d_bin)/$(PF)/share/man/man1/$$i.1.gz; \
done
+ ln -sf $(DEB_HOST_GNU_TYPE)-ld.gold $(d_nat)/usr/bin/$(DEB_HOST_GNU_TYPE)-gold
+ for i in $(programs); do \
+ ln -sf $$i.1.gz $(d_nat)/$(PF)/share/man/man1/$(DEB_HOST_GNU_TYPE)-$$i.1.gz; \
+ done
+ifeq ($(with_native),yes)
+ $(call strip_package, $(p_nat), $(d_nat))
+endif
ifeq ($(with_multiarch),yes)
- @echo XXXXXXXXXXXXXXXXXXXXXXXXXXXXxx
for i in \
addr2line ar gprof \
nm objcopy objdump ranlib readelf size strings strip; \
@@ -1185,44 +1232,31 @@ endif
ifneq (,$(filter $(DEB_HOST_ARCH),i386 kfreebsd-i386 hurd-i386))
# temporary i586-* symlinks for stretch/sid
ifneq (,$(TRIPLET_SYMLINK))
- for i in \
- addr2line ar as c++filt elfedit gprof ld ld.bfd \
- $(if $(with_gold),ld.gold dwp) \
- nm objcopy objdump ranlib readelf size strings strip; \
- do \
- ln -sf $(DEB_HOST_GNU_TYPE)-$$i $(d_bin)/$(PF)/bin/$(TRIPLET_SYMLINK)-$$i; \
- ln -sf $(DEB_HOST_GNU_TYPE)-$$i.1.gz $(d_bin)/$(PF)/share/man/man1/$(TRIPLET_SYMLINK)-$$i.1.gz; \
+ for i in $(programs); do \
+ ln -sf $(DEB_HOST_GNU_TYPE)-$$i $(d_nat)/$(PF)/bin/$(TRIPLET_SYMLINK)-$$i; \
+ ln -sf $(DEB_HOST_GNU_TYPE)-$$i.1.gz $(d_nat)/$(PF)/share/man/man1/$(TRIPLET_SYMLINK)-$$i.1.gz; \
done
endif
# temporary i486-* symlinks for jessie/sid
ifeq ($(DEB_HOST_GNU_CPU),i586)
gnutype=$(subst i586,i486,$(DEB_HOST_GNU_TYPE)); \
- for i in \
- addr2line ar as c++filt elfedit gprof ld ld.bfd \
- $(if $(with_gold),ld.gold dwp) \
- nm objcopy objdump ranlib readelf size strings strip; \
- do \
- ln -sf $$i $(d_bin)/$(PF)/bin/$$gnutype-$$i; \
- ln -sf $$i.1.gz $(d_bin)/$(PF)/share/man/man1/$$gnutype-$$i.1.gz; \
+ for i in $(programs); do \
+ ln -sf $(DEB_HOST_GNU_TYPE)-$$i $(d_nat)/$(PF)/bin/$$gnutype-$$i; \
+ ln -sf $(DEB_HOST_GNU_TYPE)-$$i.1.gz $(d_nat)/$(PF)/share/man/man1/$$gnutype-$$i.1.gz; \
done
endif
# for backports to wheezy and squeeze
ifeq ($(DEB_HOST_GNU_CPU),i486)
gnutype=$(subst i486,i586,$(DEB_HOST_GNU_TYPE)); \
- for i in \
- addr2line ar as c++filt elfedit gprof ld ld.bfd \
- $(if $(with_gold),ld.gold dwp) \
- nm objcopy objdump ranlib readelf size strings strip; \
- do \
- ln -sf $(DEB_HOST_GNU_TYPE)-$$i $(d_bin)/$(PF)/bin/$$gnutype-$$i; \
- ln -sf $(DEB_HOST_GNU_TYPE)-$$i.1.gz $(d_bin)/$(PF)/share/man/man1/$$gnutype-$$i.1.gz; \
+ for i in $(programs); do \
+ ln -sf $(DEB_HOST_GNU_TYPE)-$$i $(d_nat)/$(PF)/bin/$$gnutype-$$i; \
+ ln -sf $(DEB_HOST_GNU_TYPE)-$$i.1.gz $(d_nat)/$(PF)/share/man/man1/$$gnutype-$$i.1.gz; \
done
endif
endif
-
touch $@
-stamps/install-hppa64: checkroot stamps/build-hppa64 $(if $(CROSS),debian/strip.cross)
+stamps/install-hppa64: checkroot stamps/build-hppa64
$(checkdir)
rm -fr $(d_hppa64)
@@ -1235,9 +1269,7 @@ stamps/install-hppa64: checkroot stamps/build-hppa64 $(if $(CROSS),debian/strip.
CFLAGS="$(CFLAGS)" \
CXXFLAGS="$(CXXFLAGS)" \
LDFLAGS="$(LDFLAGS)" \
- prefix=$(pwd)/$(d_hppa64)/$(PF)/ \
- mandir=$(pwd)/$(d_hppa64)/$(PF)/share/man \
- infodir=$(pwd)/$(d_hppa64)/$(PF)/share/info install
+ DESTDIR=$(CURDIR)/$(d_hppa64) install
: # move shared libs to the standard path
mv $(d_hppa64)/$(PF)/$(DEB_HOST_GNU_TYPE)/hppa64-linux-gnu/lib/lib*-*.so \
@@ -1251,17 +1283,18 @@ stamps/install-hppa64: checkroot stamps/build-hppa64 $(if $(CROSS),debian/strip.
rm -rf $(d_hppa64)/$(PF)/hppa-linux-gnu
rm -rf $(d_hppa64)/$(PF)/lib/libiberty.a
+ : # replace hard links with soft links
+ for i in $(d_hppa64)/usr/hppa64-linux-gnu/bin/*; do \
+ ln -sf ../../bin/hppa64-linux-gnu-$$(basename $$i) $$i; \
+ done
+ ln -sf hppa64-linux-gnu-ld.bfd $(d_hppa64)/usr/bin/hppa64-linux-gnu-ld
+
$(call strip_package, $(p_hppa64), $(d_hppa64))
chmod ugo-x $(d_hppa64)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.so
: # remove RPATH
chrpath -k -d $$(file $(d_hppa64)/usr/bin/*|awk -F: '/ ELF/ {print $$1}')
- : # replace hard links with soft links
- for i in $(d_hppa64)/usr/hppa64-linux-gnu/bin/*; do \
- ln -sf ../../bin/hppa64-linux-gnu-$$(basename $$i) $$i; \
- done
-
: # Don't want /usr/<arch>-linux to exist in any package
rm -rf $(d_hppa64)/$(PF)/$(DEB_HOST_GNU_TYPE)
@@ -1319,11 +1352,15 @@ endif # ifndef BACKPORT
xargs -0r touch --no-dereference --date='$(BUILD_DATE)' && \
find $(source_files) -type f -print0 | LC_ALL=C sort -z | \
tar --null -T - -c --xz --exclude=CVS --mode=go=rX,u+rw,a-s \
+ --xform='s=^[^/]*\/=binutils-$(VERSION)/=' \
-f $(pwd)/$(d_src)/$(PF)/src/binutils/binutils-$(VERSION).tar.xz \
$(source_files)
tar cf - $$(find './debian' -mindepth 1 \( \
-path './debian/binutils*' -type d -prune -o \
+ -path './debian/libbinutils' -type d -prune -o \
+ -path './debian/binutils*-dbg' -type d -prune -o \
+ -path './debian/libbinutils-dbg' -type d -prune -o \
-path './debian/patches' -prune -o \
-path './debian/tmp*' -prune -o \
-path './debian/.bzr*' -prune -o \
@@ -1340,6 +1377,15 @@ endif # ifndef BACKPORT
xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg --build $(d_src) ..
+
+ $(install_dir) $(d_bld)/DEBIAN $(d_bld)/$(PF)/share/doc/
+ ln -sf $(p_com) $(d_bld)/$(PF)/share/doc/$(p_bld)
+ dpkg-gencontrol -P$(d_bld) -p$(p_bld) -Vbinutils:minver=$(min_ver)
+ chown -R root:root $(d_bld)
+ chmod -R go=rX $(d_bld)
+ find $(d_bld) -depth -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
+ dpkg --build $(d_bld) ..
endif
###############################################################################
@@ -1351,7 +1397,7 @@ endif
binary.%: stamps/install.% install
rm -rf $(D_CROSS)/$(PF)/share/info
- rm -rf $(D_CROSS)/DEBIAN
+ rm -rf $(D_CROSS)/DEBIAN $(D_CROSS)-dbg/DEBIAN
: # make lintian happy
$(install_dir) $(D_CROSS)/$(PF)/share/lintian/overrides
@@ -1372,6 +1418,9 @@ ifeq ($(with_check),yes)
$(install_file) test-summary-$* \
$(D_CROSS)/$(PF)/share/doc/$(P_CROSS)/test-summary
gzip -9nf $(D_CROSS)/$(PF)/share/doc/$(P_CROSS)/test-summary
+ $(install_dir) $(D_CROSS)/$(PF)/share/doc/$(p_bin)
+ ln -sf ../$(P_CROSS)/test-summary.gz \
+ $(D_CROSS)/$(PF)/share/doc/$(p_bin)/test-summary-$*.gz
endif
for pkg in bfd gas gprof ld; do \
@@ -1379,35 +1428,50 @@ endif
$(D_CROSS)/$(PF)/share/doc/$(P_CROSS)/$$pkg; \
done
- $(install_dir) $(D_CROSS)/DEBIAN
+ $(install_dir) $(D_CROSS)/DEBIAN $(D_CROSS)-dbg/DEBIAN
if [ "$(is_rc)" = yes ]; then \
nver=$$(echo $(DEB_UPSTREAM) | awk -F. '{ OFS="."; NF--; $$NF=$$NF+1; print }'); \
else \
- nver=$$(echo $(DEB_UPSTREAM) | awk -F. '{ OFS="."; $$NF=$$NF+1; print }'); \
+ nver=$$(echo $(DEB_UPSTREAM) | awk -F. '{ OFS="."; if (NF > 2) $$NF=$$NF+1; else $$++NF=1; print }'); \
fi; \
date_ext=$(DATE_EXT); \
[ "$(is_rc)" = yes ] && date_ext=; \
- sed -e 's/@VER@/$(VERSION)/g' \
- -e 's/@DEB_VER@/$(DEB_VERSION)/g' \
- -e 's/@DEB_UVER@/$(DEB_UPSTREAM)/g' \
- -e "s/@DEB_NVER@/$$nver/g" \
- -e "s/@DATE_EXT@/$$date_ext/g" \
- -e 's/@ARCH@/$*/g' \
- -e "s/@PKG@/$(P_CROSS)/g" \
- debian/binutils-cross.shlibs.in > $(D_CROSS)/DEBIAN/shlibs
$(install_file) debian/binutils.triggers $(D_CROSS)/DEBIAN/triggers
rm -f debian/substvars
dpkg-shlibdeps $(D_CROSS)/$(PF)/bin/*
dpkg-gencontrol -P$(D_CROSS) -p$(P_CROSS) \
-VBuilt-Using="$(shell dpkg-query -f '$${source:Package} (= $${source:Version}), ' -W binutils-source)"
- chown -R root:root $(D_CROSS)
- chmod -R go=rX $(D_CROSS)
- find $(D_CROSS) -depth -newermt '$(BUILD_DATE)' -print0 | \
+ cd $(D_CROSS) && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
+ dpkg-gencontrol -P$(D_CROSS)-dbg -p$(P_CROSS)-dbg
+ cd $(D_CROSS)-dbg && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
+ chown -R root:root $(D_CROSS) $(D_CROSS)-dbg
+ chmod -R go=rX $(D_CROSS) $(D_CROSS)-dbg
+ find $(D_CROSS) $(D_CROSS)-dbg -depth -newermt '$(BUILD_DATE)' -print0 | \
xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg --build $(D_CROSS) ..
+ dpkg --build $(D_CROSS)-dbg ..
+
+binary-for-host: checkroot
+ $(checkdir)
+
+ rm -fr $(d_hst)
+ $(install_dir) $(d_hst)/DEBIAN/ $(d_hst)/$(PF)/share/doc/
+ ln -sf $(p_com) $(d_hst)/$(PF)/share/doc/$(p_hst)
-binary-arch: checkroot build install \
+ rm -f debian/substvars
+ $(for_target) dpkg-gencontrol -P$(d_hst) -p$(p_hst) \
+ -Vbinutils:native=$(if $(TARGET),$(p_cross),$(p_nat)) \
+ -Vbinutils:minver=$(min_ver)
+
+ chown -R root:root $(d_hst)
+ chmod -R go=rX $(d_hst)
+
+ find $(d_hst) -depth -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
+ dpkg --build $(d_hst) ..
+
+binary-arch: checkroot build install binary-for-host \
$(if $(filter yes, $(with_cross)),$(foreach ca,$(CROSS_ARCHS), binary.$(ca)))
$(checkdir)
@@ -1442,7 +1506,7 @@ else
if [ "$(is_rc)" = yes ]; then \
nver=$$(echo $(DEB_UPSTREAM) | awk -F. '{ OFS="."; NF--; $$NF=$$NF+1; print }'); \
else \
- nver=$$(echo $(DEB_UPSTREAM) | awk -F. '{ OFS="."; $$NF=$$NF+1; print }'); \
+ nver=$$(echo $(DEB_UPSTREAM) | awk -F. '{ OFS="."; if (NF > 2) $$NF=$$NF+1; else $$++NF=1; print }'); \
fi; \
for i in debian/*.in; do \
case "$$i" in debian/control.in|debian/control.cross.in) continue; esac; \
@@ -1475,8 +1539,15 @@ ifeq ($(with_hppa64),yes)
endif
: # make lintian happy
- $(install_file) -D debian/$(p_bin).overrides \
+ $(install_file) -D debian/$(p_com).overrides \
+ $(d_com)/$(PF)/share/lintian/overrides/$(p_com)
+ $(install_file) -D debian/$(p_lib).overrides \
+ $(d_lib)/$(PF)/share/lintian/overrides/$(p_lib)
+ $(install_file) -D debian/binutils.overrides \
$(d_bin)/$(PF)/share/lintian/overrides/$(p_bin)
+ $(install_dir) $(d_nat)/$(PF)/share/lintian/overrides
+ sed 's/@PKG@/$(p_nat)/' debian/binutils-triplet.overrides \
+ > $(d_nat)/$(PF)/share/lintian/overrides/$(p_nat)
ifeq ($(with_multiarch),yes)
$(install_file) -D debian/$(p_mul).overrides \
$(d_mul)/$(PF)/share/lintian/overrides/$(p_mul)
@@ -1490,13 +1561,19 @@ endif
: # install maintainer scripts
$(install_dir) $(d_bin)/DEBIAN
- $(install_file) debian/binutils.triggers $(d_bin)/DEBIAN/triggers
- $(install_file) debian/binutils.shlibs $(d_bin)/DEBIAN/shlibs
+
+ $(install_dir) $(d_lib)/DEBIAN $(d_lib)-dbg/DEBIAN
+ $(install_file) debian/binutils.triggers $(d_lib)/DEBIAN/triggers
+ $(install_file) debian/libbinutils.shlibs $(d_lib)/DEBIAN/shlibs
+
+ $(install_dir) $(d_com)/DEBIAN
+
+ $(install_dir) $(d_nat)/DEBIAN $(d_nat)-dbg/DEBIAN
$(install_dir) $(d_dev)/DEBIAN
ifeq ($(with_multiarch),yes)
- $(install_dir) $(d_mul)/DEBIAN
+ $(install_dir) $(d_mul)/DEBIAN $(d_mul)-dbg/DEBIAN
$(install_script) debian/binutils-multiarch.preinst $(d_mul)/DEBIAN/preinst
$(install_script) debian/binutils-multiarch.postinst $(d_mul)/DEBIAN/postinst
$(install_script) debian/binutils-multiarch.prerm $(d_mul)/DEBIAN/prerm
@@ -1507,9 +1584,8 @@ ifeq ($(with_multiarch),yes)
endif
ifeq ($(with_hppa64),yes)
- $(install_dir) $(d_hppa64)/DEBIAN
+ $(install_dir) $(d_hppa64)/DEBIAN $(d_hppa64)-dbg/DEBIAN
$(install_file) debian/binutils.triggers $(d_hppa64)/DEBIAN/triggers
- $(install_file) debian/$(p_hppa64).shlibs $(d_hppa64)/DEBIAN/shlibs
endif
: # install docs
@@ -1517,6 +1593,16 @@ endif
$(install_file) debian/changelog $(d_bin)/$(PF)/share/doc/$(p_bin)/changelog.Debian
$(install_file) debian/copyright $(d_bin)/$(PF)/share/doc/$(p_bin)/
+ $(install_dir) $(d_com)/$(PF)/share/doc/$(p_com)/
+ $(install_file) debian/changelog $(d_com)/$(PF)/share/doc/$(p_com)/changelog.Debian
+ $(install_file) debian/copyright $(d_com)/$(PF)/share/doc/$(p_com)/
+
+ $(install_dir) $(d_lib)/$(PF)/share/doc/
+ ln -sf $(p_com) $(d_lib)/$(PF)/share/doc/$(p_lib)
+
+ $(install_dir) $(d_nat)/$(PF)/share/doc/
+ ln -sf $(p_lib) $(d_nat)/$(PF)/share/doc/$(p_nat)
+
$(install_dir) $(d_dev)/$(PF)/share/doc/
ln -sf $(p_bin) $(d_dev)/$(PF)/share/doc/$(p_dev)
ifeq ($(with_multiarch),yes)
@@ -1534,45 +1620,71 @@ ifeq ($(DEB_BUILD_GNU_TYPE),$(DEB_HOST_GNU_TYPE))
ifeq ($(with_check),yes)
: # remove user and date from test-summary for reproducible builds
sed -i -e '/Test Run By/Id' $(pwd)/test-summary
- $(install_file) $(pwd)/test-summary $(d_bin)/$(PF)/share/doc/$(p_bin)/
+ $(install_dir) $(d_nat)/$(PF)/share/doc/$(p_bin)
+ $(install_file) test-summary \
+ $(d_nat)/$(PF)/share/doc/$(p_bin)/test-summary-$(DEB_HOST_ARCH)
+ gzip -9nf \
+ $(d_nat)/$(PF)/share/doc/$(p_bin)/test-summary-$(DEB_HOST_ARCH)
endif
endif
+ $(install_dir) $(d_com)/$(PF)/share/doc/$(p_bin)
$(install_file) binutils/NEWS debian/README.cross \
- $(d_bin)/$(PF)/share/doc/$(p_bin)/
+ $(d_com)/$(PF)/share/doc/$(p_bin)/
- $(install_file) binutils/ChangeLog $(d_bin)/$(PF)/share/doc/$(p_bin)/changelog
+ $(install_file) binutils/ChangeLog $(d_com)/$(PF)/share/doc/$(p_bin)/changelog
for pkg in bfd gas gprof ld; do \
- $(install_dir) $(d_bin)/$(PF)/share/doc/$(p_bin)/$$pkg; \
+ $(install_dir) $(d_com)/$(PF)/share/doc/$(p_bin)/$$pkg; \
done
$(install_file) bfd/ChangeLog bfd/PORTING bfd/TODO \
- $(d_bin)/$(PF)/share/doc/$(p_bin)/bfd/
- $(install_file) gas/ChangeLog gas/NEWS $(d_bin)/$(PF)/share/doc/$(p_bin)/gas/
+ $(d_com)/$(PF)/share/doc/$(p_bin)/bfd/
+ $(install_file) gas/ChangeLog gas/NEWS $(d_com)/$(PF)/share/doc/$(p_bin)/gas/
$(install_file) gprof/ChangeLog gprof/TODO gprof/TEST \
- $(d_bin)/$(PF)/share/doc/$(p_bin)/gprof/
+ $(d_com)/$(PF)/share/doc/$(p_bin)/gprof/
$(install_file) ld/ChangeLog ld/TODO ld/NEWS \
- $(d_bin)/$(PF)/share/doc/$(p_bin)/ld/
+ $(d_com)/$(PF)/share/doc/$(p_bin)/ld/
: # These only exist in H. J. Lu releases not GNU ones.
for dir in binutils bfd gas gprof ld; do \
if [ -f $$dir/ChangeLog.linux ]; then \
- $(install_file) $$dir/ChangeLog.linux $(d_bin)/$(PF)/share/doc/$(p_bin)/$$dir/; \
+ $(install_file) $$dir/ChangeLog.linux $(d_com)/$(PF)/share/doc/$(p_bin)/$$dir/; \
fi; \
done
: # Copy bbconv.pl to the doc dir for use by interested people
- $(install_file) gprof/bbconv.pl $(d_bin)/$(PF)/share/doc/$(p_bin)/gprof/.
+ $(install_file) gprof/bbconv.pl $(d_com)/$(PF)/share/doc/$(p_bin)/gprof/.
: # Compress stuff that needs it
- gzip -9n $(d_bin)/$(PF)/share/man/man1/*.1
- find $(d_bin)/$(PF)/share/doc/$(p_bin)/ -type f ! -name copyright -a ! -name bbconv.pl | xargs gzip -9n
+ gzip -9n $(d_bin)/$(PF)/share/doc/$(p_bin)/changelog.Debian
+ find $(d_com)/$(PF)/share/doc/$(p_bin)/ -type f ! -name bbconv.pl | xargs gzip -9n
+ gzip -9n $(d_com)/$(PF)/share/doc/$(p_com)/changelog.Debian
+ gzip -9n $(d_com)/$(PF)/share/man/man1/*.1
: # Finish it all up
- find $(d_bin) -type f | xargs file | grep ELF | cut -d: -f 1 | xargs dpkg-shlibdeps
- dpkg-gencontrol -P$(d_bin) -p$(p_bin) $(CONFLICTS_TARGET_$(DEB_HOST_ARCH)) $(gold_provides)
+ dpkg-gencontrol -P$(d_bin) -p$(p_bin) \
+ $(CONFLICTS_TARGET_$(DEB_HOST_ARCH)) $(gold_provides) \
+ -Vbinutils:native=$(p_nat)
cd $(d_bin) && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
rm -f debian/substvars
+ find $(d_lib) -type f | xargs file | grep ELF | cut -d: -f 1 | xargs dpkg-shlibdeps
+ dpkg-gencontrol -P$(d_lib) -p$(p_lib)
+ cd $(d_lib) && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
+ dpkg-gencontrol -P$(d_lib)-dbg -p$(p_lib)-dbg
+ cd $(d_lib)-dbg && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
+
+ rm -f debian/substvars
+ dpkg-gencontrol -P$(d_com) -p$(p_com)
+ cd $(d_com) && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
+
+ rm -f debian/substvars
+ find $(d_nat) -type f | xargs file | grep ELF | cut -d: -f 1 | xargs dpkg-shlibdeps
+ dpkg-gencontrol -P$(d_nat) -p$(p_nat) -VextraDepends='libbinutils (= $${binary:Version})'
+ cd $(d_nat) && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
+ dpkg-gencontrol -P$(d_nat)-dbg -p$(p_nat)-dbg -VextraDepends='libbinutils (= $${binary:Version})'
+ cd $(d_nat)-dbg && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
+
+ rm -f debian/substvars
dpkg-gencontrol -P$(d_dev) -p$(p_dev)
cd $(d_dev) && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
@@ -1581,6 +1693,8 @@ ifeq ($(with_multiarch),yes)
find $(d_mul) -type f | xargs file | grep ELF | cut -d: -f 1 | xargs dpkg-shlibdeps
dpkg-gencontrol -P$(d_mul) -p$(p_mul)
cd $(d_mul) && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
+ dpkg-gencontrol -P$(d_mul)-dbg -p$(p_mul)-dbg
+ cd $(d_mul)-dbg && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
rm -f debian/substvars
mkdir -p $(d_mdev)/DEBIAN
@@ -1593,22 +1707,42 @@ ifeq ($(with_hppa64),yes)
find $(d_hppa64) -type f | xargs file | grep ELF | cut -d: -f 1 | xargs dpkg-shlibdeps
dpkg-gencontrol -P$(d_hppa64) -p$(p_hppa64)
cd $(d_hppa64) && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
+ dpkg-gencontrol -P$(d_hppa64)-dbg -p$(p_hppa64)-dbg
+ cd $(d_hppa64)-dbg && find -type f ! -regex './DEBIAN/.*' -printf '%P\n' | LC_ALL=C sort | xargs md5sum > DEBIAN/md5sums
endif
- chown -R root:root $(d_bin) $(d_dev)
- chmod -R go=rX $(d_bin) $(d_dev)
+ chown -R root:root $(d_bin) $(d_com) $(d_lib) $(d_lib)-dbg $(d_nat) $(d_nat)-dbg $(d_dev)
+ chmod -R go=rX $(d_bin) $(d_com) $(d_lib) $(d_lib)-dbg $(d_nat) $(d_nat)-dbg $(d_dev)
find $(d_bin) -depth -newermt '$(BUILD_DATE)' -print0 | \
xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg --build $(d_bin) ..
+ find $(d_com) -depth -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
+ dpkg --build $(d_com) ..
+ find $(d_lib) -depth -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
+ dpkg --build $(d_lib) ..
+ find $(d_lib)-dbg -depth -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
+ dpkg --build $(d_lib)-dbg ..
+ find $(d_nat) -depth -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
+ dpkg --build $(d_nat) ..
+ find $(d_nat)-dbg -depth -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
+ dpkg --build $(d_nat)-dbg ..
find $(d_dev) -depth -newermt '$(BUILD_DATE)' -print0 | \
xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg --build $(d_dev) ..
ifeq ($(with_multiarch),yes)
- chown -R root:root $(d_mul)
- chmod -R go=rX $(d_mul)
+ chown -R root:root $(d_mul) $(d_mul)-dbg
+ chmod -R go=rX $(d_mul) $(d_mul)-dbg
find $(d_mul) -depth -newermt '$(BUILD_DATE)' -print0 | \
xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg --build $(d_mul) ..
+ find $(d_mul)-dbg -depth -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
+ dpkg --build $(d_mul)-dbg ..
chown -R root:root $(d_mdev)
chmod -R go=rX $(d_mdev)
@@ -1617,110 +1751,20 @@ ifeq ($(with_multiarch),yes)
dpkg --build $(d_mdev) ..
endif
ifeq ($(with_hppa64),yes)
- chown -R root:root $(d_hppa64)
- chmod -R go=rX $(d_hppa64)
+ chown -R root:root $(d_hppa64)-dbg
+ chmod -R go=rX $(d_hppa64) $(d_hppa64)-dbg
find $(d_hppa64) -depth -newermt '$(BUILD_DATE)' -print0 | \
xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
dpkg --build $(d_hppa64) ..
+ find $(d_hppa64)-dbg -depth -newermt '$(BUILD_DATE)' -print0 | \
+ xargs -0r touch --no-dereference --date='$(BUILD_DATE)'
+ dpkg --build $(d_hppa64)-dbg ..
endif
+ @echo '==================== Build finished ===================='
+ ps aux
endif # Process the following only if $(TARGET) is set
endif # ifndef BACKPORT
-###############################################################################
-
-#################
-# cross targets #
-#################
-
-# Process the following only if $(TARGET) is set
-ifneq (,$(TARGET))
-
-p_cross = $(subst _,-,binutils-$(TARGET))
-d_cross = debian/$(p_cross)
-
-#-----------------------------------------------------------------
-# sysroot options
-ifdef WITH_SYSROOT
- with_sysroot = $(WITH_SYSROOT)
-endif
-ifdef WITH_BUILD_SYSROOT
- with_build_sysroot = $(WITH_BUILD_SYSROOT)
-endif
-
-ifneq ($(with_sysroot),)
- CONFARGS += --with-sysroot=$(with_sysroot)
-endif
-ifneq ($(with_build_sysroot),)
- CONFARGS += --with-build-sysroot=$(with_build_sysroot)
-endif
-ifeq ($(with_gold),yes)
- CONFARGS += --enable-ld=default --enable-gold
-endif
-
-stamps/configure-cross: stamps/patch
- $(checkdir)
- test "" != "$(TARGET)"
- rm -rf stamps/configure-cross builddir-$(TARGET)
- mkdir builddir-$(TARGET)
- cd builddir-$(TARGET) \
- && env CC="$(CC)" CXX="$(CXX)" CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS)" ../configure \
- $(CONFARGS) \
- --target=$(TARGET)
- touch $@
-
-stamps/build-cross: stamps/configure-cross
- $(checkdir)
- test "" != "$(TARGET)"
- env MAKE="$(MAKE) VERSION=$(VERSION)-$(DEB_TARGET_ARCH)" \
- $(MAKE) -C builddir-$(TARGET) $(NJOBS) \
- CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS)"
- touch $@
-
-stamps/install-cross: stamps/build-cross
- $(checkdir)
- test "" != "$(TARGET)"
- rm -rf $(d_cross)
- env MAKE="$(MAKE) VERSION=$(VERSION)-$(DEB_TARGET_ARCH)" \
- $(MAKE) -C builddir-$(TARGET) prefix=$(pwd)/$(d_cross)/$(PF) \
- mandir=$(pwd)/$(d_cross)/$(PF)/share/man install
- rm -rf $(d_cross)/$(PF)/lib* $(d_cross)/$(PF)/info $(d_cross)/$(PF)/share/locale
-
- mkdir -p $(d_cross)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
- mv $(d_cross)/$(PF)/$(DEB_HOST_GNU_TYPE)/$(TARGET)/lib/*.so \
- $(d_cross)/$(PF)/lib/$(DEB_HOST_MULTIARCH)
- $(call strip_package, $(p_cross),$(d_cross))
- chmod ugo-x $(d_cross)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/*.so
-
- : # Get rid of .la files since libtool obviously has no idea about transient paths
- rm -f $(d_cross)/$(PF)/$(DEB_HOST_GNU_TYPE)/$(TARGET)/lib/*.la
-
- : # don't ship header files and static libs
- rm -rf $(d_cross)/$(PF)/$(DEB_HOST_GNU_TYPE)/$(TARGET)
-
- gzip -9n $(d_cross)/$(PF)/share/man/man1/*
- touch $@
-
-stamps/configure-host-cross: stamps/configure-cross
- $(checkdir)
- test "" != "$(TARGET)"
- $(MAKE) configure-host -C builddir-$(TARGET) $(NJOBS) \
- CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS)"
- touch $@
-
-stamps/build-static-cross: stamps/configure-host-cross
- $(checkdir)
- test "" != "$(TARGET)"
- $(MAKE) -C builddir-$(TARGET) $(NJOBS) \
- CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS) -all-static"
- touch $@
-
-stamps/install-static-cross: stamps/build-static-cross stamps/install-cross
-
-binary-cross:
- @echo "Please use dpkg-buildpackage instead of calling binary-cross directly; see README.cross"
- @false
-
-endif # ifneq ($(TARGET),)
###############################################################################
@@ -1728,19 +1772,55 @@ define checkdir
test -f bfd/elf32.c -a -f debian/rules
endef
+# if which pkg_create_dbgsym >/dev/null 2>&1; then \
+# pkg_create_dbgsym $1 $2; \
+# fi
+
ifeq ($(with_strip),yes)
# strip_package: <pkgname> <install-dir> <???>
define strip_package
- : # Strip shared libraries
- if which pkg_create_dbgsym >/dev/null 2>&1; then \
- pkg_create_dbgsym $1 $2; \
- fi
- $(STRIP) --strip-unneeded $2/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libbfd-*so
- $(STRIP) --strip-unneeded $2/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libopcodes-*so
- $(STRIP) $$(file $2/$(PF)/bin/* |awk -F: '$$0 !~ /script/ {print $$1}')
+ $(install_dir) $(strip $2)-dbg/usr/share/doc/
+ ln -sf $(strip $1) $(strip $2)-dbg/usr/share/doc/$(strip $1)-dbg
+ : # Strip shared libraries and binaries
+ set -e; \
+ for i in \
+ $(strip $2)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libbfd-*so \
+ $(strip $2)/$(PF)/lib/$(DEB_HOST_MULTIARCH)/libopcodes-*so \
+ $$(file $(strip $2)/$(PF)/bin/* |awk -F: '$$0 !~ /script/ {print $$1}'); \
+ do \
+ test ! -h $$i || continue; test -f $$i || continue; \
+ files="$$files $$i"; \
+ done; \
+ mkdir -p $(strip $2)-dbg/usr/lib/debug/.dwz/$(DEB_HOST_MULTIARCH); \
+ dwz=usr/lib/debug/.dwz/$(DEB_HOST_MULTIARCH)/$(strip $1).debug; \
+ dwz -m $(strip $2)-dbg/$$dwz -M /$$dwz \
+ $$files; \
+ $(CROSS)objcopy --compress-debug-sections $(strip $2)-dbg/$$dwz; \
+ for i in $$files; do \
+ b_id=$$(LC_ALL=C $(CROSS)readelf -n $$i | sed -n 's/ *Build ID: *\([0-9a-f][0-9a-f]*\)/\1/p'); \
+ if [ -z "$$b_id" ]; then \
+ id=$$(echo $$i | sed -r 's,debian/[^/]+,$2-dbg/usr/lib/debug,'); \
+ echo strip $$i; \
+ mkdir -p $$(dirname $$id); \
+ $(CROSS)objcopy --only-keep-debug $$i $$id; \
+ chmod 644 $$id; \
+ $(STRIP) $$i; \
+ $(CROSS)objcopy --add-gnu-debuglink $$id $$i; \
+ else \
+ echo "ID: $${b_id} -> $$(echo $$i | sed 's,$(strip $2),,')"; \
+ d=usr/lib/debug/.build-id/$${b_id:0:2}; \
+ f=$${b_id:2}.debug; \
+ mkdir -p $(strip $2)-dbg/$$d; \
+ $(CROSS)objcopy --only-keep-debug --compress-debug-sections $$i $(strip $2)-dbg/$$d/$$f; \
+ chmod 644 $(strip $2)-dbg/$$d/$$f; \
+ $(STRIP) $$i; \
+ fi; \
+ done
endef
else
define strip_package
+ $(install_dir) $(strip $2)-dbg/usr/share/doc/
+ ln -sf $(strip $1) $(strip $2)-dbg/usr/share/doc/$(strip $1)-dbg
endef
endif
@@ -1766,4 +1846,4 @@ checkroot:
.PHONY: binary binary-arch binary-indep clean checkroot
-.PRECIOUS: stamps/patch stamps/configure.% stamps/build.% stamps/install.%
+.PRECIOUS: stamps/configure.% stamps/build.% stamps/install.%
diff --git a/debian/source.lintian-overrides b/debian/source.lintian-overrides
index 6d2e47b..5662f66 100644
--- a/debian/source.lintian-overrides
+++ b/debian/source.lintian-overrides
@@ -3,3 +3,10 @@ binutils source: binaries-have-file-conflict
# wrong positive
binutils source: license-problem-gfdl-invariants
+
+# yes, we know what we are doing
+debian-rules-sets-dpkg-architecture-variable
+
+# test data
+binutils source: source-is-missing binutils/testsuite/binutils-all/nfp/test1_nfp6000.nffw
+binutils source: source-is-missing binutils/testsuite/binutils-all/nfp/test2_nfp6000.nffw
diff --git a/debian/source/format b/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)
diff --git a/debian/strip.cross.in b/debian/strip.cross.in
deleted file mode 100644
index df2a6e3..0000000
--- a/debian/strip.cross.in
+++ /dev/null
@@ -1,3 +0,0 @@
-#! /bin/sh
-
-__TARGET__strip --remove-section=.comment --remove-section=.note $*
diff --git a/debian/tests/build b/debian/tests/build
index b23e556..01b1248 100644
--- a/debian/tests/build
+++ b/debian/tests/build
@@ -1 +1,12 @@
-#!/bin/true
+#!/bin/sh
+
+set -e
+
+CPUS=$(getconf _NPROCESSORS_ONLN)
+case "$CPUS" in
+ [0-9]|[0-9][0-9]|[0-9][0-9][0-9]) ;;
+ *) CPUS=1
+esac
+
+set -x
+DEB_BUILD_OPTIONS="parallel=$CPUS nohppa nomult nocross" dpkg-buildpackage -d -B --no-sign
diff --git a/debian/tests/control b/debian/tests/control
index 26d0ba8..9b8825f 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -1,6 +1,14 @@
Tests: build
-Depends: build-essential
-Restrictions: build-needed
+# this doesn't work well, without building -hppa, -multiarch and -cross packages
+#Depends: build-essential
+#Restrictions: build-needed
+Depends: build-essential,
+ fakeroot,
+ autoconf (>= 2.64),
+ bison, flex, gettext, texinfo, dejagnu, quilt, chrpath, dwz,
+ python3, file, xz-utils, lsb-release, zlib1g-dev, procps
+# build process emits warnings on stderr
+Restrictions: allow-stderr
Tests: libc-link
Depends: build-essential