On 12/2/05, Ralf Wildenhues <address@hidden> wrote:
Hi Christopher,
* Christopher Hulbert wrote on Fri, Dec 02, 2005 at 12:48:13PM CET:
> That's what I get for not following Rule #1 (Make sure you are using the
> latest version). 1.5.20 seemed to fix it.
Good to know.
> The other problem I have is I
> have to set FCFLAGS to -fpic so when autoconf gets the Fortran libraries to
> link with pgf90 puts the libso first. Is there another way to do that?
This is not quite enough information. Do you mean when creating a
program or creating a library? Best to show the command (as you did
previously) and its output, then I can probably say how to fix it.
> perhaps an AC_FC_LIBRARY_LDFLAGS_PIC type macro? I realize this is more of
> an autoconf question, but hoping you could help out.
If you do './libtool --mode=link..', then this likely remains a libtool
question.
Cheers,
Ralf
No I don't think it's a libtool problem. Basiclly I
call the AC_FC_LIBRARY_LDFLAGS macro to get the fortran libraries
to link with. Due to the behavior of pgf90, it
either puts the libso (for PIC code) first or the lib
directory first. Both directories contain the same libraries just
compiled differently. So, I have to set LDFLAGS=-fpic before
calling configure so that in the macro it passes the -fpic flags to
pgcc/pgf90 and I get the libso directory first. Autoconf doesn't
use libtool to get that information.
i.e.
LDLFAGS=-fpic ./configure
-L/usr/local/pgi/linux86-64/6.0/libso
-L/usr/local/pgi/linux86-64/6.0/lib -L/usr/lib64
-L/usr/lib/gcc/x86_64-redhat-linux/4.0.0 -lpgmp -lpgthread -lpgf90
-lpgf90_rpm1 -lpgf902 -lpgf90rtl -lpgftnrtl -lnspgc -lpgc -lm
./configure
-L/usr/local/pgi/linux86-64/6.0/lib
-L/usr/local/pgi/linux86-64/6.0/libso -L/usr/lib64
-L/usr/lib/gcc/x86_64-redhat-linux/4.0.0 -lpgmp -lpgthread -lpgf90
-lpgf90_rpm1 -lpgf902 -lpgf90rtl -lpgftnrtl -lnspgc -lpgc -lm