2 # This file defines the things that should be common to all "libraries"
3 # in the paradyn build tree. It depends on things like SRCS and
4 # TARGET being set correctly in the module-specific template and the
5 # architecture-specific Makefile.
7 # $Id: nmake.library.tmpl,v 1.4 1998/07/23 16:22:46 wylie Exp $
10 BUILD_ID= -s $(SUITE_NAME) -v $(RELEASE_NUM)$(BUILD_MARK)$(BUILD_NUM)
12 XTARGET = $(TARGET:.lib=)
13 XTARGET = $(XTARGET:.dll=)
14 VOUCHER = V_$(XTARGET)
17 @echo Updating build voucher information: $(VOUCHER)
18 $(BUILDSTAMP) $(BUILD_ID) $(XTARGET)
21 VPATH = $(VPATH) ../src
27 lib -out:$*.lib $(VOUCHER).obj $(OBJS)
34 $(AR) crv $(TARGET2) $(VOUCHER).obj $(OBJS2)
37 !endif # UNCOMMON_LINK
40 DEST = $(TO_CORE)\$(LIBRARY_DEST)
47 $(RM) *.obj *.h *.C *.lib *.exp *.pdb $(TARGET)
49 !ifndef UNCOMMON_INSTALL
50 install: $(DEST)/$(TARGET)
52 $(DEST)/$(TARGET): $(TARGET)
53 $(CP) $(TARGET) $(DEST)
54 # $(RANLIB) $(DEST)/$(TARGET)
57 # definition for secondary library
60 install: $(DEST)/$(TARGET2)
62 $(DEST)/$(TARGET2): $(TARGET2)
63 $(CP) $(TARGET2) $(DEST)
64 $(RANLIB) $(DEST)/$(TARGET2)
66 !endif # ifndef UNCOMMON_INSTALL
69 # dependency generation definitions
78 # Define DEPENDS dependencies such that the DEPENDS files depends on
79 # the .I files, not the .[Ch] files; otherwise, DEPENDS get rebuilt
80 # all the time. We do need to build the Igen-generated files before
81 # updating DEPENDS, however,
84 #!ifdef EXPLICIT_DEPENDS
87 #DEPENDS: $(SRCS) $(IGEN_ISRCS)
90 # $(MAKE) $(IGEN_GEN_SRCS)
92 # $(MODCC) -MM $(MODCFLAGS) $(SRCS) $(IGEN_GEN_SRCS) > DEPENDS
93 ## makedepend -fDEPENDS -- $(CFLAGS) $(SRCS) $(IGEN_SRCS) $(NOPED_SRCS)
95 #!ifdef EXPLICIT_DEPENDS
102 # $(MODCC) -MM $(MODCFLAGS) $(SRCS) > DEPENDS
103 ## makedepend -fDEPENDS -- $(CFLAGS) $(SRCS)
108 # makedepend -fDEPENDS -- $(CFLAGS) $(SRCS)
115 # A few pattern rules for simplicity in handling igen-generated files.
118 %.xdr.C %.xdr.CLNT.C %.xdr.CLNT.h %.xdr.SRVR.C %.xdr.SRVR.h %.xdr.h: %.I
119 $(IGEN) -xdr $(ICFLAGS) $<
121 %.thread.C %.thread.CLNT.h %.thread.SRVR.h %.thread.h: %.I
122 $(IGEN) -thread $(ICFLAGS) $<
126 $(CXX) $(CXXFLAGS) -c $<
129 $(CXX) $(CXXFLAGS) -c $<
140 $(CXX) $(CXXFLAGS) -c $<
145 # include the dependencies.