[Pkg-cmake-commits] [cmake] 05/06: Fix FindPkgConfig when no minimum version has been set.
Felix Geyer
fgeyer at moszumanska.debian.org
Sun Sep 20 19:21:41 UTC 2015
This is an automated email from the git hooks/post-receive script.
fgeyer pushed a commit to branch master
in repository cmake.
commit f6c4ef7488a84a2efe92cb66ff7caae99ec50ab5
Author: Felix Geyer <fgeyer at debian.org>
Date: Sun Sep 20 20:47:26 2015 +0200
Fix FindPkgConfig when no minimum version has been set.
* Fix FindPkgConfig when no minimum version has been set.
- FindPkgConfig_remove_variable_dereference.patch
---
debian/changelog | 2 ++
...FindPkgConfig_remove_variable_dereference.patch | 39 ++++++++++++++++++++++
debian/patches/series | 1 +
3 files changed, 42 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index bb64e4c..8d8d1c7 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -5,6 +5,8 @@ cmake (3.3.2-1) UNRELEASED; urgency=medium
* Make compiler feature testing more reliable.
- Fixes testsuite failure on alpha. (Closes: #789807)
- Features_Extract_strings_from_test_binary_more_reliably.patch
+ * Fix FindPkgConfig when no minimum version has been set.
+ - FindPkgConfig_remove_variable_dereference.patch
-- Felix Geyer <fgeyer at debian.org> Fri, 04 Sep 2015 17:12:34 +0200
diff --git a/debian/patches/FindPkgConfig_remove_variable_dereference.patch b/debian/patches/FindPkgConfig_remove_variable_dereference.patch
new file mode 100644
index 0000000..5ab3e34
--- /dev/null
+++ b/debian/patches/FindPkgConfig_remove_variable_dereference.patch
@@ -0,0 +1,39 @@
+From b9ec9392da21a3421e48c6961976060d872faffb Mon Sep 17 00:00:00 2001
+From: Rolf Eike Beer <eike at sf-mail.de>
+Date: Tue, 18 Aug 2015 12:14:43 +0200
+Subject: [PATCH] FindPkgConfig: remove variable dereference
+
+If CMAKE_MINIMUM_REQUIRED_VERSION is not set because no
+cmake_minimum_required() call is present this line can lead to an error as that
+string is empty so too few arguments are passed to if():
+
+See also "/var/tmp/paludis/build/kde-krdc-15.08.0/work/build/CMakeFiles/CMakeOutput.log".
+See also "/var/tmp/paludis/build/kde-krdc-15.08.0/work/build/CMakeFiles/CMakeError.log".
+CMake Error at /usr/share/cmake/Modules/FindPkgConfig.cmake:112 (elseif):
+ given arguments:
+
+ "VERSION_LESS" "3.1"
+
+ Unknown arguments specified
+Call Stack (most recent call first):
+ /usr/share/cmake/Modules/FindPkgConfig.cmake:501 (_pkgconfig_parse_options)
+ /usr/share/cmake/Modules/FindOpenSSL.cmake:43 (pkg_check_modules)
+---
+ Modules/FindPkgConfig.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Modules/FindPkgConfig.cmake b/Modules/FindPkgConfig.cmake
+index 526a62e..ae6903e 100644
+--- a/Modules/FindPkgConfig.cmake
++++ b/Modules/FindPkgConfig.cmake
+@@ -109,7 +109,7 @@ macro(_pkgconfig_parse_options _result _is_req _is_silent _no_cmake_path _no_cma
+ set(${_no_cmake_path} 1)
+ set(${_no_cmake_environment_path} 1)
+ endif()
+- elseif(${CMAKE_MINIMUM_REQUIRED_VERSION} VERSION_LESS 3.1)
++ elseif(CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 3.1)
+ set(${_no_cmake_path} 1)
+ set(${_no_cmake_environment_path} 1)
+ endif()
+--
+1.7.10.4
diff --git a/debian/patches/series b/debian/patches/series
index 09adfa8..0c9f3dc 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -5,3 +5,4 @@ FindJNI.cmake.mips.patch
fix-hdf5-hl.patch
FindJNI-Add-support-for-x32-architecture-on-Linux.patch
Features_Extract_strings_from_test_binary_more_reliably.patch
+FindPkgConfig_remove_variable_dereference.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-cmake/cmake.git
More information about the Pkg-cmake-commits
mailing list