Add defination to disable doc

This commit is contained in:
eabdullin 2022-07-06 13:42:31 +03:00
parent e6d61cb1eb
commit 8cf285017c
1 changed files with 14 additions and 2 deletions

View File

@ -1,6 +1,8 @@
%bcond_without doc
Name: pbuilder Name: pbuilder
Version: 0.231 Version: 0.231
Release: 4%{?dist} Release: 4%{?dist}.alma
Summary: Personal package builder for Debian packages Summary: Personal package builder for Debian packages
License: GPLv2+ License: GPLv2+
@ -42,7 +44,9 @@ dependencies.
%prep %prep
%autosetup -p1 %autosetup -p1
%if %{without doc}
sed -i 's|$(MAKE) -C Documentation $@||g' Makefile
%endif
# Adjust ccache path # Adjust ccache path
sed -i 's|/usr/lib/ccache|%{_libdir}/ccache|g' pbuilderrc sed -i 's|/usr/lib/ccache|%{_libdir}/ccache|g' pbuilderrc
@ -54,11 +58,13 @@ sed -i 's|/usr/lib/ccache|%{_libdir}/ccache|g' pbuilderrc
%install %install
%make_install %make_install
%if %{without doc}
# Man pages # Man pages
install -Dpm 0644 debuild-pbuilder.1 %{buildroot}%{_mandir}/man1/debuild-pbuilder.1 install -Dpm 0644 debuild-pbuilder.1 %{buildroot}%{_mandir}/man1/debuild-pbuilder.1
install -Dpm 0644 pdebuild.1 %{buildroot}%{_mandir}/man1/pdebuild.1 install -Dpm 0644 pdebuild.1 %{buildroot}%{_mandir}/man1/pdebuild.1
install -Dpm 0644 pbuilderrc.5 %{buildroot}%{_mandir}/man5/pbuilderrc.5 install -Dpm 0644 pbuilderrc.5 %{buildroot}%{_mandir}/man5/pbuilderrc.5
install -Dpm 0644 pbuilder.8 %{buildroot}%{_mandir}/man8/pbuilder.8 install -Dpm 0644 pbuilder.8 %{buildroot}%{_mandir}/man8/pbuilder.8
%endif
# Install directories # Install directories
install -d %{buildroot}%{_localstatedir}/cache/%{name} install -d %{buildroot}%{_localstatedir}/cache/%{name}
@ -97,16 +103,22 @@ make check
%{_prefix}/lib/pbuilder/ %{_prefix}/lib/pbuilder/
%{_datadir}/bash-completion/ %{_datadir}/bash-completion/
%{_datadir}/pbuilder/ %{_datadir}/pbuilder/
%if %{without doc}
%{_mandir}/man1/debuild-pbuilder.1* %{_mandir}/man1/debuild-pbuilder.1*
%{_mandir}/man1/pdebuild.1* %{_mandir}/man1/pdebuild.1*
%{_mandir}/man5/pbuilderrc.5* %{_mandir}/man5/pbuilderrc.5*
%{_mandir}/man8/pbuilder.8* %{_mandir}/man8/pbuilder.8*
%{_docdir}/pbuilder/ %{_docdir}/pbuilder/
%endif
# The ccache folder needs to be owned by the pbuilder user # The ccache folder needs to be owned by the pbuilder user
%attr(0755,%{name},root) %{_localstatedir}/cache/%{name}/ccache %attr(0755,%{name},root) %{_localstatedir}/cache/%{name}/ccache
%changelog %changelog
* Wed Jul 06 2022 Eduard Abdullin <eabdullin@almalinux.org> - 0.231-4.alma
- Use AlmaLinux patch
- Add defination to exclude docs
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.231-4 * Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.231-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild