Added features to the dyninst API library, including an optional "else"
[dyninst.git] / dyninstAPI / 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 #
7
8 CFLAGS               += $(TCLFRIENDLYWARNINGS) -DBPATCH_LIBRARY -UMT_THREAD -DBPATCH_SET_MUTATIONS_ACTIVE
9 CXXFLAGS             += $(TCLFRIENDLYWARNINGS) -DBPATCH_LIBRARY -UMT_THREAD -DBPATCH_SET_MUTATIONS_ACTIVE
10 TFLAGS               += $(TCLFRIENDLYWARNINGS)
11
12 TARGET        = libdyninstAPI.a
13
14 VPATH        += .././.dyninstAPI/src:../dyninstAPI/h:\
15                 ../../paradynd/src:../../paradyn/h
16
17 SRCS         += ../src/BPatch.C \
18                 ../src/BPatch_image.C \
19                 ../src/BPatch_snippet.C \
20                 ../src/BPatch_templates.C \
21                 ../src/BPatch_thread.C \
22                 ../src/BPatch_type.C \
23                 ../src/BPatch_init.C \
24                 ../src/BPatch_module.C \
25                 ../src/BPatch_point.C \
26                 ../src/dummy.C \
27                 ../src/api_showerror.C \
28                 ../src/ast.C \
29                 ../src/inst.C \
30                 ../src/process.C \
31                 ../src/process2.C \
32                 ../src/stats.C \
33                 ../src/symtab.C \
34                 ../src/util.C \
35                 ../src/sharedobject.C \
36                 ../src/templates0.C \
37                 ../src/templates05.C \
38                 ../src/templates1.C \
39
40 ifdef USES_PVM
41 SRCS         += ../../paradynd/src/pvm_support.C \
42                 ../../paradynd/src/host_support.C \
43                 ../../paradynd/src/task_support.C \
44                 ../../paradynd/src/templatesPVM.C
45
46 CXXFLAGS        += -DPARADYND_PVM -DPOWER_DEBUG
47 LIBS            += -lpvm3
48
49 endif
50
51 ifdef USES_SHM_SAMPLING
52 SRCS            += ../../paradynd/src/fastInferiorHeap.C \
53                    ../../paradynd/src/fastInferiorHeapHKs.C \
54                    ../../paradynd/src/fastInferiorHeapMgr.C
55 CXXFLAGS        += -DSHM_SAMPLING
56 TFLAGS          += -DSHM_SAMPLING
57 CFLAGS          += -DSHM_SAMPLING
58 endif
59
60 #IGEN_GEN_SRCS = 
61
62 #IGEN_ISRCS    = 
63
64 LIBS            += -lpdutil
65
66 ifdef CROSSCOMPILER
67 SYSLIBS         += -liberty -lg++ -lstdc++ -lm
68 else
69 SYSLIBS         += -liberty
70 endif
71
72 IFLAGS       += -I../$(PLATFORM) -I../src -I../h -I../../paradynd/src
73
74 all:    $(TARGET)
75
76 templates0.o: ../src/templates0.C
77         $(CXX) -DBPATCH_LIBRARY $(TFLAGS) -c ../src/templates0.C
78
79 templates05.o: ../src/templates05.C
80         $(CXX) -DBPATCH_LIBRARY $(TFLAGS) -c ../src/templates05.C
81
82 templates1.o: ../src/templates1.C
83         $(CXX) -DBPATCH_LIBRARY $(TFLAGS) -c ../src/templates1.C