File: rules

package info (click to toggle)
dsdo 1.6.36-17
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 1,612 kB
  • sloc: makefile: 189; perl: 77
file content (60 lines) | stat: -rwxr-xr-x 1,551 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
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

# Make sure build is always done in a reproducible and working
# language environment
LC_ALL = C
export LC_ALL

TMP_BUILD     = tmp-build
language_code = da
country_code  = DK
name_en       = danish
name_da       = dansk

%:
	dh $@


override_dh_auto_build:
	make all
	mkdir -p $(TMP_BUILD)

# --------- idanish ------------------
	cp ispell/dansk.aff   $(TMP_BUILD)/danish.aff
	gzip -9n -c ispell/words-$(language_code).complete \
		> $(TMP_BUILD)/$(name_en).mwl.gz

# --------- myspell-da -------------
#       da_DK.{aff,dic} available in myspell dir. Nothing extra to do here.

# --------- aspell-da -----------------
	cat new_aspell/$(language_code).cwl \
		| gzip -9n -c \
		> $(TMP_BUILD)/$(language_code).cwl.gz

# --------- wdanish ------------------
	cat words-$(language_code) \
		| iconv -f ISO-8859-1 -t UTF-8 \
		| sort -u \
		> $(TMP_BUILD)/danish

# --------- documentation ------------
	iconv -f ISO-8859-1 -t UTF-8 < README > $(TMP_BUILD)/README
	iconv -f ISO-8859-1 -t UTF-8 < contributors > $(TMP_BUILD)/contributors

override_dh_auto_clean:
	rm -rf $(TMP_BUILD)

	dh_auto_clean

override_dh_auto_install:
#       Most files are installed through debian/*.install files
	installdeb-ispell   -pidanish
	installdeb-aspell   -paspell-da
	installdeb-hunspell -pmyspell-da
	installdeb-myspell  -pmyspell-da --bdic-only --srcdir=./myspell
	installdeb-wordlist -pwdanish
	dh_installdocs -A $(TMP_BUILD)/README $(TMP_BUILD)/contributors