1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114
|
#!/usr/bin/make -f
# Sample debian/rules that uses debhelper.
# This file is public domain software, originally written by Joey Hess.
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
# This is the debhelper compatability version to use.
export DH_COMPAT=3
dtmp=debian/trn4
configure: configure-stamp
configure-stamp:
dh_testdir
cp debian/Policy.sh .
ifeq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
./Configure -Oders -Doptimize='-O2 -Wall' -Dccflags=-DDEBUG
else
# Configure adds -DDEBUG for us when we use -g.
./Configure -Oders -Doptimize='-O2 -g -Wall'
endif
touch configure-stamp
build: configure-stamp build-stamp
build-stamp:
dh_testdir
$(MAKE)
touch build-stamp
clean:
dh_testdir
dh_testroot
-rm -f build-stamp configure-stamp
-$(MAKE) -i spotless
dh_clean
install: build
dh_testdir
dh_testroot
dh_clean -k
dh_installdirs
# Do the install ourselves, as we use a slightly different directory
# layout to what 'make install' wants, and we may not want to strip
# binaries.
# Binaries.
install -p trn trn-artchk nntplist Pnews Rnmail $(dtmp)/usr/lib/trn4
install -p inews $(dtmp)/usr/lib/trn4
# Other executables.
install -p Speller filexp makedir mbox.saver norm.saver \
$(dtmp)/usr/share/trn4
# Configuration files and similar.
install -p -m 0644 INIT access.def $(dtmp)/etc/trn4
install -p -m 0644 Pnews.header newsnews $(dtmp)/usr/share/trn4
# Group-scanning configuration files.
install -p -m 0644 default_topic $(dtmp)/etc/trn4/trn4top
install -p -m 0644 samples/univ/hier_groups $(dtmp)/etc/trn4
# Documentation.
cp -pR HelpFiles $(dtmp)/usr/share/trn4
install -p -m 0644 support/filter.README support/unipatch.c \
$(dtmp)/usr/share/doc/trn4/support
install -p support/Score.pl support/filter support/mhactive \
support/trnkill \
$(dtmp)/usr/share/doc/trn4/support
# Man pages.
install -p -m 0644 trn.1 $(dtmp)/usr/share/man/man1/trn4.1
for x in Pnews Rnmail strn; do \
install -p -m 0644 $$x.1 \
$(dtmp)/usr/share/man/man1/trn4-$$x.1; \
done
for x in nntplist trn-artchk; do \
install -p -m 0644 debian/$$x.1 \
$(dtmp)/usr/share/man/man1/trn4-$$x.1; \
done
# Build architecture-independent files here.
binary-indep:
# We have nothing to do by default.
# Build architecture-dependent files here.
binary-arch: build install
dh_testdir
dh_testroot
dh_installdebconf
dh_installdocs
mv $(dtmp)/usr/share/doc/trn4/changelog $(dtmp)/usr/share/doc/trn4/NEWS
dh_installexamples
dh_installmenu
dh_installchangelogs debian/changelog.upstream
dh_link
dh_strip
dh_compress -X examples
dh_fixperms
dh_installdeb
dh_shlibdeps
dh_gencontrol
dh_md5sums
dh_builddeb
binary: binary-indep binary-arch
.PHONY: configure build clean install binary-indep binary-arch binary
|