[Paraview] CMake Producing Bad CXX Flags

Kent Eschenberg eschenbe at psc.edu
Fri Mar 23 15:57:30 EST 2007


A compile of 2.6.0 with MPI is failing because it is using 
"mpi.h" from /usr/include instead of the place I tell it. 
Here is the relevant line from my CMakeCache.txt:

MPI_INCLUDE_PATH:PATH=-I/usr/local/packages/
    mpich-1.2.7p1/ch_p4/include;/usr/local/packages/
    mpich-1.2.7p1/ch_p4/include/mpi2c++

The above is actually one line. I had CMake generate verbose 
  make files and found where CMake is producing a bad string 
for cxx's flags:

/usr/bin/g++
    ...
    -I/usr/local/packages/mesa/6.5.2/gnu/include
    -I/usr/local/packages/paraview/2.6.0/src/
=>    Servers/Filters/-I/usr/local/packages/
       mpich-1.2.7p1/ch_p4/include
    -I/usr/local/packages/mpich-1.2.7p1/ch_p4/
       include/mpi2c++
    ...
    /usr/local/packages/paraview/2.6.0/src/Servers/
       Filters/vtkPVMain.cxx

The above is actually one line with some material removed at 
the "...". Each "-I" is preceeded by a blank except on the 
line where I added "=>". I suspect the C++ preprocessor 
ignored that "-I" and so looked elsewhere for mpi.h.

I could find nothing like this in the paraview or cmake bug 
lists but did find a report of the same problem from 
9/7/2006 (Brad King replied that he could not duplicate the 
problem):

http://public.kitware.com/pipermail/cmake/2006-September/010999.html

My system:
    x86_64 processors
    Red Hat Enterprise Linux WS release 4
    CMake 2.4.3 and 2.4.6
    g++ 3.4.6

Suggestions? TIA!

Kent
Pittsburgh Supercomputing Center


More information about the ParaView mailing list