[med-svn] [ismrmrd] 03/11: Fix usability of ISMRMRD CMake packaging.

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Sat Nov 26 11:58:18 UTC 2016


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch master
in repository ismrmrd.

commit fc9a68d1ae837ae06203c8c1b7d19b050d91c773
Author: Ghislain Antony Vaillant <ghisvail at gmail.com>
Date:   Fri Nov 11 12:40:50 2016 +0000

    Fix usability of ISMRMRD CMake packaging.
    
    - New patch Fix-CMake-package-configuration.patch.
    - New patch Fix-CMake-package-detection.patch.
    - Drop Use-Debian-CMake-find-module-location.patch, no longer required.
    - Install CMake configuration to -dev package.
    
    Gbp-Dch: full
---
 debian/libismrmrd-dev.install                      |  2 +-
 .../patches/Fix-CMake-package-configuration.patch  | 24 +++++++++++++++++++
 debian/patches/Fix-CMake-package-detection.patch   | 27 ++++++++++++++++++++++
 .../Use-Debian-CMake-find-module-location.patch    | 21 -----------------
 debian/patches/series                              |  3 ++-
 5 files changed, 54 insertions(+), 23 deletions(-)

diff --git a/debian/libismrmrd-dev.install b/debian/libismrmrd-dev.install
index 7aa632d..59c6616 100644
--- a/debian/libismrmrd-dev.install
+++ b/debian/libismrmrd-dev.install
@@ -1,3 +1,3 @@
 usr/include/ismrmrd
 usr/lib/*.so
-usr/share/ismrmrd/cmake/FindIsmrmrd.cmake usr/lib/cmake/ismrmrd/
+usr/lib/cmake
diff --git a/debian/patches/Fix-CMake-package-configuration.patch b/debian/patches/Fix-CMake-package-configuration.patch
new file mode 100644
index 0000000..5d7c99b
--- /dev/null
+++ b/debian/patches/Fix-CMake-package-configuration.patch
@@ -0,0 +1,24 @@
+From: Ghislain Antony Vaillant <ghisvail at gmail.com>
+Date: Fri, 11 Nov 2016 12:36:34 +0000
+Subject: Fix CMake package configuration.
+
+---
+ CMakeLists.txt | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 5e9b1a9..e6b7589 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -258,6 +258,11 @@ configure_file(cmake/ISMRMRDConfig.cmake.in
+ set(CONFIG_ISMRMRD_SCHEMA_DIR   ${CMAKE_INSTALL_PREFIX}/share/ismrmrd/schema)
+ set(CONFIG_ISMRMRD_TARGET_INCLUDE_DIRS ${CMAKE_INSTALL_PREFIX}/include)
+ set(CONFIG_ISMRMRD_LIBRARY_DIRS ${CMAKE_INSTALL_PREFIX}/lib)
++if (ISMRMRD_DATASET_SUPPORT)
++  list(APPEND CONFIG_ISMRMRD_TARGET_INCLUDE_DIRS ${HDF5_INCLUDE_DIRS})
++  list(APPEND CONFIG_ISMRMRD_LIBRARY_DIRS ${HDF5_LIBRARY_DIRS})
++  list(APPEND ISMRMRD_LIBRARIES ${HDF5_LIBRARIES})
++endif ()
+ configure_file(cmake/ISMRMRDConfig.cmake.in
+   "${CMAKE_CURRENT_BINARY_DIR}/InstallFiles/ISMRMRDConfig.cmake"
+   @ONLY
diff --git a/debian/patches/Fix-CMake-package-detection.patch b/debian/patches/Fix-CMake-package-detection.patch
new file mode 100644
index 0000000..379cae9
--- /dev/null
+++ b/debian/patches/Fix-CMake-package-detection.patch
@@ -0,0 +1,27 @@
+From: Ghislain Antony Vaillant <ghisvail at gmail.com>
+Date: Wed, 16 Nov 2016 10:29:41 +0000
+Subject: Fix CMake package detection.
+
+---
+ examples/c/CMakeLists.txt | 8 +-------
+ 1 file changed, 1 insertion(+), 7 deletions(-)
+
+diff --git a/examples/c/CMakeLists.txt b/examples/c/CMakeLists.txt
+index 778ab5a..b9a30c4 100644
+--- a/examples/c/CMakeLists.txt
++++ b/examples/c/CMakeLists.txt
+@@ -3,13 +3,7 @@ project(ISMRMRD-C-EXAMPLE)
+ 
+ # if building this example as a standalone project
+ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
+-    if(NOT DEFINED ENV{ISMRMRD_HOME})
+-        message(FATAL_ERROR "ISMRMRD_HOME environment variable must be defined")
+-    endif()
+-
+-    list(APPEND CMAKE_MODULE_PATH "$ENV{ISMRMRD_HOME}/share/ismrmrd/cmake")
+-
+-    find_package(Ismrmrd REQUIRED)
++    find_package(ISMRMRD REQUIRED)
+ 
+ # otherwise, building it as part of ISMRMRD itself
+ else()
diff --git a/debian/patches/Use-Debian-CMake-find-module-location.patch b/debian/patches/Use-Debian-CMake-find-module-location.patch
deleted file mode 100644
index 4dd5d96..0000000
--- a/debian/patches/Use-Debian-CMake-find-module-location.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-From: Ghislain Antony Vaillant <ghisvail at gmail.com>
-Date: Sat, 5 Mar 2016 16:18:09 +0000
-Subject: Use Debian CMake find module location.
-
----
- examples/c/CMakeLists.txt | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/examples/c/CMakeLists.txt b/examples/c/CMakeLists.txt
-index 778ab5a..a4d8136 100644
---- a/examples/c/CMakeLists.txt
-+++ b/examples/c/CMakeLists.txt
-@@ -7,7 +7,7 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
-         message(FATAL_ERROR "ISMRMRD_HOME environment variable must be defined")
-     endif()
- 
--    list(APPEND CMAKE_MODULE_PATH "$ENV{ISMRMRD_HOME}/share/ismrmrd/cmake")
-+    list(APPEND CMAKE_MODULE_PATH "$ENV{ISMRMRD_HOME}/lib/cmake/ismrmrd")
- 
-     find_package(Ismrmrd REQUIRED)
- 
diff --git a/debian/patches/series b/debian/patches/series
index 3934b8b..0bc9b02 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,4 +1,5 @@
 Disable-HTML-timestamps.patch
 Use-explicit-64-bit-shifts-in-testsuite.patch
-Use-Debian-CMake-find-module-location.patch
 Fix-HDF5-detection-with-CMake-3.6.patch
+Fix-CMake-package-configuration.patch
+Fix-CMake-package-detection.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/ismrmrd.git



More information about the debian-med-commit mailing list