| From a2c88988b6cfe4023fe78f13519b56a8ac9f568b Mon Sep 17 00:00:00 2001 |
| From: Fabrice Fontaine <fontaine.fabrice@gmail.com> |
| Date: Fri, 4 Mar 2022 17:59:19 +0100 |
| Subject: [PATCH] src/CMakeLists.txt: allow override of wayland pkgdatadir |
| |
| Allow the user to override WAYLAND_{PROTOCOLS_BASE,CLIENT_PKGDATADIR} |
| (needed when cross-compiling) |
| |
| Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> |
| Upstream: https://github.com/glfw/glfw/pull/2053 |
| [Dario: make the patch to be applied with fuzz factor 0] |
| Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com> |
| --- |
| src/CMakeLists.txt | 4 +++- |
| 1 file changed, 3 insertions(+), 1 deletion(-) |
| |
| diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt |
| index 29be6515ae58..1767b3c8ad8f 100644 |
| --- a/src/CMakeLists.txt |
| +++ b/src/CMakeLists.txt |
| @@ -42,7 +42,9 @@ elseif (_GLFW_WAYLAND) |
| |
| find_program(WAYLAND_SCANNER_EXECUTABLE NAMES wayland-scanner) |
| pkg_check_modules(WAYLAND_PROTOCOLS REQUIRED wayland-protocols>=1.15) |
| - pkg_get_variable(WAYLAND_PROTOCOLS_BASE wayland-protocols pkgdatadir) |
| + if (NOT WAYLAND_PROTOCOLS_BASE) |
| + pkg_get_variable(WAYLAND_PROTOCOLS_BASE wayland-protocols pkgdatadir) |
| + endif() |
| |
| macro(wayland_generate protocol_file output_file) |
| add_custom_command(OUTPUT ${output_file}.h |
| -- |
| 2.43.0 |
| |