Mageia Bugzilla – Attachment 14378 Details for
Bug 32839
git-buildpackage : helps to build rpms from git source NEW PKG REQUEST
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
Proposal spec file
git-buildpackage.spec (text/x-matlab), 6.40 KB, created by
Kristoffer Grundström
on 2024-02-13 18:03:08 CET
(
hide
)
Description:
Proposal spec file
Filename:
MIME Type:
Creator:
Kristoffer Grundström
Created:
2024-02-13 18:03:08 CET
Size:
6.40 KB
patch
obsolete
>%bcond_without docs >%define dpkg_pkg_name dpkg-devel >%define dpkg_pkg_name dpkg >%define man_pkg_name man-db >%define python_pkg_name python3-base >%define rpm_python_pkg_name python3-rpm >%define _zipmerge libzip >%define _zipmerge /usr/bin/zipmerge >%define python_pkg_name python >%define python_pkg_name python3 > >Name: git-buildpackage >Summary: Build packages from git >License: GPL-2.0-only >Group: Development/Tools >Version: 0.9.23 >Release: 1%{?dist} >BuildArch: noarch >URL: https://honk.sigxcpu.org/piki/projects/git-buildpackage/ >Source0: %{name}-%{version}.tar.gz >BuildRequires: %{dpkg_pkg_name} >Requires: %{dpkg_pkg_name} >Requires: %{name}-common = %{version}-%{release} >Requires: dchroot >BuildRequires: python3 >BuildRequires: python3-setuptools > >%if %{with docs} >BuildRequires: docbook2x >BuildRequires: libxslt1 >BuildRequires: gtk-doc >BuildRequires: perl-podlators >%endif > >%if 0%{?do_unittests} >BuildRequires: pkgconfig(libzip) >BuildRequires: %{dpkg_pkg_name} >BuildRequires: %{man_pkg_name} >BuildRequires: %{rpm_python_pkg_name} >BuildRequires: dchroot >BuildRequires: git-core >BuildRequires: gnupg >BuildRequires: perl-TimeDate >BuildRequires: python3-coverage >BuildRequires: python3-mock >BuildRequires: python3-nose >BuildRequires: rpm-build >BuildRequires: unzip >#BuildRequires: pristine-tar >%endif > >%description >Set of tools from Debian that integrate the package build system with Git. >This package contains the original Debian tools. > >%package common >Summary: Common files for git-buildpackage debian and rpm tools >Group: Development/Tools >Requires: %{man_pkg_name} >Requires: %{python_pkg_name} >Requires: git-core >Requires: python3-dateutil >Requires: python3-setuptools >Requires: pkgconfig(libzip) >Requires: unzip > >%description common >Common files and documentation, used by both git-buildpackage debian and rpm tools > >%package rpm >Summary: Build RPM packages from git >Group: Development/Tools >Requires: %{name}-common = %{version}-%{release} >Requires: %{rpm_python_pkg_name} >Requires: rpm >Requires: rpm-build >Recommends: rpm-build > >%description rpm >Set of tools from Debian that integrate the package build system with Git. >This package contains the tools for building RPM packages. > >%if %{with docs} >%package doc >Summary: Documentation for the git-buildpackage suite >Group: Development/Tools > >%description doc >This package contains documentation for the git-buildpackage suite - both the >Debian and the RPM tool set. >%endif > >%prep >%setup -q -n %{name}-%{version} > >%build >%py3_build > >%if %{with docs} ># HTML docs >HAVE_SGML2X=0 make -C docs/ >%endif > >%if 0%{?do_unittests} >%check >GIT_CEILING_DIRECTORIES=%{_builddir} \ > GIT_AUTHOR_EMAIL=rpmbuild@example.com GIT_AUTHOR_NAME=rpmbuild \ > GIT_COMMITTER_NAME=$GIT_AUTHOR_NAME GIT_COMMITTER_EMAIL=$GIT_AUTHOR_EMAIL \ > %py3_check nosetests >%endif > >%install >%py3_install >find %{buildroot} -name __pycache__ | xargs rm -r >mkdir -p %{buildroot}/usr/share/%{name} >mv %{buildroot}/usr/bin/gbp-builder-mock %{buildroot}/usr/share/%{name}/ >mkdir -p %{buildroot}/%{_sysconfdir}/git-buildpackage/ >mv %{buildroot}/usr/share/%{name}/gbp.conf %{buildroot}/%{_sysconfdir}/git-buildpackage/ > >%if %{with docs} ># Install man pages >install -d %{buildroot}%{_mandir}/man1 %{buildroot}%{_mandir}/man5 >install docs/*.1 %{buildroot}%{_mandir}/man1/ >install docs/*.5 %{buildroot}%{_mandir}/man5/ > ># Install html documentation >mkdir -p %{buildroot}%{_docdir}/%{name} >cp -r docs/manual-html %{buildroot}%{_docdir}/%{name} > ># fix perms >chmod -x %{buildroot}%{_mandir}/man1/*.1 >chmod -x %{buildroot}%{_mandir}/man5/*.5 >chmod -x %{buildroot}%{_docdir}/%{name}/manual-html/images/*.png > >%endif > >cat > files.list << EOF >%{_bindir}/git-pbuilder >%{python3_sitelib}/gbp/deb >%{python3_sitelib}/gbp/scripts/pq.py* >%{python3_sitelib}/gbp/scripts/buildpackage.py* >%{python3_sitelib}/gbp/scripts/dch.py* >%{python3_sitelib}/gbp/scripts/export_orig.py* >%{python3_sitelib}/gbp/scripts/import_ref.py* >%{python3_sitelib}/gbp/scripts/import_dsc.py* >%{python3_sitelib}/gbp/scripts/import_dscs.py* >%{python3_sitelib}/gbp/scripts/import_orig.py* >%{python3_sitelib}/gbp/scripts/create_remote_repo.py* >%{python3_sitelib}/gbp/scripts/setup_gitattributes.py* ># %%{python3_sitelib}/gbp/scripts/export_ref.py* >EOF > >%if %{with docs} >cat >> files.list << EOF >%{_mandir}/man1/gbp-buildpackage.1* >%{_mandir}/man1/gbp-create-remote-repo.1* >%{_mandir}/man1/gbp-dch.1* >%{_mandir}/man1/gbp-export-orig.1* >%{_mandir}/man1/gbp-import-dsc.1* >%{_mandir}/man1/gbp-import-dscs.1* >%{_mandir}/man1/gbp-import-orig.1* >%{_mandir}/man1/gbp-import-ref.1* >%{_mandir}/man1/gbp-pq.1* >%{_mandir}/man1/git-pbuilder.1* >%{_mandir}/man1/gbp-setup-gitattributes.1* >EOF >%endif > ># Disable the Debian tools for old CentOS >%if 0%{?centos_ver} && 0%{?centos_ver} < 7 >for f in `cat files.list`; do > rm -rfv %{buildroot}/$f >done > >%else >%files -f files.list >%defattr(-,root,root,-) >%endif > >%files common >%{_bindir}/gbp >%dir %{python3_sitelib}/gbp >%dir %{python3_sitelib}/gbp/git >%dir %{python3_sitelib}/gbp/pkg >%dir %{python3_sitelib}/gbp/scripts >%dir %{python3_sitelib}/gbp/scripts/common >%dir /usr/share/git-buildpackage >%{python3_sitelib}/gbp-* >%{python3_sitelib}/gbp/*.py* >%{python3_sitelib}/gbp/scripts/__init__.py* >%{python3_sitelib}/gbp/scripts/clone.py* >%{python3_sitelib}/gbp/scripts/config.py* >%{python3_sitelib}/gbp/scripts/pristine_tar.py* >%{python3_sitelib}/gbp/scripts/pull.py* >%{python3_sitelib}/gbp/scripts/push.py* >%{python3_sitelib}/gbp/scripts/supercommand.py* >%{python3_sitelib}/gbp/scripts/tag.py* >%{python3_sitelib}/gbp/scripts/common/*.py* >%{python3_sitelib}/gbp/git/*.py* >%{python3_sitelib}/gbp/pkg/*.py* >%config %{_sysconfdir}/git-buildpackage > >%if 0%{?mageia} >%{python3_sitelib}/gbp/__pycache__/*.pyc >%{python3_sitelib}/gbp/scripts/__pycache__/*.pyc >%{python3_sitelib}/gbp/scripts/common/__pycache__/*.pyc >%{python3_sitelib}/gbp/pkg/__pycache__/*.pyc >%{python3_sitelib}/gbp/git/__pycache__/*.pyc >%endif > >%if %{with docs} >%{_mandir}/man1/gbp.1* >%{_mandir}/man1/gbp-clone.1* >%{_mandir}/man1/gbp-config.1* >%{_mandir}/man1/gbp-pristine-tar.1* >%{_mandir}/man1/gbp-pull.1* >%{_mandir}/man1/gbp-push.1* >%{_mandir}/man1/gbp-tag.1* >%{_mandir}/man5/*.5* >%endif > >%files rpm >%dir %{python3_sitelib}/gbp/rpm >%{python3_sitelib}/gbp/scripts/*rpm*.py* >%{python3_sitelib}/gbp/rpm/*py* >/usr/share/git-buildpackage/gbp-builder-mock >%if %{with docs} >%{_mandir}/man1/gbp-buildpackage-rpm.1* >%{_mandir}/man1/gbp-pq-rpm.1* >%{_mandir}/man1/gbp-import-srpm.1* >%{_mandir}/man1/gbp-rpm-ch.1* >%endif > >%if %{with docs} >%files doc >%{_docdir}/%{name}/ >%endif
%bcond_without docs %define dpkg_pkg_name dpkg-devel %define dpkg_pkg_name dpkg %define man_pkg_name man-db %define python_pkg_name python3-base %define rpm_python_pkg_name python3-rpm %define _zipmerge libzip %define _zipmerge /usr/bin/zipmerge %define python_pkg_name python %define python_pkg_name python3 Name: git-buildpackage Summary: Build packages from git License: GPL-2.0-only Group: Development/Tools Version: 0.9.23 Release: 1%{?dist} BuildArch: noarch URL: https://honk.sigxcpu.org/piki/projects/git-buildpackage/ Source0: %{name}-%{version}.tar.gz BuildRequires: %{dpkg_pkg_name} Requires: %{dpkg_pkg_name} Requires: %{name}-common = %{version}-%{release} Requires: dchroot BuildRequires: python3 BuildRequires: python3-setuptools %if %{with docs} BuildRequires: docbook2x BuildRequires: libxslt1 BuildRequires: gtk-doc BuildRequires: perl-podlators %endif %if 0%{?do_unittests} BuildRequires: pkgconfig(libzip) BuildRequires: %{dpkg_pkg_name} BuildRequires: %{man_pkg_name} BuildRequires: %{rpm_python_pkg_name} BuildRequires: dchroot BuildRequires: git-core BuildRequires: gnupg BuildRequires: perl-TimeDate BuildRequires: python3-coverage BuildRequires: python3-mock BuildRequires: python3-nose BuildRequires: rpm-build BuildRequires: unzip #BuildRequires: pristine-tar %endif %description Set of tools from Debian that integrate the package build system with Git. This package contains the original Debian tools. %package common Summary: Common files for git-buildpackage debian and rpm tools Group: Development/Tools Requires: %{man_pkg_name} Requires: %{python_pkg_name} Requires: git-core Requires: python3-dateutil Requires: python3-setuptools Requires: pkgconfig(libzip) Requires: unzip %description common Common files and documentation, used by both git-buildpackage debian and rpm tools %package rpm Summary: Build RPM packages from git Group: Development/Tools Requires: %{name}-common = %{version}-%{release} Requires: %{rpm_python_pkg_name} Requires: rpm Requires: rpm-build Recommends: rpm-build %description rpm Set of tools from Debian that integrate the package build system with Git. This package contains the tools for building RPM packages. %if %{with docs} %package doc Summary: Documentation for the git-buildpackage suite Group: Development/Tools %description doc This package contains documentation for the git-buildpackage suite - both the Debian and the RPM tool set. %endif %prep %setup -q -n %{name}-%{version} %build %py3_build %if %{with docs} # HTML docs HAVE_SGML2X=0 make -C docs/ %endif %if 0%{?do_unittests} %check GIT_CEILING_DIRECTORIES=%{_builddir} \ GIT_AUTHOR_EMAIL=rpmbuild@example.com GIT_AUTHOR_NAME=rpmbuild \ GIT_COMMITTER_NAME=$GIT_AUTHOR_NAME GIT_COMMITTER_EMAIL=$GIT_AUTHOR_EMAIL \ %py3_check nosetests %endif %install %py3_install find %{buildroot} -name __pycache__ | xargs rm -r mkdir -p %{buildroot}/usr/share/%{name} mv %{buildroot}/usr/bin/gbp-builder-mock %{buildroot}/usr/share/%{name}/ mkdir -p %{buildroot}/%{_sysconfdir}/git-buildpackage/ mv %{buildroot}/usr/share/%{name}/gbp.conf %{buildroot}/%{_sysconfdir}/git-buildpackage/ %if %{with docs} # Install man pages install -d %{buildroot}%{_mandir}/man1 %{buildroot}%{_mandir}/man5 install docs/*.1 %{buildroot}%{_mandir}/man1/ install docs/*.5 %{buildroot}%{_mandir}/man5/ # Install html documentation mkdir -p %{buildroot}%{_docdir}/%{name} cp -r docs/manual-html %{buildroot}%{_docdir}/%{name} # fix perms chmod -x %{buildroot}%{_mandir}/man1/*.1 chmod -x %{buildroot}%{_mandir}/man5/*.5 chmod -x %{buildroot}%{_docdir}/%{name}/manual-html/images/*.png %endif cat > files.list << EOF %{_bindir}/git-pbuilder %{python3_sitelib}/gbp/deb %{python3_sitelib}/gbp/scripts/pq.py* %{python3_sitelib}/gbp/scripts/buildpackage.py* %{python3_sitelib}/gbp/scripts/dch.py* %{python3_sitelib}/gbp/scripts/export_orig.py* %{python3_sitelib}/gbp/scripts/import_ref.py* %{python3_sitelib}/gbp/scripts/import_dsc.py* %{python3_sitelib}/gbp/scripts/import_dscs.py* %{python3_sitelib}/gbp/scripts/import_orig.py* %{python3_sitelib}/gbp/scripts/create_remote_repo.py* %{python3_sitelib}/gbp/scripts/setup_gitattributes.py* # %%{python3_sitelib}/gbp/scripts/export_ref.py* EOF %if %{with docs} cat >> files.list << EOF %{_mandir}/man1/gbp-buildpackage.1* %{_mandir}/man1/gbp-create-remote-repo.1* %{_mandir}/man1/gbp-dch.1* %{_mandir}/man1/gbp-export-orig.1* %{_mandir}/man1/gbp-import-dsc.1* %{_mandir}/man1/gbp-import-dscs.1* %{_mandir}/man1/gbp-import-orig.1* %{_mandir}/man1/gbp-import-ref.1* %{_mandir}/man1/gbp-pq.1* %{_mandir}/man1/git-pbuilder.1* %{_mandir}/man1/gbp-setup-gitattributes.1* EOF %endif # Disable the Debian tools for old CentOS %if 0%{?centos_ver} && 0%{?centos_ver} < 7 for f in `cat files.list`; do rm -rfv %{buildroot}/$f done %else %files -f files.list %defattr(-,root,root,-) %endif %files common %{_bindir}/gbp %dir %{python3_sitelib}/gbp %dir %{python3_sitelib}/gbp/git %dir %{python3_sitelib}/gbp/pkg %dir %{python3_sitelib}/gbp/scripts %dir %{python3_sitelib}/gbp/scripts/common %dir /usr/share/git-buildpackage %{python3_sitelib}/gbp-* %{python3_sitelib}/gbp/*.py* %{python3_sitelib}/gbp/scripts/__init__.py* %{python3_sitelib}/gbp/scripts/clone.py* %{python3_sitelib}/gbp/scripts/config.py* %{python3_sitelib}/gbp/scripts/pristine_tar.py* %{python3_sitelib}/gbp/scripts/pull.py* %{python3_sitelib}/gbp/scripts/push.py* %{python3_sitelib}/gbp/scripts/supercommand.py* %{python3_sitelib}/gbp/scripts/tag.py* %{python3_sitelib}/gbp/scripts/common/*.py* %{python3_sitelib}/gbp/git/*.py* %{python3_sitelib}/gbp/pkg/*.py* %config %{_sysconfdir}/git-buildpackage %if 0%{?mageia} %{python3_sitelib}/gbp/__pycache__/*.pyc %{python3_sitelib}/gbp/scripts/__pycache__/*.pyc %{python3_sitelib}/gbp/scripts/common/__pycache__/*.pyc %{python3_sitelib}/gbp/pkg/__pycache__/*.pyc %{python3_sitelib}/gbp/git/__pycache__/*.pyc %endif %if %{with docs} %{_mandir}/man1/gbp.1* %{_mandir}/man1/gbp-clone.1* %{_mandir}/man1/gbp-config.1* %{_mandir}/man1/gbp-pristine-tar.1* %{_mandir}/man1/gbp-pull.1* %{_mandir}/man1/gbp-push.1* %{_mandir}/man1/gbp-tag.1* %{_mandir}/man5/*.5* %endif %files rpm %dir %{python3_sitelib}/gbp/rpm %{python3_sitelib}/gbp/scripts/*rpm*.py* %{python3_sitelib}/gbp/rpm/*py* /usr/share/git-buildpackage/gbp-builder-mock %if %{with docs} %{_mandir}/man1/gbp-buildpackage-rpm.1* %{_mandir}/man1/gbp-pq-rpm.1* %{_mandir}/man1/gbp-import-srpm.1* %{_mandir}/man1/gbp-rpm-ch.1* %endif %if %{with docs} %files doc %{_docdir}/%{name}/ %endif
View Attachment As Raw
Actions:
View
Attachments on
bug 32839
: 14378