File: rules

package info (click to toggle)
wl 2.14.0-4
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 5,628 kB
  • ctags: 3,422
  • sloc: lisp: 48,172; sh: 282; makefile: 157
file content (100 lines) | stat: -rwxr-xr-x 3,064 bytes parent folder | download | duplicates (2)
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
#!/usr/bin/make -f

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

PACKAGE=`cat debian/PACKAGE`
VERSION=`cat debian/VERSION`
EMACS=emacs21

build: pre-build build-stamp
build-stamp:
	dh_testdir

	$(EMACS) -l debian/env.el -l WL-MK -batch -q -no-site-file -f wl-texinfo-format

	touch build-stamp

pre-build: pre-build-stamp
pre-build-stamp:
	dh_testdir

	grep '^Package: ' debian/control | head -1 | sed -e "s/^Package: //g" \
	  > debian/PACKAGE
	dpkg-parsechangelog | grep '^Version: ' | sed -e "s/^Version: //g" \
	  > debian/VERSION

	sed -e "s/@PACKAGE@/$(PACKAGE)/g" \
	  debian/dirs.in > debian/dirs
	sed -e "s/@VERSION@/$(VERSION)/g" \
	  -e "s/@PACKAGE@/$(PACKAGE)/g" \
	  debian/emacsen-install.in > debian/emacsen-install
	sed -e "s/@PACKAGE@/$(PACKAGE)/g" \
	  debian/emacsen-remove.in > debian/emacsen-remove
	sed -e "s/@PACKAGE@/$(PACKAGE)/g" \
	  debian/emacsen-startup.in > debian/emacsen-startup
	sed -e "s/@PACKAGE@/$(PACKAGE)/g" \
	  debian/preinst.in > debian/preinst

	touch pre-build-stamp

clean:
	dh_testdir
	dh_testroot
	rm -f build-stamp pre-build-stamp install-stamp
	rm -f doc/*.info debian/PACKAGE debian/VERSION debian/dirs debian/emacsen-install debian/emacsen-remove debian/emacsen-startup debian/preinst
	dh_clean

install: build
	dh_testdir
	dh_testroot
	dh_clean -k
	dh_installdirs

	cp -r WL-* NEWS NEWS.ja Makefile wl elmo utils \
	  debian/$(PACKAGE)/usr/share/emacs/site-lisp/wl/
	chmod 0644 debian/$(PACKAGE)/usr/share/emacs/site-lisp/wl/wl/*.el
	chmod 0644 debian/$(PACKAGE)/usr/share/emacs/site-lisp/wl/elmo/*.el
	chmod 0644 debian/$(PACKAGE)/usr/share/emacs/site-lisp/wl/utils/*.el
	cp -r etc/icons/* \
	  debian/$(PACKAGE)/usr/share/pixmaps/wl/
	cp etc/ja.Emacs \
	  debian/$(PACKAGE)/etc/X11/Xresources/wanderlust.ja
	mv debian/$(PACKAGE)/usr/share/emacs/site-lisp/wl/wl/ChangeLog \
	  debian/$(PACKAGE)/usr/share/doc/$(PACKAGE)/changelog.wl
	mv debian/$(PACKAGE)/usr/share/emacs/site-lisp/wl/elmo/ChangeLog \
	  debian/$(PACKAGE)/usr/share/doc/$(PACKAGE)/changelog.elmo
	mv debian/$(PACKAGE)/usr/share/emacs/site-lisp/wl/utils/ChangeLog \
	  debian/$(PACKAGE)/usr/share/doc/$(PACKAGE)/changelog.utils

	touch install-stamp

# Build architecture-independent files here.
binary-indep: build install
#	dh_testversion
	dh_testdir
	dh_testroot
	dh_installdocs
	dh_installexamples samples/*
	dh_installemacsen --priority 65
	dh_installinfo
	dh_installchangelogs ChangeLog
	dh_link usr/share/pixmaps/wl usr/share/emacs/site-lisp/wl/etc/icons
	dh_link /usr/share/emacs/site-lisp/wl/NEWS /usr/share/doc/$(PACKAGE)/NEWS
	dh_link /usr/share/emacs/site-lisp/wl/NEWS.ja /usr/share/doc/$(PACKAGE)/NEWS.ja
	find debian/$(PACKAGE) -name CVS -prune -exec rm -rf {} \;
	find debian/$(PACKAGE) -name .cvsignore -prune -exec rm -rf {} \;

	dh_compress
	dh_fixperms
	dh_installdeb
	dh_gencontrol
	dh_md5sums
	dh_builddeb

# Build architecture-dependent files here.
binary-arch: build install
# We have nothing to do by default.

binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install