%global srcname qmake2cmake %{?python_enable_dependency_generator} %global gitdate 20220414 %global commit 7f89f98d55ae81a415ad91532b6c32349764c0c5 %global shortcommit %(c=%{commit}; echo ${c:0:7}) %global branch dev Name: python-qmake2cmake Version: 1.0.0%{?gitdate:~git%{gitdate}.%{shortcommit}} Release: 1%{?dist} Summary: Tool to convert qmake .pro files to CMakeLists.txt License: GPL3 URL: https://codereview.qt-project.org/admin/repos/qt/qmake2cmake # Download by wget --content-disposition \ # 'https://codereview.qt-project.org/gitweb?p=qt/qmake2cmake.git;a=snapshot;h=refs/heads/dev;sf=tgz' Source: qmake2cmake-%{branch}-%{shortcommit}.tar.gz BuildArch: noarch %description %{summary}. %package -n python3-%{srcname} Summary: %{summary} %{?python_provide:%python_provide python3-%{srcname}} Provides: %{srcname} = %{version}-%{release} BuildRequires: python3-devel BuildRequires: python3-setuptools BuildRequires: python3dist(pytest) BuildRequires: python3dist(sympy) BuildRequires: python3dist(portalocker) BuildRequires: python3dist(flask) %description -n python3-%{srcname} %{summary}. %prep %autosetup -p1 -n %{srcname}-%{branch}-%{shortcommit} %build %{py3_build} %install %{py3_install} %check %pytest tests %files -n python3-%{srcname} %doc README.md %license LICENSE.GPL3 %{_bindir}/%{srcname} %{_bindir}/%{srcname}_all %{python3_sitelib}/%{srcname}/ %{python3_sitelib}/%{srcname}-*.egg-info/ %changelog * Thu Apr 14 2022 Onuralp Sezer - 1.0.0~git20220414.7f89f98-1 - Initial package