-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.am
90 lines (65 loc) · 2.66 KB
/
Makefile.am
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
# Makefile for Assamese-Bengali MT
LANG1=asm
LANG2=ben
PREFIX1=$(LANG1)-$(LANG2)
PREFIX2=$(LANG2)-$(LANG1)
BASENAME=apertium-$(PREFIX1)
TARGETS_COMMON = $(PREFIX1).autobil.bin $(PREFIX2).autobil.bin \
$(PREFIX1).automorf.bin $(PREFIX1).autogen.bin $(PREFIX1).t1x.bin \
$(PREFIX2).automorf.bin $(PREFIX2).autogen.bin $(PREFIX2).t1x.bin \
$(PREFIX1).mode $(PREFIX2).mode modes
@ap_include@
# Assamese transducer
$(PREFIX1).automorf.bin: $(BASENAME).$(LANG1).dix
apertium-validate-dictionary $(BASENAME).$(LANG1).dix
lt-comp lr $(BASENAME).$(LANG1).dix $@
$(PREFIX2).autogen.bin: $(BASENAME).$(LANG1).dix
apertium-validate-dictionary $(BASENAME).$(LANG1).dix
lt-comp rl $(BASENAME).$(LANG1).dix $@
# Bengali transducer
$(PREFIX2).automorf.bin: $(BASENAME).$(LANG2).dix
apertium-validate-dictionary $(BASENAME).$(LANG2).dix
lt-comp lr $(BASENAME).$(LANG2).dix $@
$(PREFIX1).autogen.bin: $(BASENAME).$(LANG2).dix
apertium-validate-dictionary $(BASENAME).$(LANG2).dix
lt-comp rl $(BASENAME).$(LANG2).dix $@
# Bilingual dictionaries
$(PREFIX1).autobil.bin: $(BASENAME).$(PREFIX1).dix
apertium-validate-dictionary $<
lt-comp lr $< $@
$(PREFIX2).autobil.bin: $(BASENAME).$(PREFIX1).dix
apertium-validate-dictionary $<
lt-comp rl $< $@
# Transfer rules
$(PREFIX1).t1x.bin: $(BASENAME).$(PREFIX1).t1x
apertium-validate-transfer $(BASENAME).$(PREFIX1).t1x
apertium-preprocess-transfer $(BASENAME).$(PREFIX1).t1x $@
$(PREFIX2).t1x.bin: $(BASENAME).$(PREFIX2).t1x
apertium-validate-transfer $(BASENAME).$(PREFIX2).t1x
apertium-preprocess-transfer $(BASENAME).$(PREFIX2).t1x $@
empty.bin: empty.t1x
apertium-validate-transfer empty.t1x
apertium-preprocess-transfer empty.t1x $@
# Installation
EXTRA_DIST=$(PREFIX1).prob $(PREFIX2).prob \
$(BASENAME).$(LANG1).dix \
$(BASENAME).$(LANG2).dix \
$(BASENAME).$(PREFIX1).dix \
$(BASENAME).$(PREFIX1).t1x \
$(BASENAME).$(PREFIX2).t1x \
modes.xml
apertium_as_bndir=$(prefix)/share/apertium/$(BASENAME)/
apertium_as_bn_DATA=$(PREFIX1).autobil.bin $(PREFIX2).autobil.bin \
$(PREFIX1).prob $(PREFIX2).prob \
$(PREFIX1).autogen.bin $(PREFIX2).autogen.bin \
$(PREFIX1).automorf.bin $(PREFIX2).automorf.bin \
$(PREFIX1).t1x.bin $(PREFIX2).t1x.bin \
$(BASENAME).$(PREFIX1).t1x $(BASENAME).$(PREFIX2).t1x \
modes.xml
noinst_DATA=modes/$(PREFIX1).mode modes/$(PREFIX2).mode
install-data-local: install-modes
$(INSTALL_DATA) $(BASENAME).$(PREFIX1).t1x $(DESTDIR)$(apertium_as_bndir)
$(INSTALL_DATA) $(BASENAME).$(PREFIX2).t1x $(DESTDIR)$(apertium_as_bndir)
CLEANFILES = -r $(TARGETS_COMMON)
test: all
apertium-regtest test