[Paraview] Superbuild: passing compiler flags
Angelini, Richard C (Rick) CIV USARMY ARL (US)
richard.c.angelini.civ at mail.mil
Thu Jun 13 08:46:45 EDT 2013
Thanks for the pointer. I changed my Superbuild cmake command to pass these arguments which I believe now include the correct tags
-DUSE_SYSTEM_mpi=ON \
-DMPI_CXX:FILEPATH=`which mpicxx` \
-DMPI_CXX_INCLUDE_PATH:STRING=${CPATH} \
-DMPI_CXX_LIBRARIES:STRING="-lmpi -lmpi++ -L${LIBRARY_PATH}" \
-DMPI_C:FILEPATH=`which mpicc` \
-DMPI_C_LIBRARIES:STRING="-lmpi -lmpi++ -L${LIBRARY_PATH}" \
-DMPI_C_INCLUDE_PATH:STRING=${CPATH} \
-DMPI_Fortran:FILEPATH=`which mpif90` \
-DMPI_Fortran_LIBRARIES:STRING="-lmpi -lmpi++ -L${LIBRARY_PATH}" \
-DMPI_Fortran_INCLUDE_PATH:STRING=${CPATH} \
In the Build directory, the CMakeCache.txt file has the correct values:
MPI_C:FILEPATH=/opt/sgi/mpt/mpt-2.07/bin/mpicc
MPI_CXX:FILEPATH=/opt/sgi/mpt/mpt-2.07/bin/mpicxx
MPI_CXX_COMPILER:FILEPATH=/opt/sgi/mpt/mpt-2.07/bin/mpicxx
MPI_CXX_COMPILE_FLAGS:STRING=
MPI_CXX_INCLUDE_PATH:STRING=/opt/sgi/mpt/mpt-2.07/include:/usr/include
MPI_CXX_LIBRARIES:STRING=-lmpi -lmpi++ -L/opt/sgi/mpt/mpt-2.07/lib
MPI_CXX_LINK_FLAGS:STRING=
MPI_C_COMPILER:FILEPATH=/opt/sgi/mpt/mpt-2.07/bin/mpicc
MPI_C_COMPILE_FLAGS:STRING=
MPI_C_INCLUDE_PATH:STRING=/opt/sgi/mpt/mpt-2.07/include:/usr/include
MPI_C_LIBRARIES:STRING=-lmpi -lmpi++ -L/opt/sgi/mpt/mpt-2.07/lib
MPI_C_LINK_FLAGS:STRING=
MPI_EXTRA_LIBRARY:STRING=MPI_EXTRA_LIBRARY-NOTFOUND
MPI_Fortran:FILEPATH=/opt/sgi/mpt/mpt-2.07/bin/mpif90
MPI_Fortran_INCLUDE_PATH:STRING=/opt/sgi/mpt/mpt-2.07/include:/usr/include
MPI_Fortran_LIBRARIES:STRING=-lmpi -lmpi++ -L/opt/sgi/mpt/mpt-2.07/lib
MPI_LIBRARY:FILEPATH=-lmpi -lmpi++ -L/opt/sgi/mpt/mpt-2.07/lib
However, the in the Build/paraview/src/paraview-build directory, the CMakeCache.txt file does not have the correct values:
MPI_CXX_COMPILER:FILEPATH=/opt/sgi/mpt/mpt-2.07/bin/mpicxx
MPI_CXX_COMPILE_FLAGS:STRING=
MPI_CXX_INCLUDE_PATH:STRING=
MPI_CXX_LIBRARIES:STRING=
MPI_CXX_LINK_FLAGS:STRING=
MPI_C_COMPILER:FILEPATH=/opt/sgi/mpt/mpt-2.07/bin/mpicc
MPI_C_COMPILE_FLAGS:STRING=
MPI_C_INCLUDE_PATH:STRING=
MPI_C_LIBRARIES:STRING=
MPI_C_LINK_FLAGS:STRING=
MPI_EXTRA_LIBRARY:STRING=MPI_EXTRA_LIBRARY-NOTFOUND
MPI_Fortran_COMPILER:FILEPATH=/opt/sgi/mpt/mpt-2.07/bin/mpif90
MPI_Fortran_COMPILE_FLAGS:STRING=
MPI_Fortran_INCLUDE_PATH:STRING=
MPI_Fortran_LIBRARIES:STRING=
MPI_Fortran_LINK_FLAGS:STRING=
________________________________
Rick Angelini
USArmy Research Laboratory
CISD/HPC Architectures Team
Building 120 Cube 315
Phone: 410-278-6266
________________________________
From: Utkarsh Ayachit [utkarsh.ayachit at kitware.com]
Sent: Wednesday, June 12, 2013 11:48 AM
To: Angelini, Richard C (Rick) CIV USARMY ARL (US)
Cc: paraview at paraview.org
Subject: Re: [Paraview] Superbuild: passing compiler flags
Rick,
Can you try using -D arguments with the correct syntax and see if that works?
cmake documentation states the following:
-D <var>:<type>=<value> = Create a cmake cache entry.
Ensure that you pass each of the -D arguments correctly with ":type" suffix. You can identify the type for the variables by running ccmake once and then looking at the generated CMakeCache.txt. Also, try quoting the arguments with spaces in them, namely MPI_*_LIBRARIES variables.
Utkarsh
On Wed, Jun 12, 2013 at 11:23 AM, Angelini, Richard C (Rick) CIV USARMY ARL (US) <richard.c.angelini.civ at mail.mil<mailto:richard.c.angelini.civ at mail.mil>> wrote:
I'm trying to pass some MPI-related flags through the Superbuild cmake. These flags need to get passed down to the actual Paraview source cmake, but they don't seem to getting included. If I run ccmake I can see that the flags have not been set - and if I manually add the flags at that time, the build proceeds.
(I'm talking about the MPI_xx) flags being passed via the cmake command line) I'm using cmake 2.8.11
cmake -DCMAKE_INSTALL_PREFIX:PATH=/home/angel/pv-test/${version}_mesa \
-Ddownload_location=`pwd`/../Downloads \
-DParaView_FROM_GIT=OFF \
-DParaView_URL=`pwd`/../Downloads/ParaView-4.0.0-RC3-source.tar.gz \
-DCMAKE_BUILD_TYPE=Release \
-DENABLE_boost=ON \
-DENABLE_cgns=ON \
-DENABLE_ffmpeg=ON \
-DENABLE_hdf5=ON \
-DENABLE_matplotlib=ON \
-DENABLE_mesa=ON \
-DENABLE_osmesa=OFF \
-DENABLE_mpi=ON \
-DENABLE_numpy=ON \
-DENABLE_paraview=ON \
-DENABLE_python=ON \
-DENABLE_qt=ON \
-DENABLE_silo=ON \
-DENABLE_szip=ON \
-Dqt_DISABLE_WEBKIT=OFF \
-DUSE_SYSTEM_mpi=ON \
-DMPI_CXX=mpicxx \
-DMPI_CXX_INCLUDE_PATH=${CPATH} \
-DMPI_CXX_LIBRARIES=-lmpi -lmpixx -L${LIBRARY_PATH} \
-DMPI_C=mpicc \
-DMPI_C_LIBRARIES=-lmpi -lmpixx -L${LIBRARY_PATH} \
-DMPI_C_INCLUDE_PATH=${CPATH} \
../Source
________________________________
Rick Angelini
USArmy Research Laboratory
CISD/HPC Architectures Team
Building 120 Cube 315
Phone: 410-278-6266<tel:410-278-6266>
_______________________________________________
Powered by www.kitware.com<http://www.kitware.com>
Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
Please keep messages on-topic and check the ParaView Wiki at: http://paraview.org/Wiki/ParaView
Follow this link to subscribe/unsubscribe:
http://www.paraview.org/mailman/listinfo/paraview
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20130613/5c86b037/attachment.htm>
More information about the ParaView
mailing list