File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -35,6 +35,10 @@ if(ARROW_TESTING)
3535 # Even though this is still just an object library we still need to "link" our
3636 # dependencies so that include paths are configured correctly
3737 target_link_libraries (arrow_compute_core_testing PUBLIC ${ARROW_GTEST_GMOCK} )
38+ # When using static test linkage, define ARROW_STATIC so test_util_internal.cc doesn't expect DLL imports
39+ if (ARROW_TEST_LINKAGE STREQUAL "static" )
40+ target_compile_definitions (arrow_compute_core_testing PRIVATE ARROW_STATIC )
41+ endif ()
3842endif ()
3943
4044# Define arrow_compute_testing object library for test files requiring extra kernels.
@@ -46,6 +50,10 @@ if(ARROW_TESTING AND ARROW_COMPUTE)
4650 target_link_libraries (arrow_compute_testing
4751 PUBLIC $<TARGET_OBJECTS :arrow_compute_core_testing >
4852 PUBLIC ${ARROW_GTEST_GTEST} )
53+ # When using static test linkage, define ARROW_STATIC so test_env.cc doesn't expect DLL imports
54+ if (ARROW_TEST_LINKAGE STREQUAL "static" )
55+ target_compile_definitions (arrow_compute_testing PRIVATE ARROW_STATIC )
56+ endif ()
4957endif ()
5058
5159set (ARROW_COMPUTE_TEST_PREFIX "arrow-compute" )
Original file line number Diff line number Diff line change @@ -26,6 +26,10 @@ if(ARROW_TESTING)
2626 # Even though this is still just an object library we still need to "link" our
2727 # dependencies so that include paths are configured correctly
2828 target_link_libraries (arrow_compute_kernels_testing PUBLIC ${ARROW_GTEST_GMOCK} )
29+ # When using static test linkage, define ARROW_STATIC so test_util_internal.cc doesn't expect DLL imports
30+ if (ARROW_TEST_LINKAGE STREQUAL "static" )
31+ target_compile_definitions (arrow_compute_kernels_testing PRIVATE ARROW_STATIC )
32+ endif ()
2933endif ()
3034
3135add_arrow_test (scalar_cast_test
You can’t perform that action at this time.
0 commit comments