From 839e327f95a00ab9f8dd4a23d890c7cc18e1aa7c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Santiago=20Ospina=20De=20Los=20R=C3=ADos?= Date: Fri, 3 Jul 2020 08:55:34 +0000 Subject: [PATCH] Add patch for PDELab 2.6 On release 2.6 PDELab had a very old requirement for CMake and didn't allow to install the module properly. i.e. other modules where not able to resolve its CMake targets correctly. This issue was solved for release 2.7. --- packages/dune/package.py | 1 + packages/dune/pdelab_2.6_update_cmake.patch | 44 +++++++++++++++++++++ 2 files changed, 45 insertions(+) create mode 100644 packages/dune/pdelab_2.6_update_cmake.patch diff --git a/packages/dune/package.py b/packages/dune/package.py index 28d2270..88cf343 100644 --- a/packages/dune/package.py +++ b/packages/dune/package.py @@ -315,6 +315,7 @@ class Dune(CMakePackage): # Apply patches patch('virtualenv_from_envvariable.patch', when='+testtools') + patch('pdelab_2.6_update_cmake.patch', when='@2.6+pdelab', working_dir= 'dune-pdelab') def setup_build_environment(self, env): # We reset the DUNE_CONTROL_PATH here because any entries in this diff --git a/packages/dune/pdelab_2.6_update_cmake.patch b/packages/dune/pdelab_2.6_update_cmake.patch new file mode 100644 index 0000000..77ef513 --- /dev/null +++ b/packages/dune/pdelab_2.6_update_cmake.patch @@ -0,0 +1,44 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index dc069408..3971e6aa 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -2,7 +2,7 @@ + project("dune-pdelab" C CXX) + + # general stuff +-cmake_minimum_required(VERSION 2.8.12) ++cmake_minimum_required(VERSION 3.6) + + # guess dune-common build dir + if(NOT (dune-common_DIR OR dune-common_ROOT OR +@@ -25,26 +25,18 @@ dune_project() + # Disable the upstream testing magic, that builds tests during "make test" + set(DUNE_TEST_MAGIC OFF) + +-# To have enable all packages work with cmake-2.8, the module +-# libraries need to be added before the call to dune_enable_all_packages() +-# With cmake 3.1, one would use the MODULE_LIBRARIES argument of +-# dune_enable_all_packages() instead. ++# Use the enable all packages feature ++dune_enable_all_packages(MODULE_LIBRARIES dunepdelab) + + if(NOT MINGW) + set(clock_cc "dune/pdelab/common/clock.cc") + endif() + +-dune_add_library(dunepdelab ++dune_library_add_sources(dunepdelab SOURCES + ${clock_cc} + dune/pdelab/common/hostname.cc + dune/pdelab/common/logtag.cc +- ) +-dune_target_enable_all_packages(dunepdelab) +- +-dune_register_package_flags(LIBRARIES dunepdelab) +- +-# Use the enable all packages feature +-dune_enable_all_packages() ++) + + add_subdirectory(doc) + add_subdirectory(dune/pdelab)