## START: Set by rpmautospec ## (rpmautospec version 0.6.0) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 6; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec # PySide2 is broken with Python 3.12; do not support it on Fedora 39 and later. # # python-pyside2 fails to build with Python 3.12: error: use of undeclared # identifier 'PyUnicode_AS_UNICODE' # https://bugzilla.redhat.com/show_bug.cgi?id=2155447 # # python3-shiboken2-devel wants python < 3.11 # https://bugzilla.redhat.com/show_bug.cgi?id=2149820 # # F39FailsToInstall: python3-pyside2, python3-shiboken2, # python3-shiboken2-devel # https://bugzilla.redhat.com/show_bug.cgi?id=2220452 # # Bug python-pyside2: FTBFS in Fedora rawhide/f39 # https://bugzilla.redhat.com/show_bug.cgi?id=2226300 %bcond pyside2 %{expr:0%{?fedora} < 39} Name: python-qtsass Version: 0.4.0 Release: %autorelease Summary: Compile SCSS files to valid Qt stylesheets # SPDX License: MIT URL: https://github.com/spyder-ide/qtsass # The GitHub archive contains tests, examples, and additional documentation # that the PyPI sdist lacks. Source: %{url}/archive/v%{version}/qtsass-%{version}.tar.gz BuildArch: noarch # Remove useless shebang lines # https://github.com/spyder-ide/qtsass/pull/76 Patch: %{url}/pull/76.patch # In tests, don’t assume Python is called python # https://github.com/spyder-ide/qtsass/pull/77 Patch: %{url}/pull/77.patch BuildRequires: python3-devel # Selected test dependencies from requirements/dev.txt; most entries in that # file are for linters, code coverage, etc. BuildRequires: %{py3_dist pytest} BuildRequires: %{py3_dist flaky} %if %{with pyside2} BuildRequires: %{py3_dist PySide2} %endif BuildRequires: help2man %global common_description %{expand: SASS brings countless amazing features to CSS. Besides being used in web development, CSS is also the way to stylize Qt-based desktop applications. However, Qt’s CSS has a few variations that prevent the direct use of SASS compiler. The purpose of this tool is to fill the gap between SASS and Qt-CSS by handling those variations.} %description %{common_description} %package -n python3-qtsass Summary: %{summary} %if %{with pyside2} # F39FailsToInstall: python3-pyside2, python3-shiboken2, python3-shiboken2-devel # https://bugzilla.redhat.com/show_bug.cgi?id=2220452 Recommends: %{py3_dist PySide2} %endif %description -n python3-qtsass %{common_description} %prep %autosetup -n qtsass-%{version} -p1 %generate_buildrequires %pyproject_buildrequires %build %pyproject_wheel %install %pyproject_install %pyproject_save_files -l qtsass install -d '%{buildroot}%{_mandir}/man1' # Building the man page in %%install instead of %%build is a little weird, but # we need to use the generated entry point from the buildroot. PYTHONPATH='%{buildroot}%{python3_sitelib}' help2man \ --no-info \ --version-string='%{version}' \ --output='%{buildroot}%{_mandir}/man1/qtsass.1' \ '%{buildroot}%{_bindir}/qtsass' %check %pytest -v %files -n python3-qtsass -f %{pyproject_files} %doc AUTHORS.md %doc CHANGELOG.md %doc README.md %doc examples/ %{_bindir}/qtsass %{_mandir}/man1/qtsass.1* %changelog ## START: Generated by rpmautospec * Fri Jan 26 2024 Fedora Release Engineering - 0.4.0-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Mon Jan 22 2024 Fedora Release Engineering - 0.4.0-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Mon Dec 18 2023 Benjamin A. Beasley - 0.4.0-3 - Assert that %%pyproject_files contains a license file * Wed Sep 20 2023 Benjamin A. Beasley - 0.4.0-2 - Cleaner conditional for disabling PySide2 on F39+ * Thu Sep 14 2023 Benjamin A. Beasley - 0.4.0-1 - Update to 0.4.0 * Sun Sep 10 2023 Benjamin A. Beasley - 0.3.2-2 - Confirm License is SPDX MIT * Sun Sep 10 2023 Benjamin A. Beasley - 0.3.2-1 - Update to 0.3.2 * Sun Sep 10 2023 Benjamin A. Beasley - 0.3.1-1 - Update to 0.3.1 * Sun Sep 10 2023 Benjamin A. Beasley - 0.3.0-15 - Use help2man to generate a man page * Sun Sep 10 2023 Benjamin A. Beasley - 0.3.0-14 - Add a weak dep. on PySide2 where available * Sun Sep 10 2023 Benjamin A. Beasley - 0.3.0-13 - Run the tests * Sun Sep 10 2023 Benjamin A. Beasley - 0.3.0-12 - Remove useless shebang lines * Sun Sep 10 2023 Benjamin A. Beasley - 0.3.0-11 - Switch to the GitHub archive as source - Package additional documentation and examples * Sun Sep 10 2023 Benjamin A. Beasley - 0.3.0-10 - Port to pyproject-rpm-macros * Fri Jul 21 2023 Fedora Release Engineering - 0.3.0-8 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild * Tue Jun 13 2023 Python Maint - 0.3.0-7 - Rebuilt for Python 3.12 * Fri Jan 20 2023 Fedora Release Engineering - 0.3.0-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild * Fri Jul 22 2022 Fedora Release Engineering - 0.3.0-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild * Mon Jun 13 2022 Python Maint - 0.3.0-4 - Rebuilt for Python 3.11 * Fri Jan 21 2022 Fedora Release Engineering - 0.3.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild * Fri Jul 23 2021 Fedora Release Engineering - 0.3.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild * Sat Jun 05 2021 Mukundan Ragavan - 0.3.0-1 - Update to 0.3.0 * Fri Jun 04 2021 Python Maint - 0.1.1-5 - Rebuilt for Python 3.10 * Wed Jan 27 2021 Fedora Release Engineering - 0.1.1-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild * Wed Jul 29 2020 Fedora Release Engineering - 0.1.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild * Tue May 26 2020 Miro Hrončok - 0.1.1-2 - Rebuilt for Python 3.9 * Sat Dec 21 2019 Mukundan Ragavan - 0.1.1-1 - Initial package. ## END: Generated by rpmautospec