From c3b390629699257cc7aaedebcad419bd8c9c8bbf Mon Sep 17 00:00:00 2001 From: Kim Hagen Date: Tue, 22 Jul 2014 16:15:49 +0200 Subject: Only depend on grub if archtecture is i386 or amd64 --- debian/control | 4 ++-- debian/rules | 12 ++++++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/debian/control b/debian/control index c95af488..65989885 100644 --- a/debian/control +++ b/debian/control @@ -53,8 +53,8 @@ Depends: acpid, apt-transport-https, hostapd (>= 1:0.6.9-3), cpufrequtils, - grub-pc (>= 1.98+20100804), - libcap2-bin (>= 2.19) + libcap2-bin (>= 2.19), + ${arch:Depends} Pre-Depends: bash-completion Suggests: util-linux (>= 2.13-5), net-tools, diff --git a/debian/rules b/debian/rules index 0ae83713..96038c44 100755 --- a/debian/rules +++ b/debian/rules @@ -28,6 +28,14 @@ configure += --infodir=\$${prefix}/share/info configure += CFLAGS="$(CFLAGS)" configure += LDFLAGS="-Wl,-z,defs" +ifeq ($(shell dpkg --print-architecture),i386) + SUBSTVARS = -Varch:Depends="grub-pc (>= 1.98+20100804)" +endif + +ifeq ($(shell dpkg --print-architecture),amd64) + SUBSTVARS = -Varch:Depends="grub-pc (>= 1.98+20100804)" +endif + ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 else @@ -89,9 +97,9 @@ binary-indep: build install dh_fixperms dh_installdeb if [ -f "../.VYATTA_DEV_BUILD" ]; then \ - dh_gencontrol -- -v999.dev; \ + dh_gencontrol -- -v999.dev $(SUBSTVARS); \ else \ - dh_gencontrol; \ + dh_gencontrol $(SUBSTVARS); \ fi dh_md5sums dh_builddeb -- cgit v1.2.3