]> git.ipfire.org Git - thirdparty/dbus.git/commitdiff
Don't use -fPIC and -fPIE on Windows
authorTor Lillqvist <tml@iki.fi>
Wed, 21 Oct 2009 18:49:50 +0000 (21:49 +0300)
committerRalf Habacker <ralf.habacker@freenet.de>
Tue, 1 Dec 2009 08:20:31 +0000 (09:20 +0100)
The MinGW compiler recognizes them but emits a warning "-fPIC ignored
for target (all code is position independent)"

configure.in

index 2c74f61a1255849113dfb6e9f05afe7c60d7482c..30b725226b359b7ac4ad30698b90f3f7b1394326 100644 (file)
@@ -1093,7 +1093,7 @@ if test "x$GCC" = "xyes"; then
 
   case " $CFLAGS " in
   *[\ \        ]-fPIC[\ \      ]*) ;;
-  *) if cc_supports_flag -fPIC; then
+  *) if test x$dbus_win = xno && cc_supports_flag -fPIC; then
         PIC_CFLAGS="-fPIC"
         if ld_supports_flag -z,relro; then
            PIC_LDFLAGS="-Wl,-z,relro"
@@ -1104,7 +1104,7 @@ if test "x$GCC" = "xyes"; then
 
   case " $CFLAGS " in
   *[\ \        ]-fPIE[\ \      ]*) ;;
-  *) if cc_supports_flag -fPIE; then
+  *) if test x$dbus_win = xno && cc_supports_flag -fPIE; then
         PIE_CFLAGS="-fPIE"
         if ld_supports_flag -z,relro; then
            PIE_LDFLAGS="-pie -Wl,-z,relro"