From d1e80dc431815df3ac6eeed654eeccaf8d6beea7 Mon Sep 17 00:00:00 2001 From: Lorry Tar Creator Date: Fri, 18 Jul 2008 14:57:36 +0000 Subject: libmpeg2-0.5.1 --- m4/cflags.m4 | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 m4/cflags.m4 (limited to 'm4/cflags.m4') diff --git a/m4/cflags.m4 b/m4/cflags.m4 new file mode 100644 index 0000000..87d5143 --- /dev/null +++ b/m4/cflags.m4 @@ -0,0 +1,14 @@ +dnl AC_TRY_CFLAGS (CFLAGS, [ACTION-IF-WORKS], [ACTION-IF-FAILS]) +dnl check if $CC supports a given set of cflags +AC_DEFUN([AC_TRY_CFLAGS], + [AC_MSG_CHECKING([if $CC supports $1 flags]) + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$1" + AC_TRY_COMPILE([],[],[ac_cv_try_cflags_ok=yes],[ac_cv_try_cflags_ok=no]) + CFLAGS="$SAVE_CFLAGS" + AC_MSG_RESULT([$ac_cv_try_cflags_ok]) + if test x"$ac_cv_try_cflags_ok" = x"yes"; then + ifelse([$2],[],[:],[$2]) + else + ifelse([$3],[],[:],[$3]) + fi]) -- cgit v1.2.1