ff60e5a
# In order to use unversioned python macros in the spec file, we need to
5491181
# explicitly define %%__python.
5491181
%global __python %{_bindir}/python3
5491181
ff60e5a
%if %{defined el8}
ff60e5a
%global __python %{_libexecdir}/platform-python
ff60e5a
%endif
5491181
5491181
%if %{defined el7}
5491181
%global __python %{_bindir}/python
ff60e5a
%endif
ff60e5a
5491181
ff60e5a
Name:           centpkg
90e9eb7
Version:        0.6.6
220d6ce
Release:        3%{?dist}
ff60e5a
Summary:        CentOS utility for working with dist-git
ff60e5a
License:        GPLv2+
ff60e5a
URL:            https://git.centos.org/centos/centpkg
ff60e5a
Source0:        %{url}/archive/%{version}/centpkg-%{version}.tar.gz
220d6ce
# https://git.centos.org/centos/centpkg/issue/49
220d6ce
# https://git.centos.org/centos/centpkg/pull-request/50
220d6ce
Patch0:         0001-fix-headers-typo.patch
ff60e5a
BuildArch:      noarch
ff60e5a
ff60e5a
%if %{defined el7}
ff60e5a
BuildRequires:  python-devel
ff60e5a
BuildRequires:  python-setuptools
94a330c
BuildRequires:  python-six
94a330c
BuildRequires:  python-rpkg
ff60e5a
# The equivalent dependencies are added automatically everywhere except el7.
ff60e5a
Requires:       python-pycurl
ff60e5a
Requires:       pyOpenSSL
ff60e5a
Requires:       python-rpkg
ff60e5a
Requires:       python-six
ff60e5a
%else
ff60e5a
BuildRequires:  python3-devel
ff60e5a
BuildRequires:  python3-setuptools
94a330c
BuildRequires:  python3-six
94a330c
BuildRequires:  python3-rpkg
ff60e5a
%endif
ff60e5a
004b150
# /etc/koji.conf.d/stream.conf was previously part of streamkoji
004b150
Conflicts:      streamkoji < 1.1-3
004b150
ff60e5a
ff60e5a
%description
ff60e5a
Provides the centpkg command for working with dist-git.
ff60e5a
ff60e5a
ff60e5a
%package sig
ff60e5a
Summary:        CentOS SIG utility for working with dist-git
ff60e5a
Requires:       %{name} = %{version}-%{release}
ff60e5a
ff60e5a
ff60e5a
%description sig
ff60e5a
Provides the centpkg-sig command for working with dist-git.
ff60e5a
ff60e5a
ff60e5a
%prep
ab12219
%autosetup -p 1
ff60e5a
ff60e5a
ff60e5a
%build
ff60e5a
%py_build
94a330c
%{__python} doc/centpkg_man_page.py > centpkg.1
ff60e5a
ff60e5a
ff60e5a
%install
ff60e5a
%py_install
004b150
install -D -p -m 0644 src/stream.conf      %{buildroot}%{_sysconfdir}/koji.conf.d/stream.conf
ff60e5a
install -D -p -m 0644 src/centpkg.conf     %{buildroot}%{_sysconfdir}/rpkg/centpkg.conf
ff60e5a
install -D -p -m 0644 src/centpkg-sig.conf %{buildroot}%{_sysconfdir}/rpkg/centpkg-sig.conf
94a330c
install -D -p -m 0644 src/centpkg.bash     %{buildroot}%{_datadir}/bash-completion/completions/centpkg
94a330c
install -D -p -m 0644 centpkg.1            %{buildroot}%{_mandir}/man1/centpkg.1
ff60e5a
ff60e5a
ff60e5a
%files
ff60e5a
%license COPYING
ff60e5a
%doc README.md
004b150
%config(noreplace) %{_sysconfdir}/koji.conf.d/stream.conf
ff60e5a
%config(noreplace) %{_sysconfdir}/rpkg/centpkg.conf
ff60e5a
%{_bindir}/%{name}
ff60e5a
%{python_sitelib}/%{name}
ff60e5a
%{python_sitelib}/%{name}-%{version}-py%{python_version}.egg-info
94a330c
%{_datadir}/bash-completion/completions/centpkg
94a330c
%{_mandir}/man1/centpkg.1*
ff60e5a
ff60e5a
ff60e5a
%files sig
ff60e5a
%{_bindir}/%{name}-sig
ff60e5a
%config(noreplace) %{_sysconfdir}/rpkg/centpkg-sig.conf
ff60e5a
ff60e5a
ff60e5a
%changelog
220d6ce
* Wed Jul 21 2021 Carl George <carl@george.computer> - 0.6.6-3
220d6ce
- Backport upstream patch for "name 'header' is not defined" error
220d6ce
4d7b293
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.6-2
4d7b293
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
4d7b293
90e9eb7
* Tue Jun 08 2021 Mohan Boddu <mboddu@bhujji.com> - 0.6.6-1
90e9eb7
- Latest upstream
90e9eb7
dbb8862
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 0.6.5-2
dbb8862
- Rebuilt for Python 3.10
dbb8862
66e3837
* Tue May 25 2021 Carl George <carl@george.computer> - 0.6.5-1
66e3837
- Latest upstream
66e3837
6e1e249
* Wed Apr 28 2021 Carl George <carl@george.computer> - 0.6.4-1
6e1e249
- Latest upstream
6e1e249
457c7b8
* Fri Apr 16 2021 Carl George <carl@george.computer> - 0.6.3-1
457c7b8
- Latest upstream
457c7b8
004b150
* Tue Apr 13 2021 Carl George <carl@george.computer> - 0.6.2-1
004b150
- Latest upstream
004b150
- Add stream koji profile
004b150
94a330c
* Thu Apr 08 2021 Carl George <carl@george.computer> - 0.6.1-1
94a330c
- Latest upstream
94a330c
- Add bash completion support
94a330c
- Add manpage support
94a330c
ab12219
* Tue Mar 30 2021 Carl George <carl@george.computer> - 0.5.1-3
ab12219
- Fix epel7/python2 compatibility
ab12219
ff60e5a
* Thu Mar 25 2021 Carl George <carl@george.computer> - 0.5.1-2
ff60e5a
- Add missing el7 requirements
ff60e5a
ff60e5a
* Thu Mar 25 2021 Carl George <carl@george.computer> - 0.5.1-1
ff60e5a
- Latest version
ff60e5a
ff60e5a
* Thu Feb 25 2021 mkonecny@redhat.com 0.5.0-1
ff60e5a
- Add centpkg-sig command
ff60e5a
ff60e5a
* Mon Nov 28 2016 brian@bstinson.com 0.4.6-1
ff60e5a
- Tracking updates to rpkg (thanks pavlix)
ff60e5a
- Fix the URL building code in the sources method
ff60e5a
ff60e5a
* Sat Jan 31 2015 Brian Stinson bstinson@ksu.edu - 0.4.4-1
ff60e5a
- New version correcting the anonymous pull URLs
ff60e5a
ff60e5a
* Sun Dec 14 2014 Brian Stinson bstinson@ksu.edu - 0.4.3-1
ff60e5a
- Use the authenticated git url for centpkg pulls
ff60e5a
ff60e5a
* Sun Dec 14 2014 Brian Stinson bstinson@ksu.edu - 0.4.2-1
ff60e5a
- Fix the koji config path in centpkg.conf
ff60e5a
ff60e5a
* Sun Dec 14 2014 Brian Stinson bstinson@ksu.edu - 0.4.1-1
ff60e5a
- Fix a disttag regression and add a "patch" version number
ff60e5a
ff60e5a
* Sat Nov 23 2014 Brian Stinson bstinson@ksu.edu - 0.2-1
ff60e5a
- The srpm workflow to the CBS works now
ff60e5a
ff60e5a
* Sat Jul 05 2014 Brian Stinson bstinson@ksu.edu - 0.1-2
ff60e5a
- Update readme and add exception checking when running toplevel commands
ff60e5a
ff60e5a
* Sat Jul 05 2014 Brian Stinson bstinson@ksu.edu - 0.1-1
ff60e5a
- Local builds and mockbuilds work