Re: libtool-2.2.11a on AIX 5.3 current git master 2010-08-25 /status

2010-09-22 Thread Rainer Tammer
 Hello,

On 22.09.2010 09:38, Ralf Wildenhues wrote:
> * Rainer Tammer wrote on Wed, Sep 22, 2010 at 09:35:38AM CEST:
>> --- a/README
>> +++ b/README
>> @@ -319,6 +319,17 @@ notice and this notice are preserved.  This file is
>> offered as-is,
>>  without warranty of any kind.
>>
>>
>> +6. Platform specific notes
> We already have doc/notes.{texi,txt}.
>
Sorry,
I missed that :-((
> Cheers,
> Ralf
>
>
Bye
  Rainer



Re: libtool-2.2.11a on AIX 5.3 current git master 2010-08-25 /status

2010-09-22 Thread Ralf Wildenhues
* Rainer Tammer wrote on Wed, Sep 22, 2010 at 09:35:38AM CEST:
> --- a/README
> +++ b/README
> @@ -319,6 +319,17 @@ notice and this notice are preserved.  This file is
> offered as-is,
>  without warranty of any kind.
> 
> 
> +6. Platform specific notes

We already have doc/notes.{texi,txt}.

Cheers,
Ralf



Re: libtool-2.2.11a on AIX 5.3 current git master 2010-08-25 /status

2010-09-22 Thread Rainer Tammer
 Hello,

On 21.09.2010 19:59, Ralf Wildenhues wrote:
> Hello Rainer,
>
> * Rainer Tammer wrote on Tue, Sep 21, 2010 at 11:15:47AM CEST:
>> after this patch all tests from the old test suite are OK.
> Great!
>
>> The new test suite still shows some problems but its getting much better:
> Yeah.  They pass fully with LDFLAGS=-Wl,-brtl.  But the failures without
> runtimelinking are long-standing, not recent regressions.  That means we
> don't have to fix them before the release.
>
Usually I set "-Wl,-brtl" but in this case I was trying to set as little
as possible options.

Would it be OK to add this:

diff --git a/doc/PLATFORMS b/doc/PLATFORMS
index a724144..9d76364 100644
--- a/doc/PLATFORMS
+++ b/doc/PLATFORMS
@@ -114,6 +114,7 @@ mips-sni-sysv4  gcc  1.3.5ok
 mipsel-unknown-openbsd2.1   gcc  1.0  ok
 powerpc-apple-darwin6.4 gcc  1.5  ok
 (apple dev tools released 12/2002)
+powerpc-ibm-aix5.3.0.0  xlc  2.2.12   ok (with
LDFLAGS="-Wl,-brtl")
 powerpc-ibm-aix4.3.1.0  gcc  1.2f ok
   (egcs-1.1.1)
 powerpc-ibm-aix4.2.1.0  gcc  1.2f ok


and/or

diff --git a/README b/README
index f88901c..9e8d845 100644
--- a/README
+++ b/README
@@ -319,6 +319,17 @@ notice and this notice are preserved.  This file is
offered as-is,
 without warranty of any kind.


+6. Platform specific notes
+==
+
+6.1. AIX
+
+
+On AIX is is recommended to set:
+
+  export LDFLAGS="-Wl,-brtl"
+
+

> I've pushed the patch now.  Gary, I'm done, but Peter Rosin has pending
> stuff still.
>
OK
> Thanks again,
> Ralf
>
>
Bye
  Rainer Tammer




Re: libtool-2.2.11a on AIX 5.3 current git master 2010-08-25 /status

2010-09-21 Thread Ralf Wildenhues
Hello Rainer,

* Rainer Tammer wrote on Tue, Sep 21, 2010 at 11:15:47AM CEST:
> after this patch all tests from the old test suite are OK.

Great!

> The new test suite still shows some problems but its getting much better:

Yeah.  They pass fully with LDFLAGS=-Wl,-brtl.  But the failures without
runtimelinking are long-standing, not recent regressions.  That means we
don't have to fix them before the release.

I've pushed the patch now.  Gary, I'm done, but Peter Rosin has pending
stuff still.

Thanks again,
Ralf



Re: libtool-2.2.11a on AIX 5.3 current git master 2010-08-25 /status

2010-09-20 Thread Ralf Wildenhues
[ adding libtool-patches ]

Hello Rainer, all,

* Rainer Tammer wrote on Sun, Sep 19, 2010 at 12:55:59PM CEST:
> here is the result of the bisect. I had to slightly change your
> suggested bisect script:
> 
> if grep 'FAIL: f[c7]*demo-exec' checklog; then
> ->
> if grep '^FAIL: ' checklog; then
> 
> Result:

> 2fc264a8e2f7224627bb7c191a38a2dc9e7b5bcb is first bad commit
> commit 2fc264a8e2f7224627bb7c191a38a2dc9e7b5bcb
> Author: Ralf Wildenhues 
> Date:   Fri Aug 6 22:03:19 2010 +0200
> 
> Fix AC_NO_EXECUTABLES test failure on AIX.
> 
> * libltdl/m4/libtool.m4 (_LT_SYS_MODULE_PATH_AIX): Wrap link
> test in AC_CACHE_VAL, using cache variable $lt_cv_aix_libpath.
> * tests/no-executables.at (AC_NO_EXECUTABLES): Preset it, to
> avoid link test.
> Bug report by Rainer Tammer.

Thank You! for carrying this through until the end!  The timing is
really at the last minute, before this becomes a regression in a
released version.

As far as I can see it, the semantic change of the above patch is that,
before the patch, _LT_SYS_MODULE_PATH_AIX computed the libpath value for
each compiler separately, while now it is done only once, by the C
compiler, and that result reused for the others.  A quick test reveals
that the different compilers add different directories to their path.

Now, The Right Thing[tm] would probably be to somehow merge these paths
intelligently, so that when we link C, C++, and Fortran code together,
all directories are available.  However, at this point I'm *only*
interested in avoiding *regressions* and still keeping the
no-executables issue fixed.

Thus, the attached patch uses, in addition to a global cache variable
(that the user may specify), a set of per-language cache variables.
(The trailing space in the tagvar name is because the CC tagvar has no
_CC suffix, but should not overlap with the global name.)

I'm running it on the AIX systems I have access to now.

Rainer, can you please try it on your problematic system, too, ASAP?

OK to commit?

Thanks,
Ralf
>From c723aee17f21478894ba038711afde125daa1f70 Mon Sep 17 00:00:00 2001
From: Ralf Wildenhues 
Date: Mon, 20 Sep 2010 21:51:55 +0200
Subject: [PATCH] Revert to per-language libpath computation on AIX.

* libltdl/m4/libtool.m4 (_LT_SYS_MODULE_PATH_AIX): Accept
tagname argument.  Use global cache variable lt_cv_aix_libpath
to override per-language tag variables for the libpath value.
Fix the sed script to remove trailing space.
(_LT_LINKER_SHLIBS, _LT_LANG_CXX_CONFIG): Pass tag argument to
_LT_SYS_MODULE_PATH_AIX.
Tracked down and reported by Rainer Tammer.

Signed-off-by: Ralf Wildenhues 
---
 ChangeLog |   11 ++
 libltdl/m4/libtool.m4 |   54 
 2 files changed, 42 insertions(+), 23 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 8ed47f7..3a87052 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2010-09-20  Ralf Wildenhues  
+
+   Revert to per-language libpath computation on AIX.
+   * libltdl/m4/libtool.m4 (_LT_SYS_MODULE_PATH_AIX): Accept
+   tagname argument.  Use global cache variable lt_cv_aix_libpath
+   to override per-language tag variables for the libpath value.
+   Fix the sed script to remove trailing space.
+   (_LT_LINKER_SHLIBS, _LT_LANG_CXX_CONFIG): Pass tag argument to
+   _LT_SYS_MODULE_PATH_AIX.
+   Tracked down and reported by Rainer Tammer.
+
 2010-09-20  Peter Rosin  
Ralf Wildenhues  
 
diff --git a/libltdl/m4/libtool.m4 b/libltdl/m4/libtool.m4
index a8b07bf..2aee398 100644
--- a/libltdl/m4/libtool.m4
+++ b/libltdl/m4/libtool.m4
@@ -1073,33 +1073,41 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES],
   fi
 ])
 
-# _LT_SYS_MODULE_PATH_AIX
-# ---
+# _LT_SYS_MODULE_PATH_AIX([TAGNAME])
+# --
 # Links a minimal program and checks the executable
 # for the system default hardcoded library path. In most cases,
 # this is /usr/lib:/lib, but when the MPI compilers are used
 # the location of the communication and MPI libs are included too.
 # If we don't find anything, use the default library path according
 # to the aix ld manual.
+# Store the results from the different compilers for each TAGNAME.
+# Allow to override them for all tags through lt_cv_aix_libpath.
 m4_defun([_LT_SYS_MODULE_PATH_AIX],
 [m4_require([_LT_DECL_SED])dnl
-AC_CACHE_VAL([lt_cv_aix_libpath],
-[AC_LINK_IFELSE([AC_LANG_PROGRAM],[
-lt_aix_libpath_sed='
-/Import File Strings/,/^$/ {
-   /^0/ {
-   s/^0  *\(.*\)$/\1/
-   p
-   }
-}'
-lt_cv_aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e 
"$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$lt_cv_aix_libpath"; then
-  lt_cv_aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e 
"$lt_aix_libpath_sed"`
-fi],[])
-if test -z "$lt_cv_aix_libpath"; then lt_cv_aix_libpath="/usr/lib:/lib"; fi
-])
-aix_libpath=$lt_cv_aix_libp