]> git.proxmox.com Git - mirror_qemu.git/blobdiff - configure
Merge remote-tracking branch 'jasowang/tags/net-pull-request' into staging
[mirror_qemu.git] / configure
index 89df5c44ae4632f2ff1a090220a0119bb78f90ca..3770d7c2634ec0aa540cfd2442410f02bd06a045 100755 (executable)
--- a/configure
+++ b/configure
@@ -4723,8 +4723,14 @@ EOF
 if ! compile_object ""; then
   error_exit "Failed to compile object file for LD_REL_FLAGS test"
 fi
-if do_cc -nostdlib -Wl,-r -Wl,--no-relax -o $TMPMO $TMPO; then
-  LD_REL_FLAGS="-Wl,--no-relax"
+for i in '-Wl,-r -Wl,--no-relax' -Wl,-r -r; do
+  if do_cc -nostdlib $i -o $TMPMO $TMPO; then
+    LD_REL_FLAGS=$i
+    break
+  fi
+done
+if test "$modules" = "yes" && test "$LD_REL_FLAGS" = ""; then
+  feature_not_found "modules" "Cannot find how to build relocatable objects"
 fi
 
 ##########################################