From 63e74439a603f969d8cf8d5a5621f558002599a8 Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Wed, 7 Jun 2006 12:06:00 -0700 Subject: Bug #7150: Check for gcc & Sun cc in configure.ac and use correct flags to turn on more warnings for each This is the first of two fixes needed to get xcb-util building on Solaris. Signed-off-by: Jamey Sharp --- configure.ac | 10 ++++++++++ keysyms/Makefile.am | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 8b3c4ba..1204b00 100644 --- a/configure.ac +++ b/configure.ac @@ -11,6 +11,16 @@ fi AC_PROG_CC AC_PROG_LIBTOOL +if test "x$GCC" = xyes ; then + CWARNFLAGS="-Wall" +else + AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) + if test "x$SUNCC" = "xyes"; then + CWARNFLAGS="-v" + fi +fi +AC_SUBST(CWARNFLAGS) + xcbincludedir='${includedir}/xcb' AC_SUBST(xcbincludedir) diff --git a/keysyms/Makefile.am b/keysyms/Makefile.am index 6765333..e5a38cd 100644 --- a/keysyms/Makefile.am +++ b/keysyms/Makefile.am @@ -5,7 +5,7 @@ lib_LTLIBRARIES = libXCBKeysyms.la xcbinclude_HEADERS = xcb_keysyms.h -AM_CFLAGS = -Wall +AM_CFLAGS = $(CWARNFLAGS) libXCBKeysyms_la_SOURCES = keysyms.c libXCBKeysyms_la_CFLAGS = $(XCB_CFLAGS) -- cgit v1.2.3