Is this usage what you are describing? http://cmake.org/Wiki/CMake_FAQ#How_do_I_use_a_different_compiler.3F
On Sat, Apr 12, 2014 at 7:48 AM, <shahi...@mycrypto.biz> wrote: > Hi, > > i want to change CMAKE_C_COMPILER and CMAKE_CXX_COMPILER to gcc-4.7 and > g++-4.7. But when i run cmake, the configuration rollback to default. Can > somebody help me? > > ==> CMakeCCompiler.cmake <== > SET(CMAKE_C_COMPILER "/usr/bin/gcc") > SET(CMAKE_C_COMPILER_ARG1 "") > SET(CMAKE_C_COMPILER_ID "GNU") > SET(CMAKE_C_PLATFORM_ID "Linux") > > SET(CMAKE_AR "/usr/bin/ar") > SET(CMAKE_RANLIB "/usr/bin/ranlib") > SET(CMAKE_LINKER "/usr/bin/ld") > SET(CMAKE_COMPILER_IS_GNUCC 1) > SET(CMAKE_C_COMPILER_LOADED 1) > > ==> CMakeCXXCompiler.cmake <== > SET(CMAKE_CXX_COMPILER "/usr/bin/c++") > SET(CMAKE_CXX_COMPILER_ARG1 "") > SET(CMAKE_CXX_COMPILER_ID "GNU") > SET(CMAKE_CXX_PLATFORM_ID "Linux") > > SET(CMAKE_AR "/usr/bin/ar") > SET(CMAKE_RANLIB "/usr/bin/ranlib") > SET(CMAKE_LINKER "/usr/bin/ld") > SET(CMAKE_COMPILER_IS_GNUCXX 1) > SET(CMAKE_CXX_COMPILER_LOADED 1) > > > > > regards, > Naim S. > -- > > Powered by www.kitware.com > > Please keep messages on-topic and check the CMake FAQ at: > http://www.cmake.org/Wiki/CMake_FAQ > > Kitware offers various services to support the CMake community. For more > information on each offering, please visit: > > CMake Support: http://cmake.org/cmake/help/support.html > CMake Consulting: http://cmake.org/cmake/help/consulting.html > CMake Training Courses: http://cmake.org/cmake/help/training.html > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://www.cmake.org/mailman/listinfo/cmake -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake