File: rules

package info (click to toggle)
anthy 6300d-2
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 7,400 kB
  • ctags: 2,270
  • sloc: ansic: 17,009; sh: 13,554; lisp: 1,039; makefile: 252; ruby: 212; perl: 10
file content (152 lines) | stat: -rwxr-xr-x 3,907 bytes parent folder | download
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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
#!/usr/bin/make -f
# Sample debian/rules that uses debhelper.
# GNU copyright 1997 to 1999 by Joey Hess.

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

include /usr/share/dpatch/dpatch.make

DEB_HOST_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)

ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
	CFLAGS += -g
endif
ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
	INSTALL_PROGRAM += -s
endif

version=0

METADICDIR=usr/share/anthy/dic
DICDIR=var/lib/anthy
ELISPDIR=usr/share/emacs/site-lisp/anthy

configure: configure-stamp
configure-stamp: patch-stamp
	dh_testdir

	-test -r /usr/share/misc/config.sub && \
		cp -f /usr/share/misc/config.sub config.sub
	-test -r /usr/share/misc/config.guess && \
		cp -f /usr/share/misc/config.guess config.guess
	./configure $(confflags) \
		--prefix=/usr --mandir=\$${prefix}/share/man \
		--infodir=\$${prefix}/share/info --sysconfdir=/etc/anthy \

	touch configure-stamp

build: build-arch build-indep

build-arch: build-arch-stamp
build-arch-stamp: configure-stamp
	dh_testdir

	$(MAKE) sysconfdir=/etc/anthy ELCFILES=""

	touch build-arch-stamp

build-indep: build-indep-stamp
build-indep-stamp: configure-stamp
	touch build-indep-stamp

clean: unpatch
	dh_testdir
	dh_testroot
	rm -f build-arch-stamp build-indep-stamp configure-stamp

	-$(MAKE) distclean

	-rm -f conftest* src-util/*.elc config.log
	dh_clean

install: build
	dh_testdir
	dh_testroot
	dh_clean -k
	dh_installdirs

	-$(MAKE) install prefix=$(CURDIR)/debian/tmp/usr \
		sysconfdir=$(CURDIR)/debian/tmp/etc/anthy \
		lispdir=$(CURDIR)/debian/tmp/usr/share/emacs/site-lisp/anthy \
		ELCFILES=""

	install -d $(CURDIR)/debian/tmp/etc/anthy
	install -d $(CURDIR)/debian/tmp/usr/sbin

#	-mv debian/tmp/usr/share/anthy/anthy-conf debian/tmp/etc/anthy
	install -m 644 include/xstr.h \
		$(CURDIR)/debian/tmp/usr/include/anthy/xstr.h
	install -m 644 include/wtype.h \
		$(CURDIR)/debian/tmp/usr/include/anthy/wtype.h
	install -m 755 mkanthydic/.libs/mkanthydic \
		$(CURDIR)/debian/tmp/usr/bin/mkanthydic
	install -m 755 debian/update-anthy-dics \
		$(CURDIR)/debian/tmp/usr/sbin/update-anthy-dics

	install -d $(CURDIR)/debian/tmp/$(METADICDIR)
	install -m 644 cannadic/gcanna.ctd \
			$(CURDIR)/debian/tmp/$(METADICDIR)/gcanna.ctd
	install -m 644 cannadic/gcannaf.ctd \
			$(CURDIR)/debian/tmp/$(METADICDIR)/gcannaf.ctd

	cd $(CURDIR)/mkanthydic; \
		for i in *.t; do \
			install -m 644 $$i $(CURDIR)/debian/tmp/$(METADICDIR); \
		done; \
	cd $(CURDIR)
	install -m 644 mkanthydic/udict \
			$(CURDIR)/debian/tmp/$(METADICDIR)/udict

binary-indep: build-indep install
	dh_testdir -i
	dh_testroot -i

	install -d $(CURDIR)/debian/tmp/$(ELISPDIR)

	for i in anthy-conf anthy-dic anthy anthy-isearch anthy-azik; do \
		install -m 644 $(CURDIR)/src-util/$$i.el \
			$(CURDIR)/debian/tmp/$(ELISPDIR)/$$i.el; \
	done

	dh_movefiles -i
	dh_installdocs -i
	dh_installexamples -i
	dh_installemacsen -i
	dh_installchangelogs -i ChangeLog
	dh_link -i
	dh_strip -i
	dh_compress -i
	dh_fixperms -i
#	dh_makeshlibs -i
	dh_installdeb -i
#	dh_shlibdeps -l`pwd`/debian/libanthy$(version)/usr/lib
	dh_gencontrol -i
	dh_md5sums -i
	dh_builddeb -i
binary-arch: build-arch install
	dh_testdir -a
	dh_testroot -a
	dh_movefiles -a
	dh_installdebconf -a
	dh_installdocs -a
	dh_installexamples -a
#	dh_installmenu -a
#	dh_installemacsen
	dh_installman -a
	dh_installinfo -a
	dh_undocumented -a anthy-agent.1 anthy-dic-tool.1
	dh_installchangelogs -a ChangeLog
	dh_link -a
	dh_strip -a
	dh_compress -a
	dh_fixperms -a
	dh_makeshlibs -a -V
	dh_installdeb -a
	dh_shlibdeps -a -L libanthy0 -l`pwd`/debian/libanthy$(version)/usr/lib
	dh_gencontrol -a
	dh_md5sums -a
	dh_builddeb -a
binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install install-indep install-arch configure patch unpatch