New SymLite code source, now used by AnalysisStepper.
[dyninst.git] / parseAPI / make.module.tmpl
1
2 # Common makefile template for the dyninstAPI library.  This file is not
3 # intended to be a useful Makefile in isolation; instead, it should be
4 # included from within an architecture-specific Makefile.
5 #
6 # $Id: make.module.tmpl,v 1.4 2008/09/15 17:38:17 jaw Exp $
7 #
8
9 SUITE_NAME      = ParseAPI
10 RELEASE_MAJOR   = 7
11 RELEASE_MINOR = 0
12 #BUILD_MARK should be (re-)defined in core/make.config.local rather than here!
13
14 ifndef TARGET
15 ifdef STATIC_COMPS
16 STATIC_LIBRARY = true
17 TARGET = libparseAPI.a
18 else
19 TARGET = libparseAPI.so
20 endif
21 endif
22
23 ifndef STATIC_COMPS
24 CFLAGS += -fPIC
25 CXXFLAGS += -fPIC
26 endif
27
28 CFLAGS               += $(USEFULWARNINGS) -I$(TO_CORE)/../include
29 CXXFLAGS             += $(USEFULWARNINGS) -I$(TO_CORE)/../include
30
31 LDFLAGS += -L../../common/$(PLATFORM) -lcommon
32 ifneq (x$(WITHOUT_SYMTAB_API),xtrue)
33 LDFLAGS += -L../../symtabAPI/$(PLATFORM) -lsymtabAPI
34 SRCS += ../src/SymtabCodeSource.C
35 endif
36
37 LDFLAGS     += $(LIBDIR)
38 ifndef USES_NATIVE_CC
39 LD              = $(GXX)
40 LDFLAGS         += -shared $(G_PTHREAD_LD)
41 CXXFLAGS        += $(G_PTHREAD)
42 else
43 ifeq (solaris,$(findstring solaris,$(PLATFORM)))
44 LDFLAGS         += -G
45 endif #sparc
46 endif #USES_NATIVE
47
48 ifneq ($(findstring cap_instruction_api,$(CAP_DEF)),)
49     LDFLAGS += -L../../instructionAPI/$(PLATFORM) -linstructionAPI
50 endif
51
52 TO_INC   = ../h
53
54 PUBLIC_H = \
55     CFGFactory.h\
56     CFGModifier.h \
57     CFG.h\
58     CodeObject.h\
59     CodeSource.h\
60     Location.h\
61     InstructionAdapter.h\
62     InstructionSource.h\
63     ParseCallback.h\
64     ParseContainers.h\
65     SymLiteCodeSource.h
66
67 SRCS += ../src/ParserDetails.C \
68         ../src/Parser.C \
69         ../src/CFGFactory.C \
70         ../src/Function.C \
71         ../src/Block.C \
72                 ../src/CodeObject.C \
73                 ../src/debug_parse.C \
74         ../src/CodeSource.C \
75         ../src/ParseData.C\
76         ../src/InstructionAdapter.C\
77         ../src/Parser-speculative.C\
78         ../src/ParseCallback.C \
79         ../src/IA_x86Details.C \
80         ../src/IA_powerDetails.C \
81         ../src/IA_platformDetailsFactory.C \
82         ../src/CFGModifier.C\
83         ../src/SymLiteCodeSource.C \
84         ../../common/src/SymLite-elf.C \
85         ../../common/src/Elf_X.C
86
87 ifneq ($(findstring cap_instruction_api,$(CAP_DEF)),)
88 SRCS += ../../dataflowAPI/src/ABI.C \
89         ../../dataflowAPI/src/Absloc.C \
90         ../../dataflowAPI/src/AbslocInterface.C \
91         ../../dataflowAPI/src/convertOpcodes.C \
92         ../../dataflowAPI/src/debug_dataflow.C \
93         ../../dataflowAPI/src/ExpressionConversionVisitor.C \
94         ../../dataflowAPI/src/InstructionCache.C \
95         ../../dataflowAPI/src/liveness.C \
96         ../../dataflowAPI/src/RegisterMap.C \
97         ../../dataflowAPI/src/RoseImpl.C \
98         ../../dataflowAPI/src/RoseInsnFactory.C \
99         ../../dataflowAPI/src/slicing.C \
100         ../../dataflowAPI/src/stackanalysis.C \
101         ../../dataflowAPI/src/SymbolicExpansion.C \
102         ../../dataflowAPI/src/SymEval.C \
103         ../../dataflowAPI/src/SymEvalPolicy.C \
104         ../../dataflowAPI/src/templates.C \
105         ../../dataflowAPI/src/Visitors.C \
106         ../src/StackTamperVisitor.C
107
108 VPATH += ../../dataflowAPI/src
109 VPATH += ../../dataflowAPI/h
110 VPATH += ../../common/src
111
112 PUBLIC_H += Absloc.h \
113          AbslocInterface.h \
114          slicing.h \
115          SymEval.h \
116          stackanalysis.h \
117          liveness.h \
118          ABI.h \
119          bitArray.h \
120          InstructionCache.h      
121 endif
122
123 IFLAGS       += -I../$(PLATFORM) -I../src -I../../dataflowAPI/src -I../../dataflowAPI/h -I../h -I../../dynutil/h -I../../symtabAPI/h -I../../common/h -I../../instructionAPI/h
124
125