diff options
author | Jay Berkenbilt <ejb@ql.org> | 2013-11-30 04:08:01 +0100 |
---|---|---|
committer | Jay Berkenbilt <ejb@ql.org> | 2013-11-30 21:58:32 +0100 |
commit | 88c29873e56e69c83aa0d0798188cd792368059b (patch) | |
tree | ea8b1dfccea05098cd2eadd96d111e3a112b343a /configure.ac | |
parent | b75b19589db35cbeeb43c147a24bfcda91fe008f (diff) | |
download | qpdf-88c29873e56e69c83aa0d0798188cd792368059b.tar.zst |
Add /FS flag (msvc) for parallel builds
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac index af54b6ce..683b239f 100644 --- a/configure.ac +++ b/configure.ac @@ -200,7 +200,7 @@ if test "$BUILDRULES" = "msvc"; then dnl deprecated. Removing these warnings helps people who want to dnl write applications based on qpdf that can be Windows 8 dnl certified. - try_flags="/w14996" + try_flags="-w14996" else try_flags="-Wall" fi @@ -234,7 +234,23 @@ if test "$BUILDRULES" != "msvc"; then fi if test "$BUILDRULES" = "msvc"; then - try_flags="/WX" + try_flags=-FS + AC_MSG_CHECKING(for whether $CC supports $try_flags) + oCFLAGS=$CFLAGS + CFLAGS="$CFLAGS $try_flags" + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[int a = 1; int b = a; a = b;]])], + [qpdf_USE_FS=1],[qpdf_USE_FS=0]) + if test "$qpdf_USE_FS" = "1"; then + AC_MSG_RESULT(yes) + CXXFLAGS="$CXXFLAGS $try_flags" + else + AC_MSG_RESULT(no) + CFLAGS=$oCFLAGS + fi +fi + +if test "$BUILDRULES" = "msvc"; then + try_flags="-WX" else try_flags="-Werror" fi |