aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorLasse Collin <lasse.collin@tukaani.org>2009-07-01 12:21:24 +0300
committerLasse Collin <lasse.collin@tukaani.org>2009-07-01 12:21:24 +0300
commit5cc99db5bae8633f85559e5cdaef4cd905a4ee9c (patch)
tree1271fb3b026555e11206b0e7aceb11936624d069 /configure.ac
parentUse static liblzma by default also for tests. (diff)
downloadxz-5cc99db5bae8633f85559e5cdaef4cd905a4ee9c.tar.xz
Avoid visibility related compiler warnings on Windows.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac20
1 files changed, 9 insertions, 11 deletions
diff --git a/configure.ac b/configure.ac
index b1961eca..2f3af3d0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -554,21 +554,19 @@ lc_CPUCORES
# If using GCC, set some additional AM_CFLAGS:
###############################################################################
-if test "x$GCC" = xyes ; then
+if test "$GCC" = yes ; then
echo
echo "GCC extensions:"
+fi
- # Avoid checking for visibility support on Windows, because the test
- # may succeed even though visibility isn't supported. Windows has
- # a different way to export only the required symbols from the
- # libraries.
- if test "$is_w32" = no; then
- gl_VISIBILITY
- if test -n "$CFLAG_VISIBILITY" ; then
- AM_CFLAGS="$AM_CFLAGS $CFLAG_VISIBILITY"
- fi
- fi
+# Always do the visibility check but don't set AM_CFLAGS on Windows.
+# This way things get set properly even on Windows.
+gl_VISIBILITY
+if test -n "$CFLAG_VISIBILITY" && test "$is_w32" = no; then
+ AM_CFLAGS="$AM_CFLAGS $CFLAG_VISIBILITY"
+fi
+if test "$GCC" = yes ; then
# Enable as much warnings as possible. These commented warnings won't
# work for this package though:
# * -Wunreachable-code breaks several assert(0) cases, which are