[CIG-SHORT] Help with installing Pylith

Brad Aagaard baagaard at usgs.gov
Sun Oct 3 17:29:23 PDT 2010


Birendra-

Use mpicc as the C compiler to build nemesis (set CC=mpicc as a command 
line argument to configure). Using mpicc from OpenMPI will automatically 
add the command line options appropriate for compiling and linking with 
the MPI libraries.

Brad



On 10/3/10 4:57 PM, Birendra jha wrote:
> Dear developers,
> I am following the instructions on "Linux_ubuntu-AMD64_Aagaard.txt" to
> install pylith on Ubuntu 10.04 (through VMWare on my Windows XP 32bit).
> I am stuck at Step 8 during nemesis make:
> bjha at ubuntu:~/scratch/build/gcc-4.4.1_64/nemesis-dev$
> <mailto:bjha at ubuntu:~/scratch/build/gcc-4.4.1_64/nemesis-dev$> make
> make all-am
> make[1]: Entering directory
> `/home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev'
> gcc -DHAVE_CONFIG_H -I. -I/home/bjha/src/nemesis-dev
> -I/home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg
> -I/usr/include/python2.6 -I/usr/include/python2.6
> -I/home/bjha/tools/gcc-4.4.1_64/include -g -O2 -MT nemesis.o -MD -MP -MF
> .deps/nemesis.Tpo -c -o nemesis.o /home/bjha/src/nemesis-dev/nemesis.c
> mv -f .deps/nemesis.Tpo .deps/nemesis.Po
> gcc -g -O2 -L/usr/lib -L/usr/lib/python2.6/config -o nemesis nemesis.o
> -lpthread -ldl -lutil -lm -lpython2.6
> nemesis.o: In function `__pyx_f_4_mpi_9MPI_Group___init__':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:175:
> undefined reference to `ompi_mpi_group_null'
> nemesis.o: In function `__pyx_f_4_mpi_8MPI_Comm___init__':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:102:
> undefined reference to `ompi_mpi_comm_null'
> nemesis.o: In function `__pyx_f_4_mpi_getGroupObj':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:384:
> undefined reference to `ompi_mpi_group_null'
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:394:
> undefined reference to `ompi_mpi_group_empty'
> nemesis.o: In function `init_mpi':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:1535:
> undefined reference to `ompi_mpi_comm_world'
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:1540:
> undefined reference to `ompi_mpi_comm_null'
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:1545:
> undefined reference to `ompi_mpi_comm_self'
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:1550:
> undefined reference to `ompi_mpi_group_null'
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:1555:
> undefined reference to `ompi_mpi_group_empty'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Error_string':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:793:
> undefined reference to `MPI_Error_string'
> nemesis.o: In function `__pyx_f_4_mpi_8MPI_Comm___dealloc__':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:132:
> undefined reference to `MPI_Comm_free'
> nemesis.o: In function `__pyx_f_4_mpi_9MPI_Group___dealloc__':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:205:
> undefined reference to `MPI_Group_free'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Barrier':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:493:
> undefined reference to `MPI_Barrier'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Comm_create':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:551:
> undefined reference to `MPI_Comm_create'
> nemesis.o: In function `__pyx_f_4_mpi_getCommObj':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:318:
> undefined reference to `ompi_mpi_comm_world'
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:328:
> undefined reference to `ompi_mpi_comm_null'
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:338:
> undefined reference to `ompi_mpi_comm_self'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Comm_group':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:610:
> undefined reference to `MPI_Comm_group'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Comm_rank':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:673:
> undefined reference to `MPI_Comm_rank'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Comm_size':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:730:
> undefined reference to `MPI_Comm_size'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Group_excl':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:914:
> undefined reference to `MPI_Group_excl'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Group_incl':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:1014:
> undefined reference to `MPI_Group_incl'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Group_rank':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:1076:
> undefined reference to `MPI_Group_rank'
> nemesis.o: In function `__pyx_f_4_mpi_MPI_Group_size':
> /home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev/python/pythia-0.8.1.11-py2.6.egg/mpi/_mpi.c:1133:
> undefined reference to `MPI_Group_size'
> collect2: ld returned 1 exit status
> make[1]: *** [nemesis] Error 1
> make[1]: Leaving directory
> `/home/bjha/scratch/build/gcc-4.4.1_64/nemesis-dev'
> make: *** [all] Error 2
> bjha at ubuntu:~/scratch/build/gcc-4.4.1_64/nemesis-dev$
> <mailto:bjha at ubuntu:~/scratch/build/gcc-4.4.1_64/nemesis-dev$>
> Nemesis depends on MPI, but I noticed that in this set of instructions
> we don't install mpich2, but install OpenMPI (in contrast to
> "Linux_Fedora8-AMD64_Aagaard.txt" and "MacBookPro_Aagaard.txt"). Does
> that have to do something with my getting stuck during nemesis make? It
> is looking for ompi stuff, does that mean I am not linking it properly?
> Should I specify
> CPPFLAGS="-I${CIG_INCDIR} -I${MPI_INCDIR}" LDFLAGS="-L${CIG_LIBDIR}
> -L${MPI_LIBDIR}" LIBS="-lpmpich -lmpich"
> or
> CPPFLAGS="-I${CIG_INCDIR} -I${MPI_INCDIR}" LDFLAGS="-L${CIG_LIBDIR}
> -L${MPI_LIBDIR}" LIBS="-lpthread -lrt"
> during nemesis configure on Ubuntu (as it is for Macbook or Fedora,
> respectively)?
> During nemesis configure, I changed
> $HOME/src/nemesis-dev/configure --prefix=${TOOLS_DIR}
> to
> $HOME/src/nemesis-dev/configure --prefix=${TOOLS_DIR}
> CPPFLAGS="-I${TOOLS_DIR}/include"
> to be able to locate mpi.h because otherwise I getting "mpi.h not found"
> error during configure.
> Step 3.
> I got some errors during make install:
> bjha at ubuntu:~/scratch/build/gcc-4.4.1_64/spatialdata$make
> <mailto:bjha at ubuntu:~/scratch/build/gcc-4.4.1_64/spatialdata$make> install
> ...(lots of stuff scrolled by)...
> Processing dependencies for spatialdata==0.6.0
> Traceback (most recent call last):
> File "setup.py", line 36, in <module>
> url = 'http://www.geodynamics.org/',
> File "/usr/lib/python2.6/distutils/core.py", line 152, in setup
> dist.run_commands()
> File "/usr/lib/python2.6/distutils/dist.py", line 975, in run_commands
> self.run_command(cmd)
> File "/usr/lib/python2.6/distutils/dist.py", line 995, in run_command
> cmd_obj.run()
> File
> "/home/bjha/src/spatialdata/merlin-1.7.egg/merlin/command/install_deps.py",
> line 25, in run
> File
> "/home/bjha/src/spatialdata/merlin-1.7.egg/merlin/command/install_deps.py",
> line 74, in install_dependencies
> File
> "/home/bjha/src/spatialdata/merlin-1.7.egg/merlin/command/easy_install.py",
> line 526, in process_distribution
> File "/home/bjha/src/spatialdata/merlin-1.7.egg/merlin/__init__.py",
> line 650, in resolve
>
> File "/home/bjha/src/spatialdata/merlin-1.7.egg/merlin/__init__.py",
> line 2219, in requires
>
> merlin.UnknownExtra: pythia 0.8.1.10 has no such extra feature 'mpi'
> make[3]: *** [install-data-hook] Error 1
> make[3]: Leaving directory
> `/home/bjha/scratch/build/gcc-4.4.1_64/spatialdata'
> make[2]: *** [install-data-am] Error 2
> make[2]: Leaving directory
> `/home/bjha/scratch/build/gcc-4.4.1_64/spatialdata'
> make[1]: *** [install-am] Error 2
> make[1]: Leaving directory
> `/home/bjha/scratch/build/gcc-4.4.1_64/spatialdata'
> make: *** [install-recursive] Error 1
> But I went ahead with mpicc -show which gives:
> gcc -I/home/bjha/tools/gcc-4.4.1_64/include -pthread
> -L/home/bjha/tools/gcc-4.4.1_64/lib -lmpi -lopen-rte -lopen-pal -ldl
> -Wl,--export-dynamic -lnsl -lutil -lm -ldl
> Does that look ok to you?
> Step 6.
> I replaced spatialdata-dev with spatialdata, because I didn't find
> spatiaaldata-dev in the repository.
> I really need your help!
> Thank you & best regards
> Birendra
>
>
>
>
> _______________________________________________
> CIG-SHORT mailing list
> CIG-SHORT at geodynamics.org
> http://geodynamics.org/cgi-bin/mailman/listinfo/cig-short



More information about the CIG-SHORT mailing list