Am Freitag, 17. März 2006 22:14 schrieb Kayvan A. Sylvan:
> On Fri, Mar 17, 2006 at 08:29:28PM +0100, Georg Baum wrote:
> > Kayvan, are you listening? Why did you introduce this option also for 
> > cygwin?
> 
> I think this was related to trying to compile for QT/Cygwin. If we can
> compile for QT on Windows without this, then I am all for removing it.

This is the case according to Enrico and Abdel. I am going to commit the 
attached patch to trunk unless somebody objects.


Georg

Log:
        Remove unneeded test for gcc2 on cygwin
        Don't set -mms-bitfields on cygwin
Index: config/cygwin.m4
===================================================================
--- config/cygwin.m4	(Revision 13415)
+++ config/cygwin.m4	(Arbeitskopie)
@@ -4,36 +4,19 @@
 AC_DEFUN([CHECK_WITH_CYGWIN],
 [
   case $host_os in
-  cygwin* | mingw* | pw32* )
+  mingw* | pw32* )
     if test "$GCC" = yes; then
       # Ensure MSVC-compatible struct packing convention.
       # Depends on GCC version. gcc2 uses -fnative-struct while
       # gcc3 uses -mms-bitfields.
-      #
-      msnative_struct=''
-      AC_MSG_CHECKING([how to get MSVC-compatible struct packing])
-      case `$CC --version | sed -e 's,\..*,.,' -e q` in
-      2.)
-        if $CC -v --help 2>/dev/null | grep fnative-struct > /dev/null; then
-        msnative_struct='-fnative-struct'
-        fi
-        ;;
-      *)
-        if $CC -v --help 2>/dev/null | grep ms-bitfields > /dev/null; then
-        msnative_struct='-mms-bitfields'
-        fi
-        ;;
-      esac
-
-      if test x"$msnative_struct" = x; then
-        AC_MSG_RESULT([no way])
-        AC_MSG_WARN([produced libraries might be incompatible with MSVC libs])
-      else
-        CXXFLAGS="$CXXFLAGS $msnative_struct"
-        AC_MSG_RESULT([${msnative_struct}])
-      fi
+      # We support only gcc3.
+      CXXFLAGS="$CXXFLAGS -mms-bitfields"
     fi
+    ;;
+  esac
 
+  case $host_os in
+  cygwin* | mingw* | pw32* )
     # Export all symbols to Win32 DLL using MinGW 2.0 ld.
     WIN32_LD_EXPORT_ALL_SYMBOLS=''
     AC_MSG_CHECKING([whether ld accepts --export-all-symbols])

Reply via email to