## START: Set by rpmautospec ## (rpmautospec version 0.7.3) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 1; 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 %global pypi_name medimages4tests %global forgeurl https://github.com/australian-imaging-service/medimages4tests Name: python-%{pypi_name} Version: 0.5.7 Release: %{autorelease} Summary: Generates dummy medical image for image handling tests %forgemeta License: Apache-2.0 URL: %forgeurl Source: %forgesource # License change from CC0-1.0 to Apache-2.0 # https://github.com/Australian-Imaging-Service/xnat4tests/issues/17 Patch: license_change.patch BuildArch: noarch BuildRequires: git-core BuildRequires: python3-devel BuildRequires: python3dist(pytest) BuildRequires: python3dist(versioneer) %global _description %{expand: Generate dummy medical images, with junk image data but realistic headers, to test imaging handling pipelines.} %description %_description %package -n python3-%{pypi_name} Summary: %{summary} %description -n python3-%{pypi_name} %_description %prep %forgeautosetup -p1 -S git # Remove empty file (rpmlint reports as error) [ -s medimages4tests/mri/neuro/base.py ] || rm medimages4tests/mri/neuro/base.py # Generate version information using Versioneer versioneer install --no-vendor # Versioneer wants a tag to set version # Make sure this is last in %%prep to avoid dev release git add --all git commit --allow-empty -m '[Fedora] Changes for RPM package' git tag v%{version} %generate_buildrequires %pyproject_buildrequires %build %pyproject_wheel %install %pyproject_install %pyproject_save_files -l %{pypi_name} %check # Exclude test requiring network k="${k-}${k+ and }not test_openneuro_retrieve" %pytest -r fEs ${k+-k }"${k-}" %files -n python3-%{pypi_name} -f %{pyproject_files} %doc README.rst AUTHORS %changelog ## START: Generated by rpmautospec * Fri Apr 18 2025 Sandro - 0.5.7-1 - Update to 0.5.7 * Wed Jan 10 2024 Sandro - 0.3.3-3 - Remove empty file (rpmlint error) * Wed Jan 10 2024 Sandro - 0.3.3-2 - Exclude scripts/ and tests/ from wheel * Wed Jan 10 2024 Sandro - 0.3.3-1 - Initial package ## END: Generated by rpmautospec