[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
patch: AC_FC_SRCEXT and AC_FC_FREEFORM should AC_LANG_PUSH, not AC_LANG_
From: |
Steven G. Johnson |
Subject: |
patch: AC_FC_SRCEXT and AC_FC_FREEFORM should AC_LANG_PUSH, not AC_LANG_ASSERT |
Date: |
Mon, 23 Jan 2006 15:37:35 -0500 |
User-agent: |
Mozilla Thunderbird 1.0 (Macintosh/20041206) |
I can't see why these macros used AC_LANG_ASSERT instead of PUSH/POP
(and I wrote them!), but it makes them a PITA in mixed-language projects.
2006-01-23 Steven G. Johnson <address@hidden>
* lib/autoconf/fortran.m4 (AC_FC_SRCEXT, AC_FC_FREEFORM): Use
AC_LANG_PUSH/POP instead of AC_LANG_ASSERT, to allow use
in mixed-language projects.
Index: lib/autoconf/fortran.m4
===================================================================
RCS file: /sources/autoconf/autoconf/lib/autoconf/fortran.m4,v
retrieving revision 1.201
diff -u -r1.201 fortran.m4
--- lib/autoconf/fortran.m4 12 Jan 2006 19:43:29 -0000 1.201
+++ lib/autoconf/fortran.m4 23 Jan 2006 20:33:43 -0000
@@ -1144,7 +1144,7 @@
# some versions), the $FCFLAGS_<EXT> variable *must* go immediately before
# the source file on the command line, unlike other $FCFLAGS. Ugh.
AC_DEFUN([AC_FC_SRCEXT],
-[AC_LANG_ASSERT(Fortran)dnl
+[AC_LANG_PUSH(Fortran)dnl
AC_CACHE_CHECK([for Fortran flag to compile .$1 files],
ac_cv_fc_srcext_$1,
[ac_ext=$1
@@ -1172,6 +1172,7 @@
AC_SUBST(FCFLAGS_[]$1)
$2
fi
+AC_LANG_POP(Fortran)dnl
])# AC_FC_SRCEXT
@@ -1195,7 +1196,7 @@
# We try to test the "more popular" flags first, by some prejudiced
# notion of popularity.
AC_DEFUN_ONCE([AC_FC_FREEFORM],
-[AC_LANG_ASSERT([Fortran])dnl
+[AC_LANG_PUSH(Fortran)dnl
AC_CACHE_CHECK([for Fortran flag needed to allow free-form source],
ac_cv_fc_freeform,
[ac_cv_fc_freeform=unknown
@@ -1224,4 +1225,5 @@
fi
$1
fi
+AC_LANG_POP(Fortran)dnl
])# AC_FC_FREEFORM
- patch: AC_FC_SRCEXT and AC_FC_FREEFORM should AC_LANG_PUSH, not AC_LANG_ASSERT,
Steven G. Johnson <=