X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=configure.ac;h=a1afa25a52551bc4a8d9eb2fca771e96d9f86d1a;hb=ee7ad29e757ab4f99b8b776ce7e8ebee5081767a;hp=ddd71d3d13b2d4676442e2011a00905352900d15;hpb=756d59b7ebd92c58dd8d2f8757ccb6e633b73f90;p=xboard.git diff --git a/configure.ac b/configure.ac index ddd71d3..a1afa25 100644 --- a/configure.ac +++ b/configure.ac @@ -28,7 +28,7 @@ dnl| to regenerate configure. Then submit your changes to be folded into dnl| the standard version of xboard. dnl| define second argument as VERSION.PATCHLEVEL. e.g. 4.4.0j -AC_INIT([xboard],[master-20120410],[bug-xboard@gnu.org]) +AC_INIT([xboard],[master-20120430],[bug-xboard@gnu.org]) dnl| need this to be able to compile some files in a subdir (filebrowser) AM_INIT_AUTOMAKE([subdir-objects]) @@ -110,6 +110,15 @@ AC_CHECK_FUNC(setlocale, [], AC_CHECK_LIB(seq, getpseudotty) +dnl | add compiler warnings only if compiler understands them +AC_MSG_CHECKING(whether compiler understands -Wall -Wno-parentheses) +SAVE_CFLAGS="$CFLAGS" +CFLAGS="$CFLAGS -Wall -Wno-parentheses" +AC_TRY_COMPILE([],[], + AC_MSG_RESULT(yes), + AC_MSG_RESULT(no) + CFLAGS="$SAVE_CFLAGS") + dnl | check for X-libraries AC_PATH_XTRA @@ -120,7 +129,13 @@ if test -n "$no_x" ; then exit 1 fi +save_cflags="$CFLAGS" +save_cppflags="$CPPFLAGS" +CFLAGS="$CFLAGS $X_CFLAGS" +CPPFLAGS="$CPPFLAGS $X_CFLAGS" AC_CHECK_HEADER(X11/Intrinsic.h,xt="yes",xt="no") +CFLAGS="$save_cflags" +CPPFLAGS="$save_cppflags" if test "$xt" = "no" ; then echo Xt headers not found @@ -147,7 +162,13 @@ AS_IF([test x"$with_Xaw3d" != x"no"], [-lXaw])]) dnl | no Xaw3d, check for Xaw if test x"$with_Xaw3d" = x"no" ; then + save_cflags="$CFLAGS" + save_cppflags="$CPPFLAGS" + CFLAGS="$CFLAGS $X_CFLAGS" + CPPFLAGS="$CPPFLAGS $X_CFLAGS" AC_CHECK_HEADER(X11/Xaw/Dialog.h,xaw_headers="yes", xaw_headers="no") + CFLAGS="$save_cflags" + CPPFLAGS="$save_cppflags" if test x"$xaw_headers" = x"no" ; then AC_MSG_ERROR([Xaw headers not found. Please install the Xaw package and headers.]) fi @@ -344,10 +365,12 @@ AC_ARG_ENABLE( [xpm], if test x"$enable_xpm" != "xno"; then save_cflags="$CFLAGS" + save_cppflags="$CPPFLAGS" CFLAGS="$CFLAGS $X_CFLAGS" CPPFLAGS="$CPPFLAGS $X_CFLAGS" AC_CHECK_HEADERS(X11/xpm.h) CFLAGS="$save_cflags" + CPPFLAGS="$save_cppflags" if test "$ac_cv_header_X11_xpm_h" = "yes"; then save_ldflags="$LDFLAGS" LDFLAGS="$LDFLAGS $X_LIBS"