diff options
Diffstat (limited to 'meta/recipes-devtools/apt/apt/0001-test-libapt-do-not-use-gtest-from-the-host.patch')
-rw-r--r-- | meta/recipes-devtools/apt/apt/0001-test-libapt-do-not-use-gtest-from-the-host.patch | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/meta/recipes-devtools/apt/apt/0001-test-libapt-do-not-use-gtest-from-the-host.patch b/meta/recipes-devtools/apt/apt/0001-test-libapt-do-not-use-gtest-from-the-host.patch new file mode 100644 index 0000000000..503b5a5c0b --- /dev/null +++ b/meta/recipes-devtools/apt/apt/0001-test-libapt-do-not-use-gtest-from-the-host.patch | |||
@@ -0,0 +1,40 @@ | |||
1 | From 28e389a0d1275e7693df84a7d4a58b28364be1a9 Mon Sep 17 00:00:00 2001 | ||
2 | From: Alexander Kanavin <alex.kanavin@gmail.com> | ||
3 | Date: Thu, 22 Oct 2020 17:33:38 +0200 | ||
4 | Subject: [PATCH] test/libapt: do not use gtest from the host | ||
5 | |||
6 | This really does not work when cross-compiling. | ||
7 | |||
8 | Upstream-Status: Inappropriate [oe-core specific] | ||
9 | Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> | ||
10 | --- | ||
11 | test/libapt/CMakeLists.txt | 16 ---------------- | ||
12 | 1 file changed, 16 deletions(-) | ||
13 | |||
14 | diff --git a/test/libapt/CMakeLists.txt b/test/libapt/CMakeLists.txt | ||
15 | index 035ff07..280b83c 100644 | ||
16 | --- a/test/libapt/CMakeLists.txt | ||
17 | +++ b/test/libapt/CMakeLists.txt | ||
18 | @@ -6,22 +6,6 @@ find_path(GTEST_ROOT src/gtest.cc | ||
19 | find_package(GTest) | ||
20 | set(GTEST_DEPENDENCIES) | ||
21 | |||
22 | -if(NOT GTEST_FOUND AND EXISTS ${GTEST_ROOT}) | ||
23 | - include(ExternalProject) | ||
24 | - ExternalProject_Add(gtest PREFIX ./gtest | ||
25 | - SOURCE_DIR ${GTEST_ROOT} | ||
26 | - INSTALL_COMMAND true) | ||
27 | - | ||
28 | - link_directories(${CMAKE_CURRENT_BINARY_DIR}/gtest/src/gtest-build) | ||
29 | - | ||
30 | - set(GTEST_LIBRARIES "-lgtest") | ||
31 | - set(GTEST_DEPENDENCIES "gtest") | ||
32 | - set(GTEST_FOUND TRUE) | ||
33 | - find_path(GTEST_INCLUDE_DIRS NAMES gtest/gtest.h PATHS ${GTEST_ROOT}/include) | ||
34 | - | ||
35 | - message(STATUS "Found GTest at ${GTEST_ROOT}, headers at ${GTEST_INCLUDE_DIRS}") | ||
36 | -endif() | ||
37 | - | ||
38 | if(GTEST_FOUND) | ||
39 | # gtest produces some warnings with the set of warnings we activate, | ||
40 | # so disable the offending warnings while compiling tests for now | ||