GNU bug report logs - #17094
Libtool bug with PGI Fortran compiler on OS X

Previous Next

Package: libtool;

Reported by: "Jeff Squyres (jsquyres)" <jsquyres <at> cisco.com>

Date: Tue, 25 Mar 2014 14:45:02 UTC

Severity: normal

To reply to this bug, email your comments to 17094 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-libtool <at> gnu.org:
bug#17094; Package libtool. (Tue, 25 Mar 2014 14:45:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to "Jeff Squyres (jsquyres)" <jsquyres <at> cisco.com>:
New bug report received and forwarded. Copy sent to bug-libtool <at> gnu.org. (Tue, 25 Mar 2014 14:45:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: "Jeff Squyres (jsquyres)" <jsquyres <at> cisco.com>
To: "bug-libtool <at> gnu.org" <bug-libtool <at> gnu.org>
Cc: Matt Thompson <fortran <at> gmail.com>
Subject: Libtool bug with PGI Fortran compiler on OS X
Date: Tue, 25 Mar 2014 14:43:54 +0000
[Message part 1 (text/plain, inline)]
Matt Thompson (CC'ed), an Open MPI user, posted to the Open MPI list recently stating that he was having trouble installing Open MPI with the PGI compiler on OS X (thread starting here: http://www.open-mpi.org/community/lists/users/2014/03/23888.php).

After some back and forth, we think we may have found a bug in Libtool.

I created a trivial autoconf/automake/libtool package for testing:

    https://github.com/jsquyres/pgi-autotool-bug

The project makes a trivial Fortran library comprised of two .f90 source files.  Here's contents of src/Makefile.am:

-----
lib_LTLIBRARIES = libfortran_stuff.la
libfortran_stuff_la_SOURCES = fortran_foo.f90 fortran_bar.f90
-----

I made two tarballs for Matt and had him try them both.  One tarball was made with the GNU Autotools tuple that we use to make Open MPI 1.7.x tarballs (AC 2.69, AM 1.12.2, LT 2.4.2, m4 1.4.16).  The other tarball was with the most recent Automake (1.14.1), just in case this was an AM issue.  Both tarballs exhibit the same behavior on his OS X machine with the PGI Fortran compiler.

The output from a build seems to indicate a problem with Libtool.  Let me show the problem by contrasting output from "make V=1" on my Linux/gfortran based system vs. Matt's OS X / PGI Fortran compiler system.

Here's (annotated) output from Linux/gfortran "make V=1":

-----
Making all in src
make[1]: Entering directory `/home/jsquyres/git/pgi-autotool-bug/src'

# Compile the fortran_foo.f90 file
/bin/sh ../libtool  --tag=FC   --mode=compile gfortran  -g -O2 -c -o fortran_foo.lo fortran_foo.f90
libtool: compile:  gfortran -g -O2 -c fortran_foo.f90  -fPIC -o .libs/fortran_foo.o

# Compile the fortran_bar.f90 file
/bin/sh ../libtool  --tag=FC   --mode=compile gfortran  -g -O2 -c -o fortran_bar.lo fortran_bar.f90
libtool: compile:  gfortran -g -O2 -c fortran_bar.f90  -fPIC -o .libs/fortran_bar.o

# Link the two into the libfortran_stuff.so library
/bin/sh ../libtool  --tag=FC   --mode=link gfortran  -g -O2   -o libfortran_stuff.la -rpath /usr/local/lib fortran_foo.lo fortran_bar.lo  
libtool: link: gfortran -shared  -fPIC  .libs/fortran_foo.o .libs/fortran_bar.o    -O2   -Wl,-soname -Wl,libfortran_stuff.so.0 -o .libs/libfortran_stuff.so.0.0.0

# Make some handy sym links
libtool: link: (cd ".libs" && rm -f "libfortran_stuff.so.0" && ln -s "libfortran_stuff.so.0.0.0" "libfortran_stuff.so.0")
libtool: link: (cd ".libs" && rm -f "libfortran_stuff.so" && ln -s "libfortran_stuff.so.0.0.0" "libfortran_stuff.so")
libtool: link: ( cd ".libs" && rm -f "libfortran_stuff.la" && ln -s "../libfortran_stuff.la" "libfortran_stuff.la" )
-----

And here's the (annotated) output from his OS X / PGI Fortran compiler system:

-----
Making install in src

# Compile the fortran_foo.f90 file
/bin/sh ../libtool  --tag=FC   --mode=compile pgfortran  -m64 -c -o fortran_foo.lo fortran_foo.f90
libtool: compile:  pgfortran -m64 -c fortran_foo.f90  -o .libs/fortran_foo.o

# Compile the fortran_bar.f90 file
/bin/sh ../libtool  --tag=FC   --mode=compile pgfortran  -m64 -c -o fortran_bar.lo fortran_bar.f90
libtool: compile:  pgfortran -m64 -c fortran_bar.f90  -o .libs/fortran_bar.o

# Link the two into the libfortran_stuff.so library
/bin/sh ../libtool  --tag=FC   --mode=link pgfortran  -m64  -m64 -o libfortran_stuff.la -rpath /Users/fortran/AutomakeBug/autobug14/lib fortran_foo.lo fortran_bar.lo  
******* NOTICE THAT THERE'S NO COMMAND HERE TO MAKE THE LIBRARY!

# Make some handy sym links
libtool: link: (cd ".libs" && rm -f "libfortran_stuff.dylib" && ln -s "libfortran_stuff.0.dylib" "libfortran_stuff.dylib")
libtool: link: ( cd ".libs" && rm -f "libfortran_stuff.la" && ln -s "../libfortran_stuff.la" "libfortran_stuff.la" )
-----

It looks like Libtool is somehow not issuing the link command to pgfortran to actually create the library.  The sym links are created, but they're presumably dangling.

I've attached the following for reference:

- PGI outputs: config.log, configure stdout, make V=1 install stdout
- gfortran outputs: ditto

-- 
Jeff Squyres
jsquyres <at> cisco.com
For corporate legal information go to: http://www.cisco.com/web/about/doing_business/legal/cri/
[pgi-output.tar.bz2 (application/x-bzip2, attachment)]
[gfortran-output.tar.bz2 (application/x-bzip2, attachment)]

Information forwarded to bug-libtool <at> gnu.org:
bug#17094; Package libtool. (Fri, 11 Apr 2014 10:09:01 GMT) Full text and rfc822 format available.

Message #8 received at 17094 <at> debbugs.gnu.org (full text, mbox):

From: "Jeff Squyres (jsquyres)" <jsquyres <at> cisco.com>
To: "Jeff Squyres (jsquyres)" <jsquyres <at> cisco.com>
Cc: Matt Thompson <fortran <at> gmail.com>,
 "<17094 <at> debbugs.gnu.org>" <17094 <at> debbugs.gnu.org>
Subject: Re: bug#17094: Libtool bug with PGI Fortran compiler on OS X
Date: Fri, 11 Apr 2014 10:08:12 +0000
Has there been any progress on this issue?

Thanks.

On Mar 25, 2014, at 10:43 AM, Jeff Squyres (jsquyres) <jsquyres <at> cisco.com> wrote:

> Matt Thompson (CC'ed), an Open MPI user, posted to the Open MPI list recently stating that he was having trouble installing Open MPI with the PGI compiler on OS X (thread starting here: http://www.open-mpi.org/community/lists/users/2014/03/23888.php).
> 
> After some back and forth, we think we may have found a bug in Libtool.
> 
> I created a trivial autoconf/automake/libtool package for testing:
> 
>    https://github.com/jsquyres/pgi-autotool-bug
> 
> The project makes a trivial Fortran library comprised of two .f90 source files.  Here's contents of src/Makefile.am:
> 
> -----
> lib_LTLIBRARIES = libfortran_stuff.la
> libfortran_stuff_la_SOURCES = fortran_foo.f90 fortran_bar.f90
> -----
> 
> I made two tarballs for Matt and had him try them both.  One tarball was made with the GNU Autotools tuple that we use to make Open MPI 1.7.x tarballs (AC 2.69, AM 1.12.2, LT 2.4.2, m4 1.4.16).  The other tarball was with the most recent Automake (1.14.1), just in case this was an AM issue.  Both tarballs exhibit the same behavior on his OS X machine with the PGI Fortran compiler.
> 
> The output from a build seems to indicate a problem with Libtool.  Let me show the problem by contrasting output from "make V=1" on my Linux/gfortran based system vs. Matt's OS X / PGI Fortran compiler system.
> 
> Here's (annotated) output from Linux/gfortran "make V=1":
> 
> -----
> Making all in src
> make[1]: Entering directory `/home/jsquyres/git/pgi-autotool-bug/src'
> 
> # Compile the fortran_foo.f90 file
> /bin/sh ../libtool  --tag=FC   --mode=compile gfortran  -g -O2 -c -o fortran_foo.lo fortran_foo.f90
> libtool: compile:  gfortran -g -O2 -c fortran_foo.f90  -fPIC -o .libs/fortran_foo.o
> 
> # Compile the fortran_bar.f90 file
> /bin/sh ../libtool  --tag=FC   --mode=compile gfortran  -g -O2 -c -o fortran_bar.lo fortran_bar.f90
> libtool: compile:  gfortran -g -O2 -c fortran_bar.f90  -fPIC -o .libs/fortran_bar.o
> 
> # Link the two into the libfortran_stuff.so library
> /bin/sh ../libtool  --tag=FC   --mode=link gfortran  -g -O2   -o libfortran_stuff.la -rpath /usr/local/lib fortran_foo.lo fortran_bar.lo  
> libtool: link: gfortran -shared  -fPIC  .libs/fortran_foo.o .libs/fortran_bar.o    -O2   -Wl,-soname -Wl,libfortran_stuff.so.0 -o .libs/libfortran_stuff.so.0.0.0
> 
> # Make some handy sym links
> libtool: link: (cd ".libs" && rm -f "libfortran_stuff.so.0" && ln -s "libfortran_stuff.so.0.0.0" "libfortran_stuff.so.0")
> libtool: link: (cd ".libs" && rm -f "libfortran_stuff.so" && ln -s "libfortran_stuff.so.0.0.0" "libfortran_stuff.so")
> libtool: link: ( cd ".libs" && rm -f "libfortran_stuff.la" && ln -s "../libfortran_stuff.la" "libfortran_stuff.la" )
> -----
> 
> And here's the (annotated) output from his OS X / PGI Fortran compiler system:
> 
> -----
> Making install in src
> 
> # Compile the fortran_foo.f90 file
> /bin/sh ../libtool  --tag=FC   --mode=compile pgfortran  -m64 -c -o fortran_foo.lo fortran_foo.f90
> libtool: compile:  pgfortran -m64 -c fortran_foo.f90  -o .libs/fortran_foo.o
> 
> # Compile the fortran_bar.f90 file
> /bin/sh ../libtool  --tag=FC   --mode=compile pgfortran  -m64 -c -o fortran_bar.lo fortran_bar.f90
> libtool: compile:  pgfortran -m64 -c fortran_bar.f90  -o .libs/fortran_bar.o
> 
> # Link the two into the libfortran_stuff.so library
> /bin/sh ../libtool  --tag=FC   --mode=link pgfortran  -m64  -m64 -o libfortran_stuff.la -rpath /Users/fortran/AutomakeBug/autobug14/lib fortran_foo.lo fortran_bar.lo  
> ******* NOTICE THAT THERE'S NO COMMAND HERE TO MAKE THE LIBRARY!
> 
> # Make some handy sym links
> libtool: link: (cd ".libs" && rm -f "libfortran_stuff.dylib" && ln -s "libfortran_stuff.0.dylib" "libfortran_stuff.dylib")
> libtool: link: ( cd ".libs" && rm -f "libfortran_stuff.la" && ln -s "../libfortran_stuff.la" "libfortran_stuff.la" )
> -----
> 
> It looks like Libtool is somehow not issuing the link command to pgfortran to actually create the library.  The sym links are created, but they're presumably dangling.
> 
> I've attached the following for reference:
> 
> - PGI outputs: config.log, configure stdout, make V=1 install stdout
> - gfortran outputs: ditto
> 
> -- 
> Jeff Squyres
> jsquyres <at> cisco.com
> For corporate legal information go to: http://www.cisco.com/web/about/doing_business/legal/cri/
> <pgi-output.tar.bz2><gfortran-output.tar.bz2>_______________________________________________
> Bug-libtool mailing list
> Bug-libtool <at> gnu.org
> https://lists.gnu.org/mailman/listinfo/bug-libtool


-- 
Jeff Squyres
jsquyres <at> cisco.com
For corporate legal information go to: http://www.cisco.com/web/about/doing_business/legal/cri/





This bug report was last modified 11 years and 68 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.