%global srcname pOCCI
-%global commit d7ab21ffa78d0a20ae0cfeb532c07534b4a69a62
-%global shortcommit %(c=%{commit}; echo ${c:0:7})
+%global commit0 d7ab21ffa78d0a20ae0cfeb532c07534b4a69a62
+%global shortcommit0 %(c=%{commit0}; echo ${c:0:7})
# compatibility macros
%{!?py2_build:%global py2_build %{__python2} setup.py build --executable="%{__python2} -s"}
Name: python-%{srcname}
Version: 1.0.2
-Release: 0.20161005git%{shortcommit}%{?dist}
+Release: 0.20161005git%{shortcommit0}%{?dist}
Summary: OCCI compliance testing
License: MIT
URL: https://github.com/CESNET/pOCCI
-Source0: https://github.com/CESNET/%{srcname}/archive/%{commit}/%{srcname}-%{commit}.tar.gz
+Source0: https://github.com/CESNET/%{srcname}/archive/%{commit0}.tar.gz#/%{srcname}-%{shortcommit0}.tar.gz
+
# enable 2to3 with workarounds for buggy setuptools
# (not intended for inclusion in the code)
Patch1: %{srcname}-2to3.diff
%prep
%setup -qc
-pushd %{srcname}-%{commit}
+pushd %{srcname}-%{commit0}
%patch1 -p1
%if 0%{?rhel} && 0%{?rhel} <= 6
sed -e "/'sphinx.ext.viewcode'/d" -i doc/conf.py
%endif
popd
-cp -a %{srcname}-%{commit} python2
-cp -a %{srcname}-%{commit} python3
+cp -a %{srcname}-%{commit0} python2
+cp -a %{srcname}-%{commit0} python3
%build