[gnome-build-meta/mcatanzaro/epiphany-pdfs: 7/7] Fix openjpeg's cmakeconfig
- From: Javier Jardón Cabezas <jjardon src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-build-meta/mcatanzaro/epiphany-pdfs: 7/7] Fix openjpeg's cmakeconfig
- Date: Fri, 4 Jan 2019 17:01:45 +0000 (UTC)
commit 8360bffd50bf526c057b51fd8948287875b458da
Author: Michael Catanzaro <mcatanzaro igalia com>
Date: Fri Dec 28 11:12:40 2018 -0600
Fix openjpeg's cmakeconfig
It's telling poppler to look for headers in /usr/lib/include instead of
/usr/include, oops. Backport upstream patch to fix it.
elements/sdk/openjpeg.bst | 2 ++
files/openjpeg/fix-cmake-config.patch | 31 +++++++++++++++++++++++++++++++
2 files changed, 33 insertions(+)
---
diff --git a/elements/sdk/openjpeg.bst b/elements/sdk/openjpeg.bst
index f919258..dce5ce6 100644
--- a/elements/sdk/openjpeg.bst
+++ b/elements/sdk/openjpeg.bst
@@ -8,6 +8,8 @@ sources:
path: files/openjpeg/CVE-2018-6616.patch
- kind: patch
path: files/openjpeg/CVE-2018-18088.patch
+- kind: patch
+ path: files/openjpeg/fix-cmake-config.patch
depends:
- filename: base/buildsystem-cmake.bst
junction: freedesktop-sdk.bst
diff --git a/files/openjpeg/fix-cmake-config.patch b/files/openjpeg/fix-cmake-config.patch
new file mode 100644
index 0000000..c8d127f
--- /dev/null
+++ b/files/openjpeg/fix-cmake-config.patch
@@ -0,0 +1,31 @@
+From 24fd3ce777a64b8b315cfe1ee642ec7b1cc6aa97 Mon Sep 17 00:00:00 2001
+From: Libor Bukata <libor bukata oracle com>
+Date: Fri, 31 Aug 2018 12:57:40 +0200
+Subject: [PATCH] The change makes a relative path to header files always
+ correct regardless of the number of sub- directories in
+ OPENJPEG_INSTALL_PACKAGE_DIR variable.
+
+---
+ cmake/OpenJPEGConfig.cmake.in | 9 +++++++--
+ 1 file changed, 7 insertions(+), 2 deletions(-)
+
+diff --git a/cmake/OpenJPEGConfig.cmake.in b/cmake/OpenJPEGConfig.cmake.in
+index b20294ca5..2925108ad 100644
+--- a/cmake/OpenJPEGConfig.cmake.in
++++ b/cmake/OpenJPEGConfig.cmake.in
+@@ -26,8 +26,13 @@ get_filename_component(SELF_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
+ if(EXISTS ${SELF_DIR}/OpenJPEGTargets.cmake)
+ # This is an install tree
+ include(${SELF_DIR}/OpenJPEGTargets.cmake)
+- get_filename_component(OPENJPEG_INCLUDE_ROOT "${SELF_DIR}/../../@OPENJPEG_INSTALL_INCLUDE_DIR@" ABSOLUTE)
+- set(OPENJPEG_INCLUDE_DIRS ${OPENJPEG_INCLUDE_ROOT})
++
++ # We find a relative path from the PKG directory to header files.
++ set(PKG_DIR "@CMAKE_INSTALL_PREFIX@/@OPENJPEG_INSTALL_PACKAGE_DIR@")
++ set(INC_DIR "@CMAKE_INSTALL_PREFIX@/@OPENJPEG_INSTALL_INCLUDE_DIR@")
++ file(RELATIVE_PATH PKG_TO_INC_RPATH "${PKG_DIR}" "${INC_DIR}")
++
++ get_filename_component(OPENJPEG_INCLUDE_DIRS "${SELF_DIR}/${PKG_TO_INC_RPATH}" ABSOLUTE)
+
+ else()
+ if(EXISTS ${SELF_DIR}/OpenJPEGExports.cmake)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]