<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman,new york,times,serif;font-size:12pt;color:#000000;"><div>I'm using a MSVC 9.0 Generator with Cmake 2.8.2<br>
<br>How do I add a change so that the command for my RUN_TESTS project changes from the default of:<br><br>"C:\Program Files\CMake 2.8\bin\ctest.exe" --force-new-ctest-process&nbsp; -C $(OutDir)<br>if errorlevel 1 goto VCReportError<br><br>to<br><br>"C:\Program Files\CMake 2.8\bin\ctest.exe" --force-new-ctest-process&nbsp; -VV -C $(OutDir)<br>if errorlevel 1 goto VCReportError<br><br><br>My CMakeLists file has the following sections (I've omitted un-interesting items):<br><br><br>cmake_minimum_required (VERSION 2.6)<br>set(Boost_ADDITIONAL_VERSIONS "1.42" "1.42.0" "1.43" "1.43.0" "1.44" "1.44.0")<br>set(Boost_USE_MULTITHREADED ON)<br>set(Boost_USE_STATIC_LIBS&nbsp;&nbsp; ON)<br><br>project (SomthingCalc)<br>#convienent way to handle gtest so that the 5 gtest locations<br>#list below don't have to be set within cmake<br>#use of this assumes a folder layout such that 'include', 'Debug', and<br>#'Release' are subfolders of IDT_GTEST_ROOT and contain the
 neede files<br>set(IDT_GTEST_ROOT "NOTFOUND" CACHE PATH "root for gtest" )<br>if( NOT IDT_GTEST_ROOT EQUAL "NOTFOUND")<br>&nbsp; set( GTEST_INCLUDE_DIR&nbsp;&nbsp; ${IDT_GTEST_ROOT}/include )<br>&nbsp; set( GTEST_LIBRARY&nbsp; ${IDT_GTEST_ROOT}/Release/gtest.lib )<br>&nbsp; set( GTEST_MAIN_LIBRARY&nbsp; ${IDT_GTEST_ROOT}/Release/gtest_main.lib ) <br>&nbsp; set( GTEST_LIBRARY_DEBUG&nbsp; ${IDT_GTEST_ROOT}/Debug/gtest.lib )<br>&nbsp; set( GTEST_MAIN_LIBRARY_DEBUG&nbsp; ${IDT_GTEST_ROOT}/Debug/gtest_main.lib&nbsp; )<br>endif() <br><br>set(BOOST_ROOT "C:/boost_1_43_0" CACHE PATH "root for boost")<br>find_package( Boost 1.41.0 COMPONENTS&nbsp; filesystem system REQUIRED )<br><br>enable_testing()&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br>find_package(GTest
 REQUIRED)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br>include_directories(${GTEST_INCLUDE_DIRS})&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br><br>#threads needed for gtest in linux<br>if(NOT MSVC)<br>&nbsp; find_package(Threads)<br>endif(NOT MSVC)<br><br>if(Boost_FOUND)<br>&nbsp; include_directories(${Boost_INCLUDE_DIRS})<br><br>&nbsp; #Keith's unit tests that use the regular 'database'<br>&nbsp; add_executable(KeithGtestRegular <br>&nbsp;&nbsp;&nbsp; unittestElements.cpp<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; ...<br>&nbsp;&nbsp;&nbsp; )<br>&nbsp; target_link_libraries(KeithGtestRegular&nbsp;&nbsp; ${GTEST_BOTH_LIBRARIES})<br>&nbsp; target_link_libraries(KeithGtestRegular&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp;
 ${Boost_LIBRARIES}<br>&nbsp;&nbsp;&nbsp; )<br>&nbsp; if (CMAKE_USE_PTHREADS_INIT)<br>&nbsp;&nbsp;&nbsp; target_link_libraries(KeithGtestRegular&nbsp; ${CMAKE_THREAD_LIBS_INIT})<br>&nbsp; endif()<br><br>&nbsp; add_test(RegularGtests KeithGtestRegular&nbsp; "--gtest_output=xml:RegularTests.xml" ) <br><br>endif()<br><br></div>
</div><br>







      </body></html>