Hello,

 

Looks like a bug; did I miss something ?

 

My environment:

###################################################

[mbozzore@tyan04 openmpi-1.2.4]$ echo $CFLAGS

-I/home/mbozzore/pvfs-2.6.3/include

[mbozzore@tyan04 openmpi-1.2.4]$ echo $FFLAGS

 

[mbozzore@tyan04 openmpi-1.2.4]$ echo $LIBS

-lpvfs2 -lpthread

[mbozzore@tyan04 openmpi-1.2.4]$ echo $LDFLAGS

-L/export/pvfs-2.6.3/lib/

###################################################

 

Open MPI version : 1.2.4; same behaviour expected with 1.2.6

 

 

arguments given to configure:

 

./configure --prefix=/export/ompi-124-pvfs263
--with-io-romio-flags=--with-file-system=pvfs+nfs

 

 

config.log:

 

####################################################################

configure:36703: checking if Fortran compiler works

configure:36759: gfortran -o conftest  -L/export/pvfs-2.6.3/lib/
conftest.f -lpvfs2 -lpthread >&5

configure:36762: $? = 0

configure:36768: ./conftest

configure:36771: $? = 0

configure:36793: result: yes

configure:36819: checking whether gfortran and gfortran compilers are
compatible

configure:36844: gfortran   -c conftestf90.f

configure:36851: $? = 0

configure:36861: gfortran  -c conftestf77.f

configure:36868: $? = 0

configure:36878: gfortran  -o conftest conftestf90.o conftestf77.o
-lpvfs2 -lpthread

/usr/bin/ld: cannot find -lpvfs2

collect2: ld returned 1 exit status

configure:36885: $? = 1

configure:36912: here is the F77 program:

        subroutine Conf1_test()

        end

configure:36925: here is the F90 program:

        program main

        call Conf1_test()

        end

configure:36950: result: no

configure:36952: WARNING: *** Fortran 77 and Fortran 90 compilers are
not link compatible

configure:36954: WARNING: *** Disabling MPI Fortran 90/95 bindings

configure:36994: checking for extra arguments to build a shard library

configure:37017: result: none needed

configure:37416: checking if Fortran 90 compiler supports LOGICAL

configure:37418: result: skipped

configure:37780: checking if Fortran 90 compiler supports INTEGER

configure:37782: result: skipped

####################################################################

 

 

With an updated configure script:

 

####################################################################

[mbozzore@tyan04 openmpi-1.2.4]$ diff -U4 configure.orig configure.new

--- configure.orig      2008-08-21 09:49:01.000000000 -0400

+++ configure.new       2008-08-21 11:10:31.000000000 -0400

@@ -36874,10 +36874,10 @@

 

 # 1 is the command

 # 2 is actions to do if success

 # 3 is actions to do if fail

-echo "configure:36878: $OMPI_F90 $FCFLAGS -o conftest conftestf90.o
conftestf77.o $LIBS" >&5

-$OMPI_F90 $FCFLAGS -o conftest conftestf90.o conftestf77.o $LIBS 1>&5
2>&1

+#echo "NEW configure:36878: $OMPI_F90 $FCFLAGS $LDFLAGS -o conftest
conftestf90.o conftestf77.o $LIBS" >&5

+$OMPI_F90 $FCFLAGS $LDFLAGS -o conftest conftestf90.o conftestf77.o
$LIBS 1>&5 2>&1

 ompi_status=$?

 

 # 1 is the message

 # 2 is whether to put a prefix or not

####################################################################

 

 

config.log:

####################################################################

NEW configure:36878: gfortran  -L/export/pvfs-2.6.3/lib/ -o conftest
conftestf90.o conftestf77.o -lpvfs2 -lpthread

configure:36885: $? = 0

configure:36956: result: yes

####################################################################

 

 

 

>From the FAQ:
http://www.open-mpi.org/faq/?category=building#build-compiler-flags

 

LDFLAGS: Flags passed to the linker (not language-specific). This flag
is rarely required; Open MPI will usually pick up all LDFLAGS that it
needs by itself.

 

 

Mehdi

 

 

Mehdi Bozzo-Rey <mailto:mbozz...@platform.com> 

Open Source Solution Developer

Platform OCS5
<http://www.platform.com/Products/platform-open-cluster-stack5> 

Platform computing

Phone: +1 905 948 4649

 

 

Reply via email to