Anoop, OpenMPI defaults to building only shared libraries; see this FAQ entry for building static libraries:
http://www.open-mpi.org/faq/?category=building#static-build Hope this helps. --andy > -----Original Message----- > From: users-boun...@open-mpi.org > [mailto:users-boun...@open-mpi.org] On Behalf Of Anoop Rajendra > Sent: Thursday, June 15, 2006 4:56 PM > To: us...@open-mpi.org > Subject: [OMPI users] Cannot link statically against OpenMPI programs > > Hi. > > I'm having trouble compiling applications to link statically > > The command line and error I receive is > > [root@Pebble-anoop examples]# mpicc -c cpi.c > [root@Pebble-anoop examples]# mpicc -static -o cpi cpi.o > /usr/bin/ld: cannot find -lmpi > collect2: ld returned 1 exit status > > Not sure how I can compile an application statically. Can > someone help? > > Thanks, > Anoop > _______________________________________________ > users mailing list > us...@open-mpi.org > http://www.open-mpi.org/mailman/listinfo.cgi/users >