Hi,
I’m getting a link error trying to build OpenMPI 1.5.1 with PGI Server 11.1 on Oracle Enterprise Linux 5.4.
configure command:
cd /tmp/openmpi-1.5.1/build
env CC=pgcc FC=pgfortran F77=pgfortran CXX=pgcpp CFLAGS=-fast FFLAGS=-fast CXXFLAGS=-fast …/configure --prefix=/shared_apps/pgi/linux86-64/11.1/mpi/openmpi
<snip>
make[2]: Entering directory `/tmp/mpi/openmpi-1.5.1/build/opal'
CC class/opal_bitmap.lo
CC class/opal_free_list.lo
CC class/opal_hash_table.lo
CC class/opal_list.lo
CC class/opal_object.lo
CC class/opal_graph.lo
CC class/opal_atomic_lifo.lo
CC class/opal_pointer_array.lo
CC class/opal_value_array.lo
CC memoryhooks/memory.lo
CC runtime/opal_progress.lo
CC runtime/opal_finalize.lo
CC runtime/opal_init.lo
CC runtime/opal_params.lo
CC runtime/opal_cr.lo
CC threads/condition.lo
CC threads/mutex.lo
CC threads/thread.lo
CC threads/tsd.lo
CC dss/dss_internal_functions.lo
CC dss/dss_compare.lo
CC dss/dss_copy.lo
CC dss/dss_dump.lo
CC dss/dss_get.lo
CC dss/dss_load_unload.lo
CC dss/dss_lookup.lo
CC dss/dss_pack.lo
CC dss/dss_peek.lo
CC dss/dss_print.lo
CC dss/dss_register.lo
CC dss/dss_release.lo
CC dss/dss_set.lo
CC dss/dss_set_buffer_type.lo
CC dss/dss_size.lo
CC dss/dss_unpack.lo
CC dss/dss_open_close.lo
CCLD libopen-pal.la
/usr/bin/ld: /shared_apps/pgi/linux86-64/11.1/lib/libpgbind.a(bindsa.o): relocation R_X86_64_PC32 against `syscall@@GLIBC_2.2.5' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: final link failed: Bad value
make[2]: *** [libopen-pal.la] Error 2
make[2]: Leaving directory `/tmp/mpi/openmpi-1.5.1/build/opal'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/tmp/mpi/openmpi-1.5.1/build/opal'
make: *** [all-recursive] Error 1
I’ve tried adding -fPIC to each of the compiler flags, e.g.
CFLAGS=“-fast -fPIC”
but it doesn’t seem to make any difference.
I’ve also tried PGI Server installed as both a network install with the main installation on an NFS mount /shared_apps and the local files in /usr/pgi/shared_objects and as a normal install with everything in /shared_apps but each time I get this link error on libpgbind.a
OpenMPI configures and builds OK with GCC (no compiler parameters on the configure line).
Do I have the correct compiler parameters for 11.1 ?
I’ve seen previous versions specify F77=pgf77 rather than pgfortran ?
Any ideas would be appreciated.