Ah! Brice's email crossed mine in the ether...
On Aug 3, 2011, at 10:29 AM, Brice Goglin wrote:
> I finally reproduced here. Based on the ornl platform script, you're
> configuring with LDFLAGS=-static and then building with make
> LDFLAGS=-all-static. Surprisingly, this works fine when building vanilla
> hwloc, but it breaks inside OMPI. The reason is that OMPI doesn't pass
> LDFLAGS=-static to hwloc's checks. Inside the vanilla hwloc, the libnuma
> related checks properly use the static libnuma:
> configure:9786: checking for set_mempolicy in -lnuma
> configure:9811: gcc -o conftest -static conftest.c -lnuma -lpthread >&5
> /usr/bin/ld: cannot find -lnuma
> collect2: ld returned 1 exit status
> Inside OMPI, there's no -static so it uses libnuma.so:
> configure:65582: checking for set_mempolicy in -lnuma
> configure:65607: gcc -o conftest -O3 -DNDEBUG -finline-functions -fno-strict-aliasing -pthread conftest.c -lnuma -lnsl -lutil -lm >&5
> configure:65607: $? = 0
> configure:65616: result: yes
Err.. I don't quite understand. How exactly are you configuring? If I do this:
./configure --prefix=/home/jsquyres/bogus --disable-mpi-f77 --disable-vt --disable-io-romio --disable-mpi-cxx --disable-shared --enable-static --enable-mpirun-prefix-by-default LDFLAGS=-static
I fail when linking opal_wrapper because of the ptmalloc shared memory hooks that we're looking for:
../../../opal/.libs/libopen-pal.a(memory_linux_munmap.o): In function `opal_memory_linux_free_ptmalloc2_munmap':
/users/jsquyres/svn/ompi5/opal/mca/memory/linux/memory_linux_munmap.c:74: undefined reference to `__munmap'
What is the goal here -- to make libmpi.a (and friends) that have no external dependencies?
For corporate legal information go to: