Update for consistency with autoconf'ed LIBRARY_DEST definition.
[dyninst.git] / valueAdded / sharedMem / make.module.tmpl
1 # -*-Makefile-*-
2 #
3 # Common makefile template for rtinst library.  This file is not
4 # intended to be a useful Makefile in isolation; instead, it should be
5 # included from within an architecture-specific Makefile.
6 #
7 # $Id: make.module.tmpl,v 1.5 2008/03/12 20:09:43 legendre Exp $
8 #
9
10 # This is from the point of view of the build directories... so ../
11 MUTATEE_SRCS    = ../src/RTshared-unix.c
12
13 MUTATOR_SRCS    =       ../src/shmMgr.C \
14                         ../src/shmSegment.C \
15                         ../src/shmSegment-unix.C
16
17 MUTATEE_OBJS    = RTshared-unix.o
18 MUTATOR_OBJS    = shmMgr.o \
19                   shmSegment.o \
20                   shmSegment-unix.o
21
22 TO_INC = ../h
23 PUBLIC_H = SharedMem.h
24
25
26 SRCS = $(MUTATOR_SRCS)
27
28 TO_ROOT = ../../..
29 CXXFLAGS += -I$(TO_ROOT)/dyninstAPI/h -I$(TO_ROOT) -I$(TO_ROOT)/dynutil/h -I$(TO_ROOT)/symtabAPI/h -I$(TO_ROOT)/instructionAPI/h -fPIC
30 CFLAGS += -I$(TO_ROOT)/dyninstAPI/h -I$(TO_ROOT) -I$(TO_ROOT)/dynutil/h -I$(TO_ROOT)/symtabAPI/h -fPIC -I$(TO_ROOT)/instructionAPI/h
31
32 TARGETS = libdynShmMutatee.so libdynShmMutator.so
33
34 all: $(TARGETS)
35
36 # Override the install script - we have two files
37 OVERRIDE_INSTALL = true
38
39 install: $(TARGETS) install_generic
40         -$(CP) $(TARGETS) $(DEST)
41
42 libdynShmMutatee.so: $(MUTATEE_OBJS)
43         $(LD) $(LDFLAGS) $(LDFLAGS_MUTATEE) -o libdynShmMutatee.so $(MUTATEE_OBJS)
44 libdynShmMutator.so: $(MUTATOR_OBJS)
45         $(LD) $(LDFLAGS) -o libdynShmMutator.so $(MUTATOR_OBJS) $(MUTATOR_LIBS) $(LDFLAGS_MUTATOR)
46
47
48
49 MODCC         = $(CC)
50 MODCFLAGS     = $(CFLAGS)
51
52
53
54
55
56 #
57 # override standard install rule; provide a default DEST if not already set
58 #
59 ifndef DEST
60 DEST            = $(LIBRARY_DEST)
61 endif
62