Hi Jeff and Gilles,

thank you very much for your answers. I added -I flags for
"valgrind.h" und "cuda.h" to the CPPFLAGS and CXXCPPFLAGS
and related -L flags to LDFLAGS. Now the header files are
usable und I was able to build Open MPI master without errors
with gcc. Tomorrow I can test the installation.

Kind regards and thank you very much for your help once more

Siegmar


Am 15.02.2017 um 14:42 schrieb Jeff Squyres (jsquyres):
Siegmar --

Sorry for the delay in replying.

You should actually put -I flags in CPPFLAGS and CXXCPPFLAGS, not CFLAGS and 
CXXFLAGS.

The difference is:

1. CFLAGS is given to the C compiler when compiling
2. CPPFLAFS is given to the C compiler when compiling and to the C preprocessor 
when preprocessing (i.e., in a standalone fashion / without compiling)

The same is true with CXXFLAGS and CXXCPPFLAGS.

More below.

adding "-I/usr/local/include" to CFLAGS and CXXFLAGS solved the problem.
I have a similar problem with "valgrind.h" and "cuda.h" for both compilers.

loki openmpi-master-201702080209-bc2890e-Linux.x86_64.64_gcc 155 grep 
valgrind.h log.configure.Linux.x86_64.64_gcc
checking valgrind/valgrind.h usability... yes

The above test uses the C compiler, and therefore uses CFLAGS (and CPPFLAGS, 
but that's empty in your case).  It therefore has the -I that you put in CFLAGS.

checking valgrind/valgrind.h presence... no

The above test uses the C preprocessor, but not the C compiler.  Hence, it 
*only* uses CPPFLAGS (and *not* CFLAGS), and therefore does not have the -I 
indicating where the include files live.

The test therefore fails.

configure: WARNING: valgrind/valgrind.h: accepted by the compiler, rejected by 
the preprocessor!
configure: WARNING: valgrind/valgrind.h: proceeding with the compiler's result
checking for valgrind/valgrind.h... yes


loki openmpi-master-201702080209-bc2890e-Linux.x86_64.64_gcc 155 grep cuda.h 
log.configure.Linux.x86_64.64_gcc
checking if --with-cuda is set... found (/usr/local/cuda/include/cuda.h)
checking cuda.h usability... no
checking cuda.h presence... no
checking for cuda.h... no
checking if MPI Extension cuda has C bindings... yes (required)
checking if MPI Extension cuda has mpif.h bindings... no
checking if MPI Extension cuda has "use mpi" bindings... no
checking if MPI Extension cuda has "use mpi_f08" bindings... no
loki openmpi-master-201702080209-bc2890e-Linux.x86_64.64_gcc 156

This looks like it could be an error.  Your config.log shows that it checks 
/usr/local/cuda/include for cuda.h (in the --with-cuda test), but then 
-I/usr/local/cuda/include is not added to CPPFLAGS for the "checking cuda.h 
usability / presence" tests.

Sylvain -- can you look into this?
_______________________________________________
users mailing list
users@lists.open-mpi.org
https://rfd.newmexicoconsortium.org/mailman/listinfo/users

Reply via email to