Call ld with proper flags
authorStefano Zacchiroli <zack@debian.org>
Tue, 19 May 2009 15:23:34 +0000 (17:23 +0200)
committerStéphane Glondu <glondu@debian.org>
Fri, 25 Jan 2019 13:59:28 +0000 (14:59 +0100)
Filter linkflags passed to ld by ocamlopt -pack and -output-obj
to remove the "-Wl," parts, which are only used when ocamlopt calls
gcc.

Gbp-Pq: Name 0002-Call-ld-with-proper-flags.patch

configure

index d67672ef3c83a15a0c36f5563491131fd0df658a..c0024a9c976daf084c4ef4ca3e417970cf4091a0 100755 (executable)
--- a/configure
+++ b/configure
@@ -2049,7 +2049,7 @@ echo "DYNLINKOPTS=$dllib" >> Makefile
 echo "OTHERLIBRARIES=$otherlibraries" >> Makefile
 echo "CC_PROFILE=$cc_profile" >> Makefile
 echo "SYSTHREAD_SUPPORT=$systhread_support" >> Makefile
-echo "PACKLD=$partialld $nativecclinkopts -o\\ " >> Makefile
+echo "PACKLD=$partialld $(echo $nativecclinkopts|sed s/-Wl,//g) -o\\ " >> Makefile
 echo "IFLEXDIR=$iflexdir" >> Makefile
 echo "O=o" >> Makefile
 echo "A=a" >> Makefile