-
Notifications
You must be signed in to change notification settings - Fork 288
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1473 from fspindle/feat_catch2
Introduce catch2 3.7.1
- Loading branch information
Showing
73 changed files
with
26,412 additions
and
18,801 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,43 @@ | ||
project(${CATCH2_LIBRARY}) | ||
|
||
set(CATCH2_MAJOR_VERSION 2 PARENT_SCOPE) | ||
set(CATCH2_MINOR_VERSION 13 PARENT_SCOPE) | ||
set(CATCH2_PATCH_VERSION 7 PARENT_SCOPE) | ||
set(CATCH2_MAJOR_VERSION 3 PARENT_SCOPE) | ||
set(CATCH2_MINOR_VERSION 7 PARENT_SCOPE) | ||
set(CATCH2_PATCH_VERSION 1 PARENT_SCOPE) | ||
|
||
vp_include_directories(${CMAKE_CURRENT_SOURCE_DIR}) | ||
|
||
file(GLOB lib_srcs *.cpp) | ||
file(GLOB lib_hdrs *.hpp) | ||
|
||
add_library(${CATCH2_LIBRARY} STATIC ${lib_srcs} ${lib_hdrs}) | ||
target_compile_definitions(${CATCH2_LIBRARY} PRIVATE "CATCH_AMALGAMATED_CUSTOM_MAIN") | ||
|
||
if(UNIX) | ||
if(CMAKE_COMPILER_IS_GNUCXX OR CV_ICC) | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC") | ||
endif() | ||
endif() | ||
|
||
if((VISP_CXX_STANDARD EQUAL VISP_CXX_STANDARD_11) AND CXX11_CXX_FLAGS) | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CXX11_CXX_FLAGS}") | ||
elseif((VISP_CXX_STANDARD EQUAL VISP_CXX_STANDARD_14) AND CXX14_CXX_FLAGS) | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CXX14_CXX_FLAGS}") | ||
elseif((VISP_CXX_STANDARD EQUAL VISP_CXX_STANDARD_17) AND CXX17_CXX_FLAGS) | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CXX17_CXX_FLAGS}") | ||
endif() | ||
|
||
if(ENABLE_SOLUTION_FOLDERS) | ||
set_target_properties(${CATCH2_LIBRARY} PROPERTIES FOLDER "3rdparty") | ||
endif() | ||
|
||
set_target_properties(${CATCH2_LIBRARY} | ||
PROPERTIES OUTPUT_NAME ${CATCH2_LIBRARY} | ||
DEBUG_POSTFIX "${VISP_DEBUG_POSTFIX}" | ||
COMPILE_PDB_NAME ${CATCH2_LIBRARY} | ||
COMPILE_PDB_NAME_DEBUG "${CATCH2_LIBRARY}${VISP_DEBUG_POSTFIX}" | ||
ARCHIVE_OUTPUT_DIRECTORY ${VISP_3P_LIBRARY_OUTPUT_PATH} | ||
) | ||
|
||
if(NOT BUILD_SHARED_LIBS) | ||
vp_install_target(${CATCH2_LIBRARY} EXPORT VISPModules ARCHIVE DESTINATION ${VISP_3P_LIB_INSTALL_PATH} COMPONENT dev) | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.