summaryrefslogtreecommitdiff
path: root/packaging/git-buildpackage.spec
diff options
context:
space:
mode:
Diffstat (limited to 'packaging/git-buildpackage.spec')
-rw-r--r--packaging/git-buildpackage.spec20
1 files changed, 17 insertions, 3 deletions
diff --git a/packaging/git-buildpackage.spec b/packaging/git-buildpackage.spec
index ec019bc4..7ac503f3 100644
--- a/packaging/git-buildpackage.spec
+++ b/packaging/git-buildpackage.spec
@@ -171,9 +171,7 @@ cp -r docs/manual-html %{buildroot}%{_docdir}/%{name}
cp -r docs/apidocs %{buildroot}%{_docdir}/%{name}
%endif
-
-%files
-%defattr(-,root,root,-)
+cat > files.list << EOF
%{_bindir}/gbp-pq
%{_bindir}/git-buildpackage
%{_bindir}/git-dch
@@ -190,7 +188,10 @@ cp -r docs/apidocs %{buildroot}%{_docdir}/%{name}
%{python_sitelib}/gbp/scripts/import_dscs.py*
%{python_sitelib}/gbp/scripts/import_orig.py*
%{python_sitelib}/gbp/scripts/create_remote_repo.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*
@@ -199,6 +200,19 @@ cp -r docs/apidocs %{buildroot}%{_docdir}/%{name}
%{_mandir}/man1/gbp-import-orig.1*
%{_mandir}/man1/gbp-pq.1*
%{_mandir}/man1/git-pbuilder.1*
+EOF
+%endif
+
+# Disable the debian tools for CentOS
+%if 0%{?centos_version}
+for f in `cat files.list`; do
+ rm -rfv %{buildroot}/$f
+done
+
+%else
+
+%files -f files.list
+%defattr(-,root,root,-)
%endif
%files common