[xenial/master-next,3/3] UBUNTU: [Packaging] prevent linux-*-tools-common from being produced from non linux packages
diff mbox

Message ID 20170509175209.20241-7-apw@canonical.com
State New
Headers show

Commit Message

Andy Whitcroft May 9, 2017, 5:52 p.m. UTC
BugLink: http://bugs.launchpad.net/bugs/1688579
Signed-off-by: Andy Whitcroft <apw@canonical.com>
---
 debian/rules.d/3-binary-indep.mk | 8 ++++++++
 1 file changed, 8 insertions(+)

Patch
diff mbox

diff --git a/debian/rules.d/3-binary-indep.mk b/debian/rules.d/3-binary-indep.mk
index 32bc90cc1d71..e4884208cc71 100644
--- a/debian/rules.d/3-binary-indep.mk
+++ b/debian/rules.d/3-binary-indep.mk
@@ -94,6 +94,10 @@  install-tools: install-source $(stampdir)/stamp-build-perarch
 	@echo Debug: $@
 
 ifeq ($(do_tools_common),true)
+ifneq ($(DEBIAN),debian.master)
+	echo "non-master branch building linux-tools-common, aborting"
+	exit 1
+endif
 	rm -rf $(builddir)/tools
 	install -d $(builddir)/tools
 	for i in *; do $(LN) $(CURDIR)/$$i $(builddir)/tools/; done
@@ -162,6 +166,10 @@  binary-indep: install-indep
 	dh_compress -i
 	dh_fixperms -i
 ifeq ($(do_tools_common),true)
+ifneq ($(DEBIAN),debian.master)
+	echo "non-master branch building linux-cloud-tools-common, aborting"
+	exit 1
+endif
 	dh_installinit -p$(cloudpkg) -n --name hv-kvp-daemon
 	dh_installinit -p$(cloudpkg) -n --name hv-vss-daemon
 	dh_installinit -p$(cloudpkg) -n --name hv-fcopy-daemon