cmake.prov: handle exceptions

This commit is contained in:
Jan Grulich 2015-03-23 10:18:31 +01:00
parent 35c8f502e7
commit 9a29aa1646
2 changed files with 9 additions and 2 deletions

View File

@ -63,7 +63,11 @@ class CMakeParser:
def resolveCMakeModuleVersion(self, modulePath, cmakeModule, lowercase):
versionFile = ("%s/%s-config-version.cmake" if lowercase else "%s/%sConfigVersion.cmake") % (modulePath, cmakeModule)
f = open(versionFile, 'r')
try:
f = open(versionFile, 'r')
except:
return None
for line in f:
line = line.strip()

View File

@ -13,7 +13,7 @@
Name: cmake
Version: 3.2.1
Release: 3%{?dist}
Release: 4%{?dist}
Summary: Cross-platform make system
Group: Development/Tools
@ -233,6 +233,9 @@ update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
%changelog
* Mon Mar 23 2015 Daniel Vrátil <dvratil@redhat.com> - 3.2.1-4
- cmake.prov: handle exceptions
* Wed Mar 18 2015 Rex Dieter <rdieter@fedoraproject.org> 3.2.1-3
- cmake.prov: use /usr/bin/python (instead of /bin/python)