shorewall_code/Shorewall-shell/debian/rules
el_cubano 60beb2f1d2 Add Debian files
git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@7501 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
2007-10-22 13:35:14 +00:00

69 lines
1.6 KiB
Makefile
Executable File

#!/usr/bin/make -f
#
# Shorewall firewall (http://www.shorewall.net)
# debianized version
# Include dpatch stuff.
include /usr/share/dpatch/dpatch.make
# shorewall version
export V=`cat install.sh | grep "^VERSION=" | head -n 1 | cut -f 2 -d "="`
VMAJOR:=$(shell echo $(V) |cut -f 1 -d .)
VMINOR:=$(shell echo $(V) |cut -f 2 -d .)
VPATCH:=$(shell echo $(V) |cut -f 3 -d .)
NEXTPATCH:=$(shell expr $(VPATCH) + 1)
SRWL=$(CURDIR)/debian/shorewall-shell
build: patch build-stamp
build-stamp:
dh_testdir
# there's nothing to compile ;-)
touch build-stamp
clean: clean-patched unpatch
clean-patched:
dh_testdir
dh_testroot
rm -f build-stamp
rm -f debian/shorewall-shell.substvars
# clean the build directory
rm -rf $(SRWL)
dh_clean
install: build
dh_testdir
dh_testroot
dh_clean -k
dh_installdirs
echo 'shorewall:next=$(VMAJOR).$(VMINOR).$(NEXTPATCH)~' \
> debian/shorewall-shell.substvars
dh_install
install -m 644 debian/shorewall-shell.lintian $(SRWL)/usr/share/lintian/overrides/shorewall-shell
# set version number
echo $V > $(SRWL)/usr/share/shorewall-shell/version
# global configuration has to be fully readable
chmod 644 $(SRWL)/usr/share/shorewall-shell/*
# must be executable
chmod 755 $(SRWL)/usr/share/shorewall-shell/compiler
binary-indep: build install
dh_testdir
dh_testroot
dh_installdocs releasenotes.txt
dh_installchangelogs changelog.txt
dh_compress
dh_fixperms
dh_installdeb
dh_gencontrol
dh_md5sums
dh_builddeb -v
binary-arch: build install
binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install patch unpatch \
clean-patched