From: Luca Boccassi Date: Mon, 12 Jun 2017 12:54:44 +0000 (+0100) Subject: Hide dbgsym metapackage behind DEB_BUILD_OPTIONS X-Git-Url: https://gerrit.fd.io/r/gitweb?p=deb_dpdk.git;a=commitdiff_plain;h=864973804fe71a7a00292fdb15777cddf87716ca Hide dbgsym metapackage behind DEB_BUILD_OPTIONS dbgsym packages go in the -debug section of the archive, and various DDs and FTP Masters have strongly recommended to avoid uploading any such metapackage to Main for this reason. It can be still very useful for users and rebuilders, so leave it disabled behind a dbgsym_meta DEB_BUILD_OPTIONS flag. Change-Id: I112f3195755cc6bafef3167b39d3d47273572377 Signed-off-by: Luca Boccassi --- diff --git a/debian/rules b/debian/rules index bd5ec0b5..33b98b5a 100755 --- a/debian/rules +++ b/debian/rules @@ -113,17 +113,6 @@ DPDK_CONFIG_BUILD_KMOD=y # dpkg-genchanges, and also would require a lot of overrides for debhelpers. get_built_using ?= $(filter-out (=),$(shell dpkg-query -f='$${source:Package} (=$${source:Version})' -W $1)) -override_dh_gencontrol: - dh_gencontrol - dh_gencontrol -p dpdk-modules-$(KVERS) -- \ - -v`cat debian/VERSION` \ - -V'built:using:kernel=$(call get_built_using,linux-headers-$(KVERS))' - ./debian/dh-dbgsym-metapkg libdpdk$(DPDK_ABI)-dbgsym - -override_dh_builddeb: - dh_builddeb - dh_builddeb -plibdpdk$(DPDK_ABI)-dbgsym - build: @if [ x"$(KVERS)" = x ] ; then \ echo 'No version in $(KSRC)/include/linux/version.h' >&2; \ @@ -137,6 +126,29 @@ endif %: dh $@ --with python2,dkms +override_dh_gencontrol: + dh_gencontrol +ifneq (,$(findstring kernel_modules,$(DEB_BUILD_OPTIONS))) + dh_gencontrol -p dpdk-modules-$(KVERS) -- \ + -v`cat debian/VERSION` \ + -V'built:using:kernel=$(call get_built_using,linux-headers-$(KVERS))' +endif +ifneq (,$(findstring dbgsym_meta,$(DEB_BUILD_OPTIONS))) + ./debian/dh-dbgsym-metapkg libdpdk$(DPDK_ABI)-dbgsym +endif + +# dbgsym_meta can be passed via DEB_BUILD_OPTIONS to enable building the +# optional dbgsym meta package libdpdk-dbgsym. +# This is not built by default as it would go in main but depend on +# packages in the debian-debug archive. +# Debian Developers and FTP masters strongly discourage this. +# We provide this optional flag as a convenience for rebuilders. +ifneq (,$(findstring dbgsym_meta,$(DEB_BUILD_OPTIONS))) +override_dh_builddeb: + dh_builddeb + dh_builddeb -plibdpdk$(DPDK_ABI)-dbgsym +endif + override_dh_auto_clean: rm -rf debian/build debian/tmp debian/dpdk-modules-* \ debian/control.modules debian/VERSION