Skip to content

Commit dcb9668

Browse files
authored
Add include path for build_info.h in test target
Add conditional include path for parse_args.cpp in test target.
1 parent 7e53503 commit dcb9668

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

CMakeLists.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -731,6 +731,13 @@ if(BUILD_TESTING)
731731
if(USE_OPENMP)
732732
target_link_libraries(${UT_TARGET} OpenMP::OpenMP_CXX)
733733
endif()
734+
if("${UT_SOURCES}" MATCHES "parse_args.cpp")
735+
message(STATUS "Adding build_info.h include path for test target: ${UT_TARGET}")
736+
target_include_directories(${UT_TARGET}
737+
PRIVATE
738+
${CMAKE_BINARY_DIR}/source/source_io
739+
)
740+
endif()
734741
install(TARGETS ${UT_TARGET} DESTINATION ${CMAKE_BINARY_DIR}/tests)
735742
add_test(
736743
NAME ${UT_TARGET}

0 commit comments

Comments
 (0)