[Libreoffice-commits] core.git: Branch 'distro/suse/suse-4.0' - config_host.mk.in configure.ac
LuboÅ¡ LuÅák
l.lunak at suse.cz
Fri Jun 28 07:04:28 PDT 2013
config_host.mk.in | 1 +
configure.ac | 20 ++++++++++++++++++++
2 files changed, 21 insertions(+)
New commits:
commit 6c5a33501453e7e76cb5c1ad836a7ad4f0a69bf5
Author: LuboÅ¡ LuÅák <l.lunak at suse.cz>
Date: Fri Jun 28 16:03:05 2013 +0200
detect -isystem
The base part of 151abb8b2b9d3a22229b98cec12e29484d12109b (and follow-up)
fixes, for other commits using ISYSTEM.
Change-Id: I9ab1ef95ec02ad30f943084161f76da1b2985b88
diff --git a/config_host.mk.in b/config_host.mk.in
index 05e4dfc..4f1842d 100644
--- a/config_host.mk.in
+++ b/config_host.mk.in
@@ -265,6 +265,7 @@ export INPATH_FOR_BUILD=@INPATH_FOR_BUILD@
export INSTALLDIR=@INSTALLDIR@
export INSTALLDIRNAME=@INSTALLDIRNAME@
export INTRO_BITMAP=@INTRO_BITMAP@
+export ISYSTEM=@ISYSTEM@
export JAVAIFLAGS=@JAVAIFLAGS@
export JAVAINTERPRETER=@JAVAINTERPRETER@
export JAVACISGCJ=@JAVACISGCJ@
diff --git a/configure.ac b/configure.ac
index e4c6827..e05fc81 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2883,6 +2883,26 @@ AC_SUBST(MAC_OS_X_VERSION_MAX_ALLOWED)
AC_SUBST(XCRUN)
AC_SUBST(MACOSX_CODESIGNING_IDENTITY)
+# Use -isystem (gcc) if possible, to avoid warnigs in 3rd party headers.
+ISYSTEM=
+if test "$GCC" = "yes"; then
+ AC_MSG_CHECKING( for -isystem )
+ save_CFLAGS=$CFLAGS
+ CFLAGS="$CFLAGS -Werror"
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ return 0; ]])],[ ISYSTEM=-isystem ],[])
+ CFLAGS=$save_CFLAGS
+ if test -n "$ISYSTEM"; then
+ AC_MSG_RESULT(yes)
+ else
+ AC_MSG_RESULT(no)
+ fi
+fi
+if test -z "$ISYSTEM"; then
+ # fall back to using -I
+ ISYSTEM=-I
+fi
+AC_SUBST(ISYSTEM)
+
dnl ===================================================================
dnl Windows specific tests and stuff
dnl ===================================================================
More information about the Libreoffice-commits
mailing list