]> Dogcows Code - chaz/openbox/blobdiff - configure.in
sync with bb-cvs
[chaz/openbox] / configure.in
index 4aef1c11298cd14d574b86089d49dc51397db71f..2093d4e0bb9b5a0e7d5c1f7b993ae806db9a2f45 100644 (file)
@@ -45,6 +45,29 @@ CXXFLAGS="$CXXFLAGS $X_CFLAGS"
 LIBS="$LIBS $X_LIBS"
 LDFLAGS="$LDFLAGS $LIBS $X_PRE_LIBS"
 
+AC_MSG_CHECKING(for GCC)
+if test x$GCC = "xyes"; then
+  AC_MSG_RESULT([yes])
+  CXXFLAGS="${CXXFLAGS} -Wall -W"
+else
+  AC_MSG_RESULT([no, trying other compilers])
+  AC_MSG_CHECKING(for MIPSpro)
+  mips_pro_ver=`$CC -version 2>&1 | grep -i mipspro | cut -f4 -d ' '`
+  if test "x$mips_pro_ver" = "x"; then
+    AC_MSG_RESULT([no])
+  else
+    AC_MSG_RESULT([yes, version $mips_pro_ver.])
+    AC_MSG_CHECKING(for -LANG:std in CXXFLAGS)
+    lang_std_not_set=`echo $CXXFLAGS | grep "\-LANG:std"`
+    if test "x$lang_std_not_set" = "x"; then
+      AC_MSG_RESULT([not set, setting.])
+      CXXFLAGS="${CXXFLAGS} -LANG:std"
+    else
+      AC_MSG_RESULT([already set.])
+    fi
+  fi
+fi
+
 dnl Check for required functions in -lX11
 AC_CHECK_LIB(X11, XOpenDisplay,
   LIBS="$LIBS -lX11",
@@ -166,7 +189,11 @@ AC_ARG_ENABLE(debug,
   [  --enable-debug          include verbose debugging code [default=no]],
   if test x$enableval = "xyes"; then
     AC_MSG_RESULT([yes])
-    DEBUG="-DDEBUG -Wall -W -fno-inline"
+    if test x$GCC = "xyes"; then
+       DEBUG="-DDEBUG -fno-inline -g"
+    else
+       DEBUG="-DDEBUG"
+    fi
   else
     AC_MSG_RESULT([no])
     DEBUG="-DNDEBUG"
This page took 0.024346 seconds and 4 git commands to generate.