Andrew Geissler | 8f84068 | 2023-07-21 09:09:43 -0500 | [diff] [blame] | 1 | From ea7b9e6fc0b3f45d6032ce624bed85bbde5ec0bf Mon Sep 17 00:00:00 2001 |
| 2 | From: Alexander Kanavin <alex@linutronix.de> |
| 3 | Date: Wed, 21 Jun 2023 20:03:03 +0200 |
| 4 | Subject: [PATCH] scripts/CMakeLists.txt: append to CMAKE_FIND_ROOT_PATH |
| 5 | instead of replacing it |
| 6 | |
| 7 | Resetting CMAKE_FIND_ROOT_PATH in particular breaks builds in Yocto |
| 8 | (which is a major cross compiling framework). |
| 9 | |
| 10 | Upstream-Status: Backport [https://github.com/KhronosGroup/Vulkan-ValidationLayers/commit/e1b11dc7856765cf45a283ac805ea5066c81cd9b] |
| 11 | Signed-off-by: Alexander Kanavin <alex@linutronix.de> |
| 12 | --- |
| 13 | scripts/CMakeLists.txt | 2 +- |
| 14 | 1 file changed, 1 insertion(+), 1 deletion(-) |
| 15 | |
| 16 | diff --git a/scripts/CMakeLists.txt b/scripts/CMakeLists.txt |
| 17 | index 94c8528c8..cd86c54eb 100644 |
| 18 | --- a/scripts/CMakeLists.txt |
| 19 | +++ b/scripts/CMakeLists.txt |
| 20 | @@ -124,7 +124,7 @@ if (MIMALLOC_INSTALL_DIR) |
| 21 | endif() |
| 22 | |
| 23 | if (CMAKE_CROSSCOMPILING) |
| 24 | - set(CMAKE_FIND_ROOT_PATH ${CMAKE_PREFIX_PATH} PARENT_SCOPE) |
| 25 | + set(CMAKE_FIND_ROOT_PATH ${CMAKE_FIND_ROOT_PATH} ${CMAKE_PREFIX_PATH} PARENT_SCOPE) |
| 26 | else() |
| 27 | set(CMAKE_PREFIX_PATH ${CMAKE_PREFIX_PATH} PARENT_SCOPE) |
| 28 | endif() |