Update to latest and reduce SRPM size

This commit is contained in:
Major Hayden 2021-08-11 08:37:06 -05:00
commit 66b9eb2c24
No known key found for this signature in database
GPG key ID: 737051E0C1011FB1
3 changed files with 23 additions and 11 deletions

View file

@ -2,19 +2,24 @@
# continues to update it without bumping the version. 😞
%global srcname azure-devtools
%global forgeurl https://github.com/Azure/azure-sdk-for-python/
%global commit 19487ff9f1790033bcc9e3354b7bdee309a5bc71
%global commit a5a4ef4a7adc8c730dd7da2e9e3bdb43c9376586
%global shortcommit %(c=%{commit}; echo ${c:0:7})
%global distprefix %{nil}
%global short_version 1.2.1
%forgemeta
Name: python-%{srcname}
Version: %{short_version}~git.2.%{shortcommit}
Version: %{short_version}~git.3.%{shortcommit}
Release: 1%{?dist}
Summary: Microsoft Azure Development Tools for SDK
License: MIT and ASL 2.0
URL: %forgeurl
Source0: %forgesource
Source0: azure-devtools-%{commit}.tar.gz
# The azure-sdk-for-python repository is huge at > 160MB, but we only need ~
# 100KB of source for this package. Use this script to generate a tarball of the
# source code:
# ./generate-devtools-tarball.sh COMMIT_SHA
Source1: generate-devtools-tarball.sh
# Asked upstream to update the vcrpy requirement. PR in progress.
# https://github.com/Azure/azure-sdk-for-python/pull/20032
Patch0: python-azure-devtools-requirements-fix.patch
@ -44,14 +49,15 @@ Summary: %{summary}
%prep
%forgesetup
%patch0 -p0
%autosetup -v -p3 -c -n %{srcname}-%{commit}
%build
pushd tools/%{srcname}
%pyproject_wheel
popd
%pyproject_wheel
%generate_buildrequires
%pyproject_buildrequires -r
%install
@ -63,11 +69,15 @@ rm -f %{buildroot}%{_bindir}/{perfstress,systemperf}
%files -n python3-%{srcname} -f %{pyproject_files}
%doc tools/%{srcname}/README.rst
%license tools/%{srcname}/LICENSE
%doc README.rst
%license LICENSE
%changelog
* Tue Aug 03 2021 Major Hayden <major@mhtx.net> - 1.2.1~git.3.a5a4ef4
- Updated to latest commit on 2021-08-11
- Generate a source tarball using a script to shrink size of source RPM
* Tue Aug 03 2021 Major Hayden <major@mhtx.net> - 1.2.1~git.2.19487ff
- Updated to latest commit on 2021-08-03