Rename demo/test options to CPPTRACE_BUILD_TESTING

This commit is contained in:
Jeremy 2023-11-13 10:44:50 -05:00
parent 96a55fc686
commit b28cb54ced
No known key found for this signature in database
GPG Key ID: B4C8300FEC395042
3 changed files with 4 additions and 9 deletions

View File

@ -443,7 +443,7 @@ endif()
# =============================================== Demo/test ===============================================
if(CPPTRACE_BUILD_TEST)
if(CPPTRACE_BUILD_TESTING)
add_executable(test test/test.cpp)
target_compile_features(test PRIVATE cxx_std_11)
target_link_libraries(test PRIVATE ${target_name})
@ -462,9 +462,7 @@ if(CPPTRACE_BUILD_TEST)
COMMAND dsymutil $<TARGET_FILE:test>
)
endif()
endif()
if(CPPTRACE_BUILD_DEMO)
add_executable(demo test/demo.cpp)
target_compile_features(demo PRIVATE cxx_std_11)
target_link_libraries(demo PRIVATE ${target_name})

View File

@ -662,8 +662,7 @@ Other useful configurations:
- `CPPTRACE_USE_EXTERNAL_LIBDWARF=On/Off`: Get libdwarf from `find_package` rather than `FetchContent`.
Testing:
- `CPPTRACE_BUILD_TEST` Build a small test program
- `CPPTRACE_BUILD_DEMO` Build a small demo program
- `CPPTRACE_BUILD_TESTING` Build small demo and test program
- `CPPTRACE_BUILD_TEST_RDYNAMIC` Use `-rdynamic` when compiling the test program
## Testing Methodology

View File

@ -150,12 +150,10 @@ option(CPPTRACE_ADDR2LINE_SEARCH_SYSTEM_PATH "" OFF)
# ---- Other configurations ----
if(PROJECT_IS_TOP_LEVEL)
option(CPPTRACE_BUILD_TEST "" OFF)
option(CPPTRACE_BUILD_DEMO "" OFF)
option(CPPTRACE_BUILD_TESTING "" OFF)
option(CPPTRACE_BUILD_TEST_RDYNAMIC "" OFF)
mark_as_advanced(
CPPTRACE_BUILD_TEST
CPPTRACE_BUILD_DEMO
CPPTRACE_BUILD_TESTING
CPPTRACE_BUILD_TEST_RDYNAMIC
)
endif()