Am 10.11.2009 um 23:26 schrieb Jeff Squyres:
I'm away from icc help resources, but try the -static-intel
compiler flag.
I also like the compiler specific libs to be linked in statically - I
just rename the *.so to *.so.disabled. So the linker is forced to use
the .a files of the Intel libs.
-- Reuti
On Nov 10, 2009, at 2:51 PM, Blosch, Edwin L wrote:
I’m trying to build OpenMPI with Intel compilers, both static and
dynamic libs, then move it to a system that does not have Intel
compilers. I don’t care about system libraries or OpenMPI
loadable modules being dynamic, that’s all fine. But I need the
compiler libs to be statically linked into any executable.
I don’t seem to be smart enough to figure out how to get the Intel
libs statically linked into the “orterun” command.
Can someone help suggest the right way to achieve this?
Here’s my configure command and the relevant output from the
“make” inside tools/orterun. Notice that I am passing –i-static
in LDFLAGS, and it does indeed appear to have made it into the
link line for orterun. It just didn’t have the desired effect. A
subsequent ‘ldd’ shows that there is still a dependency on the
libimf.so.
Thanks
./configure
--prefix=/release/cfd/openmpi-intel
--enable-mpirun-prefix-by-default
--enable-contrib-no-build=vt
--disable-per-user-config-files
--enable-mca-no-build=maffinity
--enable-static
--without-openib
--without-tm
--with-mpi-f90-size=small
CXX=/appserv/intel/cce/10.1.021/bin/icpc
CC=/appserv/intel/cce/10.1.021/bin/icc
'CFLAGS= -O2'
'CXXFLAGS= -O2'
F77=/appserv/intel/fce/10.1.021/bin/ifort
'FFLAGS=-D_GNU_SOURCE -fpe0 -no-ftz -traceback -O2'
FC=/appserv/intel/fce/10.1.021/bin/ifort
'FCFLAGS=-D_GNU_SOURCE -fpe0 -no-ftz -traceback -O2'
'LDFLAGS= -i-static'
make[2]: Entering directory `/home/bloscel/builds/openmpi/orte/
tools/orterun'
depbase=`echo main.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
/appserv/intel/cce/10.1.021/bin/icc -DHAVE_CONFIG_H -I. -I../../../
opal/include -I../../../orte/include -I../../../ompi/include -
I../../../opal/mca/paffinity/linux/plpa/src/libplpa -
I../../.. -DNDEBUG -finline-functions -fno-strict-aliasing -
restrict -pthread -fvisibility=hidden -g -MT main.o -MD -MP -MF
$depbase.Tpo -c -o main.o main.c &&\
mv -f $depbase.Tpo $depbase.Po
depbase=`echo orterun.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
/appserv/intel/cce/10.1.021/bin/icc -DHAVE_CONFIG_H -I. -I../../../
opal/include -I../../../orte/include -I../../../ompi/include -
I../../../opal/mca/paffinity/linux/plpa/src/libplpa -
I../../.. -DNDEBUG -finline-functions -fno-strict-aliasing -
restrict -pthread -fvisibility=hidden -g -MT orterun.o -MD -MP -MF
$depbase.Tpo -c -o orterun.o orterun.c &&\
mv -f $depbase.Tpo $depbase.Po
depbase=`echo debuggers.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
/appserv/intel/cce/10.1.021/bin/icc -DHAVE_CONFIG_H -I. -I../../../
opal/include -I../../../orte/include -I../../../ompi/include -
I../../../opal/mca/paffinity/linux/plpa/src/libplpa -
I../../.. -DNDEBUG -finline-functions -fno-strict-aliasing -
restrict -pthread -fvisibility=hidden -g -MT debuggers.o -MD -MP -
MF $depbase.Tpo -c -o debuggers.o debuggers.c &&\
mv -f $depbase.Tpo $depbase.Po
/bin/sh ../../../libtool --tag=CC --mode=link /appserv/intel/cce/
10.1.021/bin/icc -DNDEBUG -finline-functions -fno-strict-aliasing
-restrict -pthread -fvisibility=hidden -g -export-dynamic -i-
static -o orterun main.o orterun.o debuggers.o ../../../orte/
libopen-rte.la -lnsl -lutil
libtool: link: /appserv/intel/cce/10.1.021/bin/icc -DNDEBUG -
finline-functions -fno-strict-aliasing -restrict -pthread -
fvisibility=hidden -g -i-static -o .libs/orterun main.o orterun.o
debuggers.o -Wl,--export-dynamic ../../../orte/.libs/libopen-
rte.so /home/bloscel/builds/openmpi/opal/.libs/libopen-pal.so -ldl
-lnsl -lutil -pthread -Wl,-rpath -Wl,/release/cfd/openmpi-intel/lib
/appserv/intel/cce/10.1.021/lib/libimf.so: warning: warning:
feupdateenv is not implemented and will always fail
_______________________________________________
users mailing list
us...@open-mpi.org
http://www.open-mpi.org/mailman/listinfo.cgi/users
--
Jeff Squyres
jsquy...@cisco.com
_______________________________________________
users mailing list
us...@open-mpi.org
http://www.open-mpi.org/mailman/listinfo.cgi/users