1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129
|
From: Roman Lebedev <lebedev.ri@gmail.com>
Date: Sat, 27 Jul 2024 04:02:55 +0300
Subject: XFAIL some integration tests expecting static halide /
cross-compilation
We only build/provide `SHARED` `libHalide`,
so the integration tests that expect to find a `STATIC` one, fail.
Also stub out the cross-compilation integration test, at least for now.
Forwarded: not-needed
---
test/integration/CMakeLists.txt | 75 ++++++++++++++++++++++-------------------
1 file changed, 40 insertions(+), 35 deletions(-)
diff --git a/test/integration/CMakeLists.txt b/test/integration/CMakeLists.txt
index 867bc74..973ec11 100644
--- a/test/integration/CMakeLists.txt
+++ b/test/integration/CMakeLists.txt
@@ -22,10 +22,6 @@ foreach (bsl IN ITEMS "" "-DBUILD_SHARED_LIBS=NO" "-DBUILD_SHARED_LIBS=YES")
set(expect_shared TRUE)
elseif (hsl MATCHES "NO")
set(expect_shared FALSE)
- elseif (bsl MATCHES "YES")
- set(expect_shared TRUE)
- elseif (bsl MATCHES "NO")
- set(expect_shared FALSE)
else ()
set(expect_shared TRUE)
endif ()
@@ -49,18 +45,20 @@ foreach (bsl IN ITEMS "" "-DBUILD_SHARED_LIBS=NO" "-DBUILD_SHARED_LIBS=YES")
--build-options -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER} ${bsl} ${hsl} ${comp} -DCMAKE_BUILD_TYPE=Release
--test-command ${CMAKE_CTEST_COMMAND} --output-on-failure)
- # Run ldd on the output binary. The pass/fail regexes are set later.
- add_test(NAME "${check_link_step}"
- COMMAND ldd "${build_dir}/main")
-
- # Make sure we don't run ldd before building...
- set_tests_properties("${build_step}" PROPERTIES FIXTURES_SETUP "${test_name}")
- set_tests_properties("${check_link_step}" PROPERTIES FIXTURES_REQUIRED "${test_name}")
-
if (expect_shared)
- set_tests_properties("${check_link_step}" PROPERTIES PASS_REGULAR_EXPRESSION "libHalide")
+ # Run ldd on the output binary. The pass/fail regexes are set later.
+ add_test(NAME "${check_link_step}"
+ COMMAND ldd "${build_dir}/main")
+ # Make sure we don't run ldd before building...
+ set_tests_properties("${build_step}" PROPERTIES FIXTURES_SETUP "${test_name}")
+ set_tests_properties("${check_link_step}" PROPERTIES FIXTURES_REQUIRED "${test_name}")
+
+ set_tests_properties("${check_link_step}" PROPERTIES PASS_REGULAR_EXPRESSION "libHalide")
else ()
- set_tests_properties("${check_link_step}" PROPERTIES FAIL_REGULAR_EXPRESSION "libHalide")
+ set_tests_properties("${build_step}"
+ PROPERTIES
+ WILL_FAIL TRUE
+ FAIL_REGULAR_EXPRESSION "Halide `static` libraries were requested but not found.")
endif ()
endforeach ()
endforeach ()
@@ -86,6 +84,11 @@ add_test(NAME aot_static_generator
--build-options -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER} -DHalide_SHARED_LIBS=NO -DCMAKE_BUILD_TYPE=Release
--test-command ${CMAKE_CTEST_COMMAND} --output-on-failure)
+set_tests_properties(aot_static_generator
+ PROPERTIES
+ WILL_FAIL TRUE
+ FAIL_REGULAR_EXPRESSION "Halide `static` libraries were requested but not found.")
+
add_test(NAME aot_shared_generator_adams2019
COMMAND
${CMAKE_CTEST_COMMAND}
@@ -106,32 +109,34 @@ add_test(NAME aot_static_generator_adams2019
set_tests_properties(aot_static_generator_adams2019
PROPERTIES
WILL_FAIL TRUE
- FAIL_REGULAR_EXPRESSION "Autoscheduler Halide::[A-Za-z0-9_]+ does not exist")
+ FAIL_REGULAR_EXPRESSION "Halide `static` libraries were requested but not found.")
##
# Cross compiling test
##
-if (CMAKE_HOST_SYSTEM_NAME MATCHES "Linux")
- add_test(NAME cross_compile_host
- COMMAND
- ${CMAKE_CTEST_COMMAND}
- --build-and-test "${CMAKE_CURRENT_LIST_DIR}/xc" "${CMAKE_CURRENT_BINARY_DIR}/xc-host"
- --build-generator Ninja
- --build-options -DCMAKE_BUILD_TYPE=Release
- --test-command ${CMAKE_CTEST_COMMAND} --output-on-failure)
+if (FALSE)
+ if (CMAKE_HOST_SYSTEM_NAME MATCHES "Linux")
+ add_test(NAME cross_compile_host
+ COMMAND
+ ${CMAKE_CTEST_COMMAND}
+ --build-and-test "${CMAKE_CURRENT_LIST_DIR}/xc" "${CMAKE_CURRENT_BINARY_DIR}/xc-host"
+ --build-generator Ninja
+ --build-options -DCMAKE_BUILD_TYPE=Release
+ --test-command ${CMAKE_CTEST_COMMAND} --output-on-failure)
- add_test(NAME cross_compile_aarch64
- COMMAND
- ${CMAKE_CTEST_COMMAND}
- --build-and-test "${CMAKE_CURRENT_LIST_DIR}/xc" "${CMAKE_CURRENT_BINARY_DIR}/xc-aarch64"
- --build-generator Ninja
- --build-options
- -DCMAKE_TOOLCHAIN_FILE=${CMAKE_CURRENT_LIST_DIR}/../../cmake/toolchain.linux-aarch64.cmake
- -DCMAKE_BUILD_TYPE=Release
- "-Dxc-halide_generators_ROOT=${CMAKE_CURRENT_BINARY_DIR}/xc-host"
- --test-command ${CMAKE_CTEST_COMMAND} --output-on-failure)
+ add_test(NAME cross_compile_aarch64
+ COMMAND
+ ${CMAKE_CTEST_COMMAND}
+ --build-and-test "${CMAKE_CURRENT_LIST_DIR}/xc" "${CMAKE_CURRENT_BINARY_DIR}/xc-aarch64"
+ --build-generator Ninja
+ --build-options
+ -DCMAKE_TOOLCHAIN_FILE=${CMAKE_CURRENT_LIST_DIR}/../../cmake/toolchain.linux-aarch64.cmake
+ -DCMAKE_BUILD_TYPE=Release
+ "-Dxc-halide_generators_ROOT=${CMAKE_CURRENT_BINARY_DIR}/xc-host"
+ --test-command ${CMAKE_CTEST_COMMAND} --output-on-failure)
- set_tests_properties(cross_compile_host PROPERTIES FIXTURES_SETUP xc-host)
- set_tests_properties(cross_compile_aarch64 PROPERTIES FIXTURES_REQUIRED xc-host)
+ set_tests_properties(cross_compile_host PROPERTIES FIXTURES_SETUP xc-host)
+ set_tests_properties(cross_compile_aarch64 PROPERTIES FIXTURES_REQUIRED xc-host)
+ endif ()
endif ()
|