diff options
Diffstat (limited to 'meta-oe/recipes-dbs/rocksdb/files/0001-CMakeLists.txt-Make-the-test-discovery-occur-on-targ.patch')
-rw-r--r-- | meta-oe/recipes-dbs/rocksdb/files/0001-CMakeLists.txt-Make-the-test-discovery-occur-on-targ.patch | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/meta-oe/recipes-dbs/rocksdb/files/0001-CMakeLists.txt-Make-the-test-discovery-occur-on-targ.patch b/meta-oe/recipes-dbs/rocksdb/files/0001-CMakeLists.txt-Make-the-test-discovery-occur-on-targ.patch new file mode 100644 index 0000000000..b0a949fe31 --- /dev/null +++ b/meta-oe/recipes-dbs/rocksdb/files/0001-CMakeLists.txt-Make-the-test-discovery-occur-on-targ.patch | |||
@@ -0,0 +1,42 @@ | |||
1 | From 9abf6cd09c60f0be9a85c055dfdf43698f057f73 Mon Sep 17 00:00:00 2001 | ||
2 | From: Mingli Yu <mingli.yu@windriver.com> | ||
3 | Date: Wed, 25 Sep 2024 13:47:37 +0800 | ||
4 | Subject: [PATCH] CMakeLists.txt: Make the test discovery occur on target | ||
5 | |||
6 | Set DISCOVERY_MODE to PRE_TEST to delay test discovery until just | ||
7 | prior to test execution on the target to fix the build failure as | ||
8 | the default POST_BUILD behavior is not desirable in cross-compiling | ||
9 | env. | ||
10 | |||
11 | /build/tmp/work/core2-64-wrs-linux/rocksdb/9.0.0/build/env_basic_test: error while loading shared libraries: libgflags.so.2.2: cannot open shared object file: No such file or directory | ||
12 | CMake Error at /build/tmp/work/core2-64-wrs-linux/rocksdb/9.0.0/recipe-sysroot-native/usr/share/cmake-3.30/Modules/GoogleTestAddTests.cmake:112 (message): | ||
13 | Error running test executable. | ||
14 | |||
15 | Path: '/build/tmp/work/core2-64-wrs-linux/rocksdb/9.0.0/build/env_basic_test' | ||
16 | Working directory: '/build/tmp/work/core2-64-wrs-linux/rocksdb/9.0.0/build' | ||
17 | Result: 127 | ||
18 | Output: | ||
19 | |||
20 | Upstream-Status: Inappropriate [oe specific] | ||
21 | |||
22 | Signed-off-by: Mingli Yu <mingli.yu@windriver.com> | ||
23 | --- | ||
24 | CMakeLists.txt | 2 +- | ||
25 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
26 | |||
27 | diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
28 | index 403ad1243..f34397798 100644 | ||
29 | --- a/CMakeLists.txt | ||
30 | +++ b/CMakeLists.txt | ||
31 | @@ -1502,7 +1502,7 @@ if(WITH_TESTS) | ||
32 | ) | ||
33 | target_link_libraries(${exename}${ARTIFACT_SUFFIX} testutillib${ARTIFACT_SUFFIX} testharness gtest ${THIRDPARTY_LIBS} ${ROCKSDB_LIB}) | ||
34 | if(NOT "${exename}" MATCHES "db_sanity_test") | ||
35 | - gtest_discover_tests(${exename} DISCOVERY_TIMEOUT 120) | ||
36 | + gtest_discover_tests(${exename} DISCOVERY_TIMEOUT 120 DISCOVERY_MODE PRE_TEST) | ||
37 | add_dependencies(rocksdb_check ${exename}${ARTIFACT_SUFFIX}) | ||
38 | endif() | ||
39 | endforeach(sourcefile ${TESTS}) | ||
40 | -- | ||
41 | 2.34.1 | ||
42 | |||