[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: NetBSD 1.5 & AC_F77_WRAPPERS problem
From: |
Akim Demaille |
Subject: |
Re: NetBSD 1.5 & AC_F77_WRAPPERS problem |
Date: |
18 Jul 2001 13:13:29 +0200 |
User-agent: |
Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Academic Rigor) |
>>>>> "Nicolas" == Nicolas Joly <address@hidden> writes:
Nicolas> Hi,
Hi Nicolas!
Nicolas> I just checked CVS autoconf on my NetBSD 1.5 and the
Nicolas> `AC_F77_WRAPPERS' problem is back.
Nicolas> The needed `#ifdef F77_DUMMY_MAIN ... #endif' structure is
Nicolas> missing.
:( Well, there will be no 2.51 then...
How about this? I'm entirely responsible for this, I simply forgot
that AC_F77_DUMMY_MAIN needs this special section will running and we
include it only when it _has_ been run...
Index: aclang.m4
===================================================================
RCS file: /cvs/autoconf/aclang.m4,v
retrieving revision 1.146
diff -u -u -r1.146 aclang.m4
--- aclang.m4 2001/07/17 16:30:20 1.146
+++ aclang.m4 2001/07/18 11:12:04
@@ -358,14 +358,7 @@
# against Fortran code, hence a dummy main might be needed.
m4_define([AC_LANG_PROGRAM(C)],
[$1
-m4_provide_ifelse([AC_F77_DUMMY_MAIN],
-[#ifdef F77_DUMMY_MAIN
-# ifdef __cplusplus
- extern "C"
-# endif
- int F77_DUMMY_MAIN() { return 1; }
-#endif
-])dnl
+m4_ifdef([_AC_LANG_PROGRAM_C_F77_HOOKS], [_AC_LANG_PROGRAM_C_F77_HOOKS])dnl
int
main ()
{
@@ -1961,6 +1954,14 @@
# MAIN _MAIN __MAIN main_ main__ _main (we follow DDD and try these too)
AC_DEFUN([AC_F77_DUMMY_MAIN],
[AC_REQUIRE([AC_F77_LIBRARY_LDFLAGS])dnl
+m4_define([_AC_LANG_PROGRAM_C_F77_HOOKS],
+[#ifdef F77_DUMMY_MAIN
+# ifdef __cplusplus
+ extern "C"
+# endif
+ int F77_DUMMY_MAIN() { return 1; }
+#endif
+])
AC_CACHE_CHECK([for dummy main to link with Fortran 77 libraries],
ac_cv_f77_dummy_main,
[AC_LANG_PUSH(C)dnl
Index: m4sugar.m4
===================================================================
RCS file: /cvs/autoconf/m4sugar.m4,v
retrieving revision 2.44
diff -u -u -r2.44 m4sugar.m4
--- m4sugar.m4 2001/06/01 10:55:21 2.44
+++ m4sugar.m4 2001/07/18 11:12:06
@@ -371,7 +371,7 @@
[$3])])
-# ifndef(NAME, [IF-NOT-DEFINED], [IF-DEFINED])
+# m4_ifndef(NAME, [IF-NOT-DEFINED], [IF-DEFINED])
# -----------------------------------------------
m4_define([m4_ifndef],
[m4_ifdef([$1], [$3], [$2])])