[mpich-discuss] building 32 bit shmem on 64 bit linux system

Anthony Chan chan at mcs.anl.gov
Wed Jun 25 22:51:14 CDT 2008


Since you are using MPICH-1, you can try setting CC, F77 and F90

CC="gcc -m32"
F77="g77 -m32"
....

BTW, can you use MPICH2 instead ?  We have shifted all our development
effort to MPICH2 which is more robust than MPICH-1.  If you are using
MPICH2, setting CFLAGS and FFLAGS should work, and you can use nemesis
which shared memory for intranode communication.

A.Chan

----- "Daniel Fetchinson" <fetchinson at googlemail.com> wrote:

> Hi folks,
> 
> I'd like to build the 32-bit shmem mpi library because the code I'll
> use with mpi only works in 32-bit because of some 32-bit specific
> assembly code. The machine is a 64-bit machine with a 64-bit linux
> distribution (suse).
> 
> I tried configuring mpich-1.2.7p1 in a number of ways:
> 
> ./configure --with-device=ch_shmem
> ./configure --with-arch=LINUX --with-device=ch_shmem
> ./configure --with-arch=LINUX32 --with-device=ch_shmem
> ./configure --with-arch=i386 --with-device=ch_shmem
> 
> with and without setting the following environment variables (in
> bash):
> 
> export CFLAGS=-m32
> export FFLAGS=-m32
> 
> Configuring went all right but none of the above combinations worked
> with 'make' unfortunately :(
> The error in 'make' is the following:
> 
> /home/fetchinson/mpich-1.2.7p1/bin/mpicc  -o overtake overtake.o
> test.o
> /usr/lib64/gcc/x86_64-suse-linux/4.2.1/../../../../x86_64-suse-linux/bin/ld:
> skipping incompatible /home/fetchinson/mpich-1.2.7p1/lib/libmpich.a
> when searching for -lmpich
> /usr/lib64/gcc/x86_64-suse-linux/4.2.1/../../../../x86_64-suse-linux/bin/ld:
> cannot find -lmpich
> collect2: ld returned 1 exit status
> make[4]: *** [overtake] Error 1
> make[3]: [linktest1] Error 2 (ignored)
> Could not link a C program with MPI libraries
> make[3]: *** [linktest1] Error 1
> make[2]: *** [linktest] Error 2
> make[1]: *** [mpi-lib-test] Error 2
> make: *** [mpi] Error 2
> 
> Which makes me believe that I was not able to convince the
> compiler/linker/etc that I really want everything in 32-bit.
> 
> What would be the correct way of compiling the whole mpi library to
> 32-bit?
> 
> Cheers,
> Daniel




More information about the mpich-discuss mailing list