From 7312b9c23d537491d2c53d59f498e48d6bbe87fe998693e0314b640f19188ef0 Mon Sep 17 00:00:00 2001 From: Simon Lees Date: Mon, 6 Sep 2021 09:32:21 +0000 Subject: [PATCH] Accepting request 915515 from home:rhabacker:branches:games - Be more verbose when version in generated xxxConfigVersion.cmake files is empty. OBS-URL: https://build.opensuse.org/request/show/915515 OBS-URL: https://build.opensuse.org/package/show/devel:tools:building/cmake?expand=0&rev=471 --- cmake.changes | 6 ++++++ cmake.prov | 6 +++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/cmake.changes b/cmake.changes index bc190e8..078f53d 100644 --- a/cmake.changes +++ b/cmake.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Aug 31 13:19:26 UTC 2021 - Ralf Habacker + +- Be more verbose when version in generated xxxConfigVersion.cmake + files is empty. + ------------------------------------------------------------------- Sun Aug 29 13:38:36 UTC 2021 - Andreas Stieger diff --git a/cmake.prov b/cmake.prov index b0d0092..2b0d692 100644 --- a/cmake.prov +++ b/cmake.prov @@ -69,7 +69,11 @@ class CMakeParser: # set(PACKAGE_VERSION ) version = re.match(r"^set[\ ]*\([\ ]*PACKAGE_VERSION[\ ]+[\"]*([0-9\.]+)[\"]*[\ ]*[.]*\)", line) if version: - return version.groups(1)[0] + _version = version.groups(1)[0] + if _version == '..': + sys.stderr.write("error: Version pattern found without values - '%s' was created incorrectly\n" % versionFile) + return _version + return None