Statically link lib{bfd,iberty}
authorStephane Glondu <steph@glondu.net>
Fri, 4 Sep 2020 04:23:06 +0000 (06:23 +0200)
committerRaspbian forward porter <root@raspbian.org>
Sat, 7 Nov 2020 23:17:21 +0000 (23:17 +0000)
Gbp-Pq: Name 0008-Statically-link-lib-bfd-iberty.patch

configure.ac

index ab1e1888b323d7f691dfcde72725e6650d3fd40e..b3ebe744d00147349d3299a3933545a21669f1e0 100644 (file)
@@ -1680,6 +1680,10 @@ AS_IF([test x"$with_bfd" != "xno"],
     'ocamlobjinfo' will be unable to display info on .cmxs files.
     ]))])
 
+## Statically link libbfd and libiberty to avoid a versioned dependency
+## too constrained on libbinutils
+bfd_ldlibs="$(echo $bfd_ldlibs | sed 's/-lbfd/-Wl,-Bstatic -lbfd -liberty -Wl,-Bdynamic -lz -ldl/')"
+
 ## Does the assembler support debug prefix map and CFI directives
 as_has_debug_prefix_map=false
 asm_cfi_supported=false