File tree Expand file tree Collapse file tree 4 files changed +22
-8
lines changed
Expand file tree Collapse file tree 4 files changed +22
-8
lines changed Original file line number Diff line number Diff line change 1515# specific language governing permissions and limitations
1616# under the License.
1717
18- add_library (iceberg_test_util STATIC cmd_util.cc docker_compose_util.cc)
18+ set (ICEBERG_TEST_UTIL_SOURCES tmp_util.cc)
19+ set (ICEBERG_TEST_UTIL_HEADERS tmp_util.h)
20+
21+ # Platform-specific integration test utilities (Linux-specific)
22+ if (ICEBERG_BUILD_REST_INTEGRATION_TESTS)
23+ list (APPEND ICEBERG_TEST_UTIL_SOURCES cmd_util.cc docker_compose_util.cc)
24+ list (APPEND ICEBERG_TEST_UTIL_HEADERS cmd_util.h docker_compose_util.h)
25+ endif ()
26+
27+ add_library (iceberg_test_util STATIC ${ICEBERG_TEST_UTIL_SOURCES} )
1928
2029target_include_directories (iceberg_test_util PUBLIC ${CMAKE_SOURCE_DIR} /src
2130 ${CMAKE_BINARY_DIR} /src)
2231
2332target_link_libraries (iceberg_test_util PUBLIC iceberg_static)
2433
25- install (FILES cmd_util.h docker_compose_util.h
34+ install (FILES ${ICEBERG_TEST_UTIL_HEADERS}
2635 DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} /iceberg/test /util)
Original file line number Diff line number Diff line change 1515# specific language governing permissions and limitations
1616# under the License.
1717
18- iceberg_test_util_sources = files (' cmd_util.cc' , ' docker_compose_util.cc' )
18+ iceberg_test_util_sources = files (' tmp_util.cc' )
19+
20+ # Platform-specific integration test utilities (Linux-specific)
21+ if get_option (' rest_integration_test' ).enabled()
22+ iceberg_test_util_sources += files (' cmd_util.cc' , ' docker_compose_util.cc' )
23+ install_headers (
24+ [' cmd_util.h' , ' docker_compose_util.h' ],
25+ subdir : ' iceberg/test/util' ,
26+ )
27+ endif
1928
2029iceberg_test_util_lib = static_library (
2130 ' iceberg_test_util' ,
@@ -29,8 +38,4 @@ iceberg_test_util_dep = declare_dependency(
2938 include_directories : include_directories (' .' ),
3039)
3140
32- # Install headers for potential external test usage
33- install_headers (
34- [' cmd_util.h' , ' docker_compose_util.h' ],
35- subdir : ' iceberg/test/util' ,
36- )
41+ install_headers ([' tmp_util.h' ], subdir : ' iceberg/test/util' )
You can’t perform that action at this time.
0 commit comments