[CMake] Using MPI Profiler Scalasca in Cmake

Thomas Richard Thomas.Richard at imgtec.com
Tue Sep 24 13:21:08 EDT 2013


Can't you simply change the cmake compiler and cflags using CMAKE_CXX_COMPILER and CMAKE_CXX_FLAGS (or add_definitions())?

For example something like:
cmake -DCMAKE_CXX_COMPILER=scalasca -DCMAKE_CXX_FLAGS="-instrument mpicxx"

From: cmake-bounces at cmake.org [mailto:cmake-bounces at cmake.org] On Behalf Of Irina Demeshko
Sent: 24 September 2013 18:14
To: cmake at cmake.org
Subject: [CMake] Using MPI Profiler Scalasca in Cmake



Hi, 

I want to utilize the MPI Profiler "Scalasca" [1] within my CMake project. 
For this reason I need to compile my project differently. 
I need to use
# scalasca -instrument mpicxx -c foo.cpp 
instead of 
# mpicxx -c foo.cpp 
I've tried to specify CX  compiler by:
 export CXX="scalasca -instrument mpicxx",
but it seems like "scalasca -instrument" was ignored
I also tried to specify -D CMAKE_CXX_COMPILER="scalasca -instrument mpicxx",
but have got an Error during compilation.

Do you have any ideas how to make this work? 

Thanks for your time and help!

Irina



More information about the CMake mailing list