[Beowulf] Compiling mpiJava on Amd64

Kozin, I (Igor) i.kozin at dl.ac.uk
Wed Jul 19 05:57:02 PDT 2006


-o stands for the object you are creating instead of the default.
You should not have removed -o because
otherwise you are trying to link in ../../lib/libmpijava.so
which is obviously not there. You have to add -fPIC to the compiler
(eg to CFLAGS) and make sure all the objects you are using
(eg in the mpi libraries) are coming from *.so or have been compiled 
with -fPIC.


> -----Original Message-----
> From: beowulf-bounces at beowulf.org 
> [mailto:beowulf-bounces at beowulf.org]On
> Behalf Of Byrne, Michael J
> Sent: 18 July 2006 20:56
> To: beowulf at beowulf.org
> Subject: [Beowulf] Compiling mpiJava on Amd64
> 
> 
> The error is coming up when I run Make.  After the .class 
> files are compiled and the .c files are compiled, it tries to 
> make the shared object "libmpijava.so."
> 
> The default for mpiJava was creating the shared object using 
> the -o flag.  I get an error that says:
> relocation R_X86_64_32 can not be used when making a shared 
> object; recompile with -fPIC
> 
> When I edit the makefile to change the flag from -o to -fPIC 
> and try Make again, no error is thrown, but the .so is not 
> found. Here is the command and error:
> 
> /usr/bin/mpicc -shared -fPIC ../../lib/libmpijava.so \ 
> -L/usr/lib64/MPICH/p4/gnu <list of .o's>
> gcc: ../../lib/libmpijava.so: No such file or directory
>  
>  
> It seems like it might be a problem in the mpicc script 
> passing to the gcc, but there isn't anything in the mpicc 
> script except building the args together.
> Has anyone else had this problem, or is experienced with 
> compiling .so's?
>  
> Michael
> 
> _______________________________________________
> Beowulf mailing list, Beowulf at beowulf.org
> To change your subscription (digest mode or unsubscribe) 
> visit http://www.beowulf.org/mailman/listinfo/beowulf
> 




More information about the Beowulf mailing list