make variable lifetime fix
authormirabilos <t.glaser@tarent.de>
Sun, 3 Dec 2017 00:12:55 +0000 (01:12 +0100)
committermirabilos <t.glaser@tarent.de>
Sun, 3 Dec 2017 00:12:55 +0000 (01:12 +0100)
debian/rules

index fd351d9..d0a7c74 100755 (executable)
@@ -117,12 +117,27 @@ EXTRA_CFLAGS+=            -Wextra -Wno-pointer-sign -Wno-unused-parameter \
                        -Wno-missing-prototypes -Wno-missing-declarations
 EXTRA_LDFLAGS=         -Wl,--as-needed
 
-# 5 is enough
 DEBHELPER_VERSION:=    9
 DSF:=                  3.0 (quilt)
 SUBST_EP:=             -e '/@PRIO@EXTRA@/d'
 HOMEPAGE:=             https://www.mirbsd.org/jupp.htm
 SUBST_HP:=             -e '/@HP@DOT@/d' -e '/@HP@OLD@/d' -e 's\ 1@HP@MODERN@\ 1${HOMEPAGE}\ 1'
+
+ifneq (,$(findstring lenny,${DEB_BUILD_OPTIONS}))
+DEBHELPER_VERSION:=    5
+endif
+ifneq (,$(findstring lenny,${DEB_BUILD_OPTIONS})$(findstring sarge,${DEB_BUILD_OPTIONS}))
+DSF:=                  1.0
+SUBST_EP:=             -e 's/@PRIO@EXTRA@/Priority: extra/'
+SELINUX_ARCHS:=                !kfreebsd-i386 !kfreebsd-amd64 !hurd-i386
+BREAKS:=               Conflicts
+endif
+ifneq (,$(findstring sarge,${DEB_BUILD_OPTIONS}))
+DEBHELPER_VERSION:=    4
+SUBST_HP:=             -e '/@HP@MODERN@/d' -e '/^VCS-[gB][ir][to][:w]/d' \
+                       -e 's/@HP@DOT@//' -e 's\ 1@HP@OLD@\ 1${HOMEPAGE}\ 1'
+endif
+
 DSC_DEPS:=             debhelper (>= ${DEBHELPER_VERSION})
 SUBST_VARS+=           DSC_DEPS
 
@@ -164,20 +179,6 @@ ifneq (,$(findstring debug,${DEB_BUILD_OPTIONS}))
 EXTRA_CFLAGS+=         -g3
 endif
 
-ifneq (,$(findstring lenny,${DEB_BUILD_OPTIONS})$(findstring sarge,${DEB_BUILD_OPTIONS}))
-DEBHELPER_VERSION:=    5
-DSF:=                  1.0
-SUBST_EP:=             -e 's/@PRIO@EXTRA@/Priority: extra/'
-SELINUX_ARCHS:=                !kfreebsd-i386 !kfreebsd-amd64 !hurd-i386
-BREAKS:=               Conflicts
-endif
-
-ifneq (,$(findstring sarge,${DEB_BUILD_OPTIONS}))
-DEBHELPER_VERSION:=    4
-SUBST_HP:=             -e '/@HP@MODERN@/d' -e '/^VCS-[gB][ir][to][:w]/d' \
-                       -e 's/@HP@DOT@//' -e 's\ 1@HP@OLD@\ 1${HOMEPAGE}\ 1'
-endif
-
 ifneq (,$(wildcard /usr/share/dpkg/buildflags.mk))
 # dpkg-dev (>= 1.16.1~)
 DEB_CFLAGS_MAINT_APPEND=${EXTRA_CFLAGS}