-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile.export
128 lines (113 loc) · 4.18 KB
/
Makefile.export
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
### -*-Mode: makefile;-*-
include Makefile.include
PWD=$(shell pwd)
#PLATFORM=${shell echo "prolog_flag(host_type,X), write(X), nl, fail."\
# | sicstus 2>/dev/null}
## use ldd --version to find out which glibc version is used
HARDWARE=$(shell uname -i)
KERNEL=$(shell uname -s)
GLIBC=$(shell getconf GNU_LIBC_VERSION)
PLATFORM=$(shell echo "$(HARDWARE) $(KERNEL) $(GLIBC)" | tr ' ' '-' )
gitversion=$(shell git log -1 --format="%at" | xargs -I{} date -u -d @{} +%Y%m%d.%H%M%S)
TAR=Alpino-$(PLATFORM)-git$(gitversion)-$(PROLOG).tar.gz
ifeq ($(PROLOG),sicstus)
export-default:
$(MAKE)
( cd create_bin ; $(MAKE) )
$(MAKE) install BINDIR=$(PWD)/bin\
LIBDIR=$(PWD)/lib\
MANDIR=$(PWD)/man\
PREFIX=$(PWD)\
ALPINO_HOME=$(PWD)
cp create_bin/Alpino bin/
$(MAKE) tar
else
export-default:
$(MAKE)
$(MAKE) install BINDIR=$(PWD)/bin\
LIBDIR=$(PWD)/lib\
MANDIR=$(PWD)/man\
PREFIX=$(PWD)\
ALPINO_HOME=$(PWD)
$(MAKE) tar
endif
echo:
@echo $(TAR)
tar:
cp create_bin/Alpino bin/
( cd .. ; tar czf $(TAR)\
--exclude=.git\
--exclude=*~\
--exclude=.#*\
--exclude=.nfs*\
--exclude=*.o\
--exclude=*.a\
--exclude=*.po\
--exclude=*.sav\
--exclude=*.mapfile\
--exclude=src/Alpino.bak\
--exclude=zlib\
--exclude=Specialization\
--exclude=Disambiguation\
--exclude=spldgen*sav.c\
--exclude=derivbank.so\
--exclude=pro_fadd.so\
--exclude=pro_lm.so\
--exclude=tokenize.so\
--exclude=corpusreader.so\
--exclude=zlib.so\
--exclude=Grammar/grammar_lc.pl\
--exclude=Grammar/penalty_weights.pl\
--exclude=Grammar/cdb\
--exclude=Tokenization/tok.c\
--exclude=Tokenization/tok_no_breaks.c\
--exclude=Tokenization/libtok.c\
--exclude=Tokenization/entities.c\
--exclude=Treebank/eans\
--exclude=Treebank/lassy\
--exclude=Treebank/medfail\
--exclude=Treebank/noisy\
--exclude=Treebank/paco-realtest\
--exclude=Treebank/paco-test\
--exclude=Treebank/qtleap1a\
--exclude=Treebank/qtleap1q\
--exclude=ovis*\
--exclude=LassySample250\
--exclude=LassySample500\
--exclude=PosTagger/Construct\
--exclude=Names/seeds\
--exclude=Names/features.pl\
--exclude=Names/Create\
--exclude=Generation/fluency/Create\
--exclude=Lexicon/Build\
--exclude=Names/Build\
--exclude=src/guides_data.c\
--exclude=src/gadata.pl\
--exclude=log\
--exclude=*_glue_*.c\
--exclude=spldgen_s_*\
--exclude=nohup.out\
--exclude=Suites/qtleap\
--exclude=Suites/Conll\
--exclude=Suites/ChildesDutch\
--exclude=Suites/Eindhoven\
--exclude=Suites/RSTCode\
--exclude=Suites/eans\
--exclude=Suites/CLEF2003\
--exclude=Suites/Spectrum*\
--exclude=Suites/TwNC-02\
--exclude=Suites/lassy.*\
Alpino )
sync
cp src/Alpino bin/
$(MAKE) -s --no-print-directory export-install
export-install:
@echo mv ../$(TAR) ~/public_html/alp/Alpino/versions/binary/$(TAR)
@echo and make sure latest.tar.gz points to this new file
check-permissions:
ls -lR |\
awk '{ print $$1 }' |\
grep . |\
grep -v -e '^[.]/' -e ^total -e '^-rw-r--r--.' \
-e '^drwxr-xr-x.' -e '^-rwxr-xr-x.' \
-e '^lrwxrwxrwx.'