From: Steven G. Johnson Date: Wed, 12 Dec 2001 04:31:12 +0000 (+0000) Subject: Fix failed C/Fortran linking on HP/UX, by extracting the Fortran X-Git-Tag: AUTOCONF-2.52g~35 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=17df4ecdf89c3e723ca407091618dc37d5de8271;p=thirdparty%2Fautoconf.git Fix failed C/Fortran linking on HP/UX, by extracting the Fortran library search path from the LPATH line in the $F77 -v output. --- diff --git a/ChangeLog b/ChangeLog index 44a4657fd..665f9c9e7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,13 +1,18 @@ +2001-12-12 Steven G. Johnson + + * lib/autoconf/fortran.m4 (_AC_PROG_F77_V_OUTPUT): Fix failed + C/Fortran linking on HP/UX, by extracting the Fortran library + search path from the LPATH line in the $F77 -v output. + 2001-12-12 Kevin Ryde * doc/autoconf.texi (File Descriptors): Use a clearer layout for the forbidden file descriptors table. - + 2001-11-26 Akim Demaille * bin/autoscan.in (%c_keywords): Build it at top level. Map to 1 in order to simplify its uses. - 2001-11-26 Akim Demaille @@ -20,7 +25,6 @@ because of `lex$U.$(OBJEXT)'. (&scan_files): Use "@list" instead of join. * doc/Makefile.am (CLEANFILES): Add *.fns. - 2001-11-26 Akim Demaille @@ -35,7 +39,6 @@ * bin/autoscan.in (used): New. Use it. - 2001-11-26 Akim Demaille @@ -44,14 +47,12 @@ (&scan_sh_file): Remove a duplicate pattern. (&check_configure_ac): Use long options. * lib/autoscan/headers (alloca.h): Check with AC_FUNC_ALLOCA. - 2001-11-26 Akim Demaille * bin/autoscan.in (scan_c_file): Fix the handling of C comments. Before, having a line containing the opening of a multi line comment made the whole line be ignored. - 2001-11-26 Akim Demaille diff --git a/lib/autoconf/fortran.m4 b/lib/autoconf/fortran.m4 index 6e2f56d4f..5dd704e4f 100644 --- a/lib/autoconf/fortran.m4 +++ b/lib/autoconf/fortran.m4 @@ -384,6 +384,13 @@ if echo $ac_f77_v_output | grep xlfentry >/dev/null 2>&1; then ac_f77_v_output=`echo $ac_f77_v_output | sed 's/,/ /g'` fi +# On HP/UX there is a line like: "LPATH is: /foo:/bar:/baz" where +# /foo, /bar, and /baz are search directories for the Fortran linker. +# Here, we change these into -L/foo -L/bar -L/baz: +ac_f77_v_output="`echo $ac_f77_v_output | + grep 'LPATH is:' | + sed 's,.*LPATH is\(: *[[^ ]]*\).*,\1,;s,: */, -L/,g'` $ac_f77_v_output" + # If we are using Cray Fortran then delete quotes. # Use "\"" instead of '"' for font-lock-mode. # FIXME: a more general fix for quoted arguments with spaces?