-
Notifications
You must be signed in to change notification settings - Fork 13
/
Makefile
executable file
·98 lines (79 loc) · 4.14 KB
/
Makefile
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
###################################################################
include Makefile.in
################ To compile Tamgu#################################
SOURCETamgu = tamgu.cxx conversion.cxx tamgutamgu.cxx tamgubool.cxx tamgubvector.cxx tamgubyte.cxx tamgudate.cxx tamgudecimal.cxx\
tamgufile.cxx tamguufile.cxx tamgufloat.cxx tamgufmatrix.cxx tamgufraction.cxx tamguframeinstance.cxx tamgufvector.cxx tamgudvector.cxx\
tamgusynode.cxx tamgutable.cxx tamguchrono.cxx tamgulisp.cxx\
tamgugrammar.cxx tamgutaskell.cxx tamguimatrix.cxx tamguint.cxx tamguiterator.cxx tamguivector.cxx tamgulist.cxx tamgulvector.cxx\
tamgulong.cxx tamgumap.cxx tamgumapf.cxx tamgumapff.cxx tamgumapfi.cxx tamgumapfs.cxx tamgumapfu.cxx tamgumapi.cxx tamgutreemapi.cxx tamgutreemapif.cxx\
tamgumapif.cxx tamgumapii.cxx tamgumapis.cxx tamgumapiu.cxx tamgumapsf.cxx tamgumapsi.cxx tamgumapss.cxx tamgumapu.cxx\
tamgumapuf.cxx tamgumapui.cxx tamgumapuu.cxx tamguprimemap.cxx tamguprimemapsf.cxx tamguprimemapsi.cxx tamguprimemapss.cxx\
tamgushort.cxx tamgusocket.cxx tamgustdin.cxx tamgustring.cxx tamgusvector.cxx tamgusys.cxx tamgutime.cxx tamgutransducer.cxx tamgutreemap.cxx\
tamguustring.cxx tamguuvector.cxx tamguvector.cxx automaton.cxx codeparse.cxx codecompile.cxx codeexecute.cxx codeoperations.cxx\
tamgurawstring.cxx containerrecording.cxx globaltamgu.cxx objectrecording.cxx predicate.cxx predicatefunctions.cxx procedures.cxx tools.cxx\
tamguhvector.cxx tamgumapfl.cxx tamgumapl.cxx tamgumaplf.cxx tamgumapll.cxx tamgumapls.cxx tamgumaplu.cxx tamgumapsl.cxx tamgumapul.cxx\
tamgutreemapf.cxx tamgutreemapsf.cxx tamgutreemapsi.cxx tamgutreemapss.cxx tamguprimemapsl.cxx tamgutreemapls.cxx tamgutreemapsl.cxx tamguautomaton.cxx tamguannotator.cxx
#------------------------------------------------------------
SOURCETAMGUMAIN = maintamgu.cxx jag.cxx
SOURCEJAG = jagmain.cxx jag.cxx conversion.cxx jagrgx.cxx
#------------------------------------------------------------
OBJECTTamgu = $(SOURCETamgu:%.cxx=$(OBJPATH)/%.o)
#------------------------------------------------------------
OBJECTTAMGUMAIN = $(SOURCETAMGUMAIN:%.cxx=$(LIBOBJPATH)/%.o)
OBJECTJAG = $(SOURCEJAG:%.cxx=$(LIBOBJPATH)/jag/%.o)
#------------------------------------------------------------
TamguBASICFLAGS = -w -c -fPIC $(Optim) -DUNIX $(MULTIGA) $(INTELINT) $(REGEX) $(SPECFLAGS) $(MOUSESUPPORT)
TamguCFLAGS = -std=c99 $(TamguBASICFLAGS)
TamguFLAGS = $(C++11Flag) $(TamguBASICFLAGS)
Tamguincludes= -Iinclude -Iinclude/libs $(INCLUDEPATH)
TamguSYSTEMLIBS = $(SYSTEMSPATH) -lpthread $(MACLIBS) $(LIBREGEX) -ldl $(SSLLIB) $(CRYPTOLIB) -lldap
#------------------------------------------------------------
$(OBJPATH)/%.o: src/%.cxx
$(COMPPLUSPLUS) $(TamguFLAGS) $(Tamguincludes) $< -o $@
$(LIBOBJPATH)/%.o: src/%.cxx
$(COMPPLUSPLUS) $(TamguFLAGS) $(Tamguincludes) $< -o $@
$(LIBOBJPATH)/%.o: src/libs/%.cxx
$(COMPPLUSPLUS) $(TamguFLAGS) $(Tamguincludes) $< -o $@
$(LIBOBJPATH)/jag/%.o: src/%.cxx
$(COMP) -Iinclude $(TamguFLAGS) $< -o $@
#------------------------------------------------------------
libtamgu: $(OBJECTTamgu)
$(COMPPLUSPLUS) -shared -o $(BINPATH)/libtamgu.so $(OBJECTTamgu) $(SYSTEMSPATH)
# For those who prefer a small executable linked with a dynamic library
#tamgu: $(OBJECTTAMGUMAIN)
# $(COMPPLUSPLUS) -o $(BINPATH)/tamgu $(OBJECTTAMGUMAIN) -L$(BINPATH) -ltamgu $(TamguSYSTEMLIBS)
# For those who do not want to be bothered with a dynamic library link...
tamgu: $(OBJECTTAMGUMAIN) $(OBJECTTamgu)
$(COMPPLUSPLUS) -o $(BINPATH)/tamgu $(OBJECTTAMGUMAIN) $(OBJECTTamgu) $(TamguSYSTEMLIBS)
jag: install $(OBJECTJAG)
$(COMPPLUSPLUS) -o $(BINPATH)/jag $(OBJECTJAG) $(LIBREGEX)
lib: install libtamgu
$(libtamgu)
all: install libtamgu tamgu
$(libtamgu)
$(tamgu)
install:
mkdir -p bin
mkdir -p $(BINPATH)
mkdir -p objs
mkdir -p $(OBJPATH)
mkdir -p libobjs
mkdir -p $(LIBOBJPATH)
mkdir -p $(LIBOBJPATH)/jag
cleanall:
rm -f $(OBJPATH)/*.o
rm -f $(LIBOBJPATH)/*.o
rm -f $(BINPATH)/*.so
rm -f $(BINPATH)/tamgu*
rm -f $(BINPATH)/jag
rm -f $(LIBOBJPATH)/jag/*.o
clean:
rm -f $(OBJPATH)/*.o
rm -f $(LIBOBJPATH)/*.o
rm -f $(LIBOBJPATH)/jag/*.o
cleanlib:
rm -f $(OBJPATH)/*.o
full: install libtamgu tamgu
$(libtamgu)
$(tamgu)
$(libs)