source: share/Makefile

Last change on this file was c03f8a5, checked in by Tomasz Obrebski <obrebski@…>, 9 years ago

minor fixes

  • Property mode set to 100644
File size: 1.7 KB
Line 
1include ../config.mak
2
3
4TARGETS = gram.dgp
5
6.PHONY: all
7all: $(TARGETS)
8
9# ------------------------------------------------------------------
10# main section
11# ------------------------------------------------------------------
12
13gram.dgp: gram.dgc
14        dgc --grammar=gram.dgc --categories=$(LANGUAGE)/lem.cats --outputfile=gram.dgp
15
16
17.PHONY: install
18install: install-grammar install-dictionaries
19
20.PHONY: install-grammar
21install-grammar:
22        install -m 0644 gram.dgp $(LANG_DIR)
23        install -m 0644 gram.dgc $(LANG_DIR)
24
25.PHONY: install-dictionaries
26install-dictionaries:
27ifdef LANG_DIR
28        install -d $(LANG_DIR)/pl_PL.ISO-8859-2
29        install -d $(LANG_DIR)/pl_PL.UTF-8
30        install -m 0644 pl_PL.ISO-8859-2/cor.bin $(LANG_DIR)/pl_PL.ISO-8859-2
31        install -m 0644 pl_PL.ISO-8859-2/gue.bin $(LANG_DIR)/pl_PL.ISO-8859-2
32        install -m 0644 pl_PL.ISO-8859-2/lem.bin $(LANG_DIR)/pl_PL.ISO-8859-2
33        install -m 0644 pl_PL.ISO-8859-2/lem.fst $(LANG_DIR)/pl_PL.ISO-8859-2
34        install -m 0644 pl_PL.ISO-8859-2/lem.cats $(LANG_DIR)/pl_PL.ISO-8859-2
35        install -m 0644 pl_PL.ISO-8859-2/pl_PL.ISO-8859-2.sym $(LANG_DIR)/pl_PL.ISO-8859-2
36        install -m 0644 pl_PL.UTF-8/lem.bin $(LANG_DIR)/pl_PL.UTF-8
37        install -m 0644 weights.kor $(LANG_DIR)
38endif
39
40.PHONY: uninstall
41uninstall:
42ifdef LANG_DIR
43        rm $(LANG_DIR)/weights.kor
44        rm $(LANG_DIR)/gram.*
45        rm $(LANG_DIR)/pl_PL.UTF-8/lem.bin
46        rm $(LANG_DIR)/pl_PL.ISO-8859-2/pl_PL.ISO-8859-2.sym
47        rm $(LANG_DIR)/pl_PL.ISO-8859-2/lem.cats
48        rm $(LANG_DIR)/pl_PL.ISO-8859-2/lem.bin
49        rm $(LANG_DIR)/pl_PL.ISO-8859-2/lem.fst
50        rm $(LANG_DIR)/pl_PL.ISO-8859-2/gue.bin
51        rm $(LANG_DIR)/pl_PL.ISO-8859-2/cor.bin
52        rmdir $(LANG_DIR)/pl_PL.ISO-8859-2
53        rmdir $(LANG_DIR)/pl_PL.UTF-8
54endif
55
56
57.PHONY: clean
58clean:
59        rm -f gram.dgp
60
Note: See TracBrowser for help on using the repository browser.