| 1 |
Description: Make upstream easier to package |
| 2 |
This: |
| 3 |
* allows upstream to be built and installed as a single source |
| 4 |
* fixes upstream's CMakeLists.txt to use GNUInstallDirs |
| 5 |
Author: Enrico Zini <[email protected]> |
| 6 |
|
| 7 |
--- |
| 8 |
The information above should follow the Patch Tagging Guidelines, please |
| 9 |
checkout https://dep.debian.net/deps/dep3/ to learn about the format. Here |
| 10 |
are templates for supplementary fields that you might want to add: |
| 11 |
|
| 12 |
Origin: (upstream|backport|vendor|other), (<patch-url>|commit:<commit-id>) |
| 13 |
Bug: <upstream-bugtracker-url> |
| 14 |
Bug-Debian: https://bugs.debian.org/<bugnumber> |
| 15 |
Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber> |
| 16 |
Forwarded: (no|not-needed|<patch-forwarded-url>) |
| 17 |
Applied-Upstream: <version>, (<commit-url>|commit:<commid-id>) |
| 18 |
Reviewed-By: <name and email of someone who approved/reviewed the patch> |
| 19 |
Last-Update: 2024-12-27 |
| 20 |
|
| 21 |
--- /dev/null |
| 22 |
+++ fcidecomp-2.1.1/CMakeLists.txt |
| 23 |
@@ -0,0 +1,15 @@ |
| 24 |
+cmake_minimum_required(VERSION 3.15.0) |
| 25 |
+project(fcidecomp) |
| 26 |
+ |
| 27 |
+# Set build directories |
| 28 |
+include(GNUInstallDirs) |
| 29 |
+set(HDF5_PLUGIN_INSTALL_PATH "${CMAKE_INSTALL_LIBDIR}/hdf5/serial/plugins" CACHE PATH |
| 30 |
+ "Where to install the dynamic HDF5-plugin") |
| 31 |
+ |
| 32 |
+# Build library |
| 33 |
+add_subdirectory(src/fcidecomp/fcicomp-jpegls) |
| 34 |
+ |
| 35 |
+# Build filter plugin |
| 36 |
+set(FCICOMP_JPEGLS_INCLUDE_DIR ../fcicomp-jpegls/include/) |
| 37 |
+add_subdirectory(src/fcidecomp/fcicomp-H5Zjpegls) |
| 38 |
+TARGET_LINK_LIBRARIES (H5Zjpegls PRIVATE fcicomp_jpegls) |
| 39 |
--- fcidecomp-2.1.1.orig/src/fcidecomp/fcicomp-H5Zjpegls/CMakeLists.txt |
| 40 |
+++ fcidecomp-2.1.1/src/fcidecomp/fcicomp-H5Zjpegls/CMakeLists.txt |
| 41 |
@@ -87,7 +87,7 @@ SET (CMAKE_MODULE_PATH ${FCICOMP_CMAKE_M |
| 42 |
SET (ENV{FCICOMP_JPEGLS_ROOT} ${FCICOMP_JPEGLS_ROOT}) |
| 43 |
|
| 44 |
# Find FCICOMP_JPEGLS includes and library |
| 45 |
-FIND_PACKAGE (FCICOMP_JPEGLS REQUIRED) |
| 46 |
+#FIND_PACKAGE (FCICOMP_JPEGLS REQUIRED) |
| 47 |
INCLUDE_DIRECTORIES (${FCICOMP_JPEGLS_INCLUDE_DIR}) |
| 48 |
|
| 49 |
#----------------------------------------------------------------------------- |
| 50 |
@@ -256,8 +256,8 @@ ENDIF (EXTRA_LINK_FLAGS_DEBUG) |
| 51 |
STRING (TOLOWER ${PROJECT_NAME} PROJECT_NAME_LOWER) |
| 52 |
|
| 53 |
# Define the include and lib install dir |
| 54 |
-SET (INCLUDE_INSTALL_DIR include/) |
| 55 |
-SET (LIBRARY_INSTALL_DIR hdf5/lib/plugin/) |
| 56 |
+SET (INCLUDE_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}") |
| 57 |
+SET (LIBRARY_INSTALL_DIR "${HDF5_PLUGIN_INSTALL_PATH}") |
| 58 |
|
| 59 |
# Install the library |
| 60 |
INSTALL (TARGETS ${TARGET_LIBRARY_NAME} |
| 61 |
--- fcidecomp-2.1.1.orig/src/fcidecomp/fcicomp-jpegls/CMakeLists.txt |
| 62 |
+++ fcidecomp-2.1.1/src/fcidecomp/fcicomp-jpegls/CMakeLists.txt |
| 63 |
@@ -229,8 +229,8 @@ ENDIF (EXTRA_LINK_FLAGS_DEBUG) |
| 64 |
STRING (TOLOWER ${PROJECT_NAME} PROJECT_NAME_LOWER) |
| 65 |
|
| 66 |
# Define the include and lib install dir |
| 67 |
-SET (INCLUDE_INSTALL_DIR include/) |
| 68 |
-SET (LIBRARY_INSTALL_DIR lib/) |
| 69 |
+SET (INCLUDE_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}") |
| 70 |
+SET (LIBRARY_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}") |
| 71 |
|
| 72 |
# Install the library |
| 73 |
INSTALL (TARGETS ${TARGET_LIBRARY_NAME} |