Skip to content

Commit

Permalink
Update tests that generate CMake projects to use the CMAKE_CXX_COMPIL…
Browse files Browse the repository at this point in the history
…ER the main project was CMake'd with. Fixes nlohmann#1747.
  • Loading branch information
Tridacnid committed Nov 19, 2019
1 parent 67259d6 commit fbb0bd7
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions test/cmake_add_subdirectory/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
add_test(NAME cmake_add_subdirectory_configure
COMMAND ${CMAKE_COMMAND}
-G "${CMAKE_GENERATOR}"
-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
-Dnlohmann_json_source=${PROJECT_SOURCE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/project
)
Expand Down
1 change: 1 addition & 0 deletions test/cmake_import/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ add_test(NAME cmake_import_configure
COMMAND ${CMAKE_COMMAND}
-G "${CMAKE_GENERATOR}"
-A "${CMAKE_GENERATOR_PLATFORM}"
-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
-Dnlohmann_json_DIR=${PROJECT_BINARY_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/project
)
Expand Down
1 change: 1 addition & 0 deletions test/cmake_import_minver/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ add_test(NAME cmake_import_minver_configure
COMMAND ${CMAKE_COMMAND}
-G "${CMAKE_GENERATOR}"
-A "${CMAKE_GENERATOR_PLATFORM}"
-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
-Dnlohmann_json_DIR=${PROJECT_BINARY_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/project
)
Expand Down

0 comments on commit fbb0bd7

Please sign in to comment.