summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authorVagrant Cascadian <vagrant@reproducible-builds.org>2022-04-17 22:11:12 +0000
committerDavid Kalnischkies <david@kalnischkies.de>2022-05-07 10:45:44 +0200
commit725fef5ebf45d03fea75866e9795717bf576d26a (patch)
tree4bef451e63e985d486c7e83d814a415af6c36312 /debian
parente6cefc7683de4f29be7ebcab004ea0ab80ce49bc (diff)
Add support for "nodoc" build profile
References: https://wiki.debian.org/BuildProfileSpec#Registered_profile_names Closes: #1009797 [@donkult: reworded commit message slightly & changed variable name]
Diffstat (limited to 'debian')
-rw-r--r--debian/control4
-rwxr-xr-xdebian/rules12
2 files changed, 12 insertions, 4 deletions
diff --git a/debian/control b/debian/control
index 2f1d0515e..7f10eec3e 100644
--- a/debian/control
+++ b/debian/control
@@ -31,7 +31,7 @@ Build-Depends: cmake (>= 3.4),
triehash,
xsltproc,
zlib1g-dev
-Build-Depends-Indep: doxygen, graphviz, w3m
+Build-Depends-Indep: doxygen <!nodoc>, graphviz <!nodoc>, w3m <!nodoc>
Vcs-Git: https://salsa.debian.org/apt-team/apt.git
Vcs-Browser: https://salsa.debian.org/apt-team/apt
@@ -101,6 +101,7 @@ Priority: optional
Depends: ${misc:Depends}
Section: doc
Multi-Arch: foreign
+Build-Profiles: <!nodoc>
Description: documentation for APT
This package contains the user guide and offline guide for various
APT tools which are provided in a html and a text-only version.
@@ -125,6 +126,7 @@ Priority: optional
Depends: ${misc:Depends}
Section: doc
Multi-Arch: foreign
+Build-Profiles: <!nodoc>
Description: documentation for APT development
This package contains documentation for development of the APT
Debian package manipulation program and its libraries.
diff --git a/debian/rules b/debian/rules
index 202f1b86d..502840080 100755
--- a/debian/rules
+++ b/debian/rules
@@ -17,6 +17,12 @@ else
configure_test_flags =
endif
+ifeq ($(filter nodoc,$(DEB_BUILD_PROFILES)),)
+ profile_doc_flags=-DWITH_DOC=ON
+else
+ profile_doc_flags=-DWITH_DOC=OFF
+endif
+
%:
dh $@ --buildsystem=cmake+ninja
@@ -44,7 +50,7 @@ override_dh_installsystemd:
dh_installsystemd -papt --no-restart-on-upgrade --no-restart-after-upgrade --no-start apt-daily.service apt-daily-upgrade.service
dh_installsystemd --remaining-packages
-override_dh_auto_configure-arch: flags=-DWITH_DOC=OFF
-override_dh_auto_configure-indep: flags=-DWITH_DOC=ON
+override_dh_auto_configure-arch: configure_doc_flags=-DWITH_DOC=OFF
+override_dh_auto_configure-indep: configure_doc_flags=$(profile_doc_flags)
override_dh_auto_configure-arch override_dh_auto_configure-indep:
- dh_auto_configure -- -DCMAKE_BUILD_RPATH_USE_ORIGIN=ON $(flags) $(configure_test_flags)
+ dh_auto_configure -- -DCMAKE_BUILD_RPATH_USE_ORIGIN=ON $(configure_doc_flags) $(configure_test_flags)