forked from mzsanford/cld
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sh
executable file
·46 lines (38 loc) · 1.55 KB
/
build.sh
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
#!/bin/bash
CFLAGS="-fPIC -I. -O2 -DCLD_WINDOWS"
LDFLAGS=-L.
CC=g++
AR=ar
rm -f *.o
rm -f libcld.a
SOURCES="encodings/compact_lang_det/cldutil.cc \
encodings/compact_lang_det/cldutil_dbg_empty.cc \
encodings/compact_lang_det/compact_lang_det.cc \
encodings/compact_lang_det/compact_lang_det_impl.cc \
encodings/compact_lang_det/ext_lang_enc.cc \
encodings/compact_lang_det/getonescriptspan.cc \
encodings/compact_lang_det/letterscript_enum.cc \
encodings/compact_lang_det/tote.cc \
encodings/compact_lang_det/generated/cld_generated_score_quadchrome_0406.cc \
encodings/compact_lang_det/generated/compact_lang_det_generated_cjkbis_0.cc \
encodings/compact_lang_det/generated/compact_lang_det_generated_ctjkvz.cc \
encodings/compact_lang_det/generated/compact_lang_det_generated_deltaoctachrome.cc \
encodings/compact_lang_det/generated/compact_lang_det_generated_quadschrome.cc \
encodings/compact_lang_det/win/cld_htmlutils_windows.cc \
encodings/compact_lang_det/win/cld_unilib_windows.cc \
encodings/compact_lang_det/win/cld_utf8statetable.cc \
encodings/compact_lang_det/win/cld_utf8utils_windows.cc \
encodings/internal/encodings.cc \
languages/internal/languages.cc"
#encodings/compact_lang_det/win/cld_unicodetext.cc \
echo
echo "Compile..."
$CC -c $CFLAGS $SOURCES
echo
echo "Make libcld.a"
$AR rcs libcld.a *.o
echo
echo "Compile example.cc"
$CC -DCLD_WINDOWS -I. -L. -o example example.cc -lcld -lstdc++
echo
echo "Done!"