libtool-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: darwin/Fortran: -single_module


From: Peter O'Gorman
Subject: Re: darwin/Fortran: -single_module
Date: Thu, 08 Dec 2005 13:14:53 +0900
User-agent: Mozilla Thunderbird 1.0.2 (Macintosh/20050317)

Ralf Wildenhues wrote:

+         echo "int foo(void){return 1;}" > conftest.$ac_ext
+         $CC $CLFAGS $LDFLAGS -o libconftest.dylib \


There's a typo in CFLAGS.

At this point in the configure script, CC may be one of user-provided
  $CC, $F77, $FC, $GCJ,

$ac_ext will be adjusted to the current language, as will $ac_compile,
so I don't think this makes too much sense.
I think you wanted $LTCC $LTCFLAGS instead.
(Or $ac_compile in conjunction with $lt_simple_compile_test_code?  But
then, the cache variable should be tagged.)

Surely you get away with this because, after the C case is tested,
AC_CACHE_VAL causes the test not to be executed again.  So you may
simply m4_if([$1], [], [
   AC_CACHE_VAL(...)])
to make clear that it is your intent to only run in the C case, and just
remove that code from the other tags.  Do you agree?

I'm happy to leave it as is, simply changing to LTCC and LTCFLAGS in all cases. If the var happens to become unset somewhere then the test will run again. I'll put it on my "fixme sometime" list though.

Applied the following to fix the typo.

Peter
Index: ChangeLog
2005-12-08  Peter O'Gorman  <address@hidden>

        * libltdl/m4/libtool.m4 (_LT_LANG_CXX_CONFIG, _LT_LINKER_SHLIBS)
        [darwin: Use $LTCC $LTCFLAGS to check for -single_module.
        Reported  by Ralf Wildenhues <address@hidden>

from  Ralf Wildenhues <address@hidden>
Index: libltdl/m4/libtool.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/libltdl/m4/libtool.m4,v
retrieving revision 1.50
diff -u -3 -p -u -r1.50 libtool.m4
--- libltdl/m4/libtool.m4 7 Dec 2005 13:23:14 -0000 1.50
+++ libltdl/m4/libtool.m4 8 Dec 2005 03:49:54 -0000
@@ -4400,9 +4400,9 @@ _LT_EOF
          # by either setting the environment variable LT_MULTI_MODULE
          # non-empty at configure time, or by adding -multi-module to the
          # link flags.
-         echo "int foo(void){return 1;}" > conftest.$ac_ext
-         $CC $CLFAGS $LDFLAGS -o libconftest.dylib \
-             -dynamiclib ${wl}-single_module conftest.$ac_ext
+         echo "int foo(void){return 1;}" > conftest.c
+         $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
+             -dynamiclib ${wl}-single_module conftest.c
          if test -f libconftest.dylib; then
              lt_cv_apple_cc_single_mod=yes
              rm libconftest.dylib
@@ -5395,9 +5395,9 @@ if test "$_lt_caught_CXX_error" != yes; 
            # by either setting the environment variable LT_MULTI_MODULE
            # non-empty at configure time, or by adding -multi-module to the
            # link flags.
-           echo "int foo(void){return 1;}" > conftest.$ac_ext
-           $CC $CLFAGS $LDFLAGS -o libconftest.dylib \
-               -dynamiclib ${wl}-single_module conftest.$ac_ext
+           echo "int foo(void){return 1;}" > conftest.c
+           $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
+               -dynamiclib ${wl}-single_module conftest.c
            if test -f libconftest.dylib; then
                lt_cv_apple_cc_single_mod=yes
                rm libconftest.dylib

reply via email to

[Prev in Thread] Current Thread [Next in Thread]