From 6ecbf8e6b9b816a8f2a73ba700da4aaf026fcb9b Mon Sep 17 00:00:00 2001 From: Max Lv Date: Fri, 30 Dec 2016 14:39:33 +0800 Subject: [PATCH] Avoid ms_struct on Cygwin and MingW --- configure | 4 ++++ configure.ac | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/configure b/configure index 9d32dc76..a60c805f 100755 --- a/configure +++ b/configure @@ -13526,8 +13526,12 @@ fi case $host in *-mingw*) + CFLAGS="$CFLAGS -mno-ms-bitfields" LIBS="$LIBS -ladvapi32 -lgdi32 -lws2_32 -lcrypt32" ;; + *-cygwin*) + CFLAGS="$CFLAGS -mno-ms-bitfields" + ;; *) ;; esac diff --git a/configure.ac b/configure.ac index 69a80554..bd9952c8 100755 --- a/configure.ac +++ b/configure.ac @@ -84,8 +84,12 @@ AM_COND_IF([USE_SYSTEM_SHARED_LIB], dnl Add library for mingw case $host in *-mingw*) + CFLAGS="$CFLAGS -mno-ms-bitfields" LIBS="$LIBS -ladvapi32 -lgdi32 -lws2_32 -lcrypt32" ;; + *-cygwin*) + CFLAGS="$CFLAGS -mno-ms-bitfields" + ;; *) ;; esac