ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/SCRAM/src/toolrules.mk
(Generate patch)

Comparing COMP/SCRAM/src/toolrules.mk (file contents):
Revision 1.9 by williamc, Tue Mar 30 15:07:35 1999 UTC vs.
Revision 1.17 by williamc, Thu Apr 1 17:28:46 1999 UTC

# Line 1 | Line 1
1   # Some Pre-Defined Rules For Building Stuff
2   #
3 < #include compilers.mk
3 > .PHONY:bin lib
4   lib : dependencies.mk
5   bin : dependencies.mk
6  
# Line 11 | Line 11 | bin : dependencies.mk
11   binarystore:=$(LOCALTOP)/$(INTbin)
12   VPATH+=:$(LOCALTOP)/$(INTbin):$(RELEASETOP)/$(INTbin)
13  
14 # -- storage of libraries
15 librarystore:=$(LOCALTOP)/$(INTlib)
16 vpath %.$(SharedSuffix) $(librarystore):$(RELEASETOP)/$(INTlib)
17 vpath %.$(ArchiveSuffix) $(librarystore):$(RELEASETOP)/$(INTlib)
18
14   # -- library names
15  
16   ifdef libname
# Line 37 | Line 32 | ifdef DefaultDebugShared
32   lib : $(shlibname)_d.$(SharedSuffix)
33   MakeLib=yes
34   endif
35 + ifdef DefaultInsureShared
36 + lib : $(shlibname)_Insure.$(SharedSuffix)
37 + MakeLib=yes
38 + endif
39   ifdef DefaultArchive
40   lib : $(arlibname).$(ArchiveSuffix)
41   MakeLib=yes
# Line 45 | Line 44 | ifdef DefaultDebugArchive
44   lib : $(arlibname)_d.$(ArchiveSuffix)
45   MakeLib=yes
46   endif
47 + ifdef DefaultInsureArchive
48 + lib : $(arlibname)_Insure.$(ArchiveSuffix)
49 + MakeLib=yes
50 + endif
51  
52   ifdef MakeLib
53   all: lib
# Line 59 | Line 62 | Sarchivelibobjs:=$(addsuffix .o,$(archiv
62   Sarchivelibdebugobjs:=$(addsuffix _d.o,$(archivefiles))
63   Ssharedlibobjs:=$(addsuffix _pic.o,$(sharedfiles))
64   Ssharedlibdebugobjs:=$(addsuffix _picd.o,$(sharedfiles))
65 <
66 < # binary target files
64 < Sbinaryobjects:=$(addsuffix .o,$(binfiles))
65 > SsharedlibInsureobjs:=$(addsuffix _picInsure.o,$(sharedfiles))
66 > SarchivelibInsureobjs:=$(addsuffix _Insure.o,$(archivefiles))
67  
68   #------------------------------------------------
69   # Rules Start Here
# Line 95 | Line 97 | Sbinaryobjects:=$(addsuffix .o,$(binfile
97  
98   %_picd.o : %.f
99          $(FC) -c $(CPPFLAGS) $(FFLAGS) $(FCDebugFlag) $(SharedFCObjectFlags) $< -o $@
100 < # -- Standard Archive Libs
101 < # Already built in
100 >
101 > # -- Debug Shared Objects with Insure
102 > %_picInsure.o : %.cc
103 >        $(Insure) -c $(CPPFLAGS) $(CXXFLAGS) $(CXXDebugFlag) $(SharedCCObjectFlags) $< -o $@
104 >
105 > %_picInsure.o : %.C
106 >        $(Insure) -c $(CPPFLAGS) $(CXXFLAGS) $(CXXDebugFlag) $(SharedCCObjectFlags) $< -o $@
107 >
108 > %_picInsure.o : %.cpp
109 >        $(Insure) -c $(CPPFLAGS) $(CXXFLAGS) $(CXXDebugFlag) $(SharedCCObjectFlags) $< -o $@
110 >
111  
112   # -- Debug Archive Libs
113   %_d.o : %.cpp
# Line 114 | Line 125 | Sbinaryobjects:=$(addsuffix .o,$(binfile
125   %_d.o : %.f
126          $(FC) -c $(CPPFLAGS) $(FFLAGS) $(FCDebugFlag) $< -o $@
127  
128 + # -- Debug Archive Libs with Insure
129 + %_Insure.o : %.cpp
130 +        $(Insure) -c $(CPPFLAGS) $(CXXFLAGS) $(CXXDebugFlag) $< -o $@
131 +
132 + %_Insure.o : %.cc
133 +        $(Insure) -c $(CPPFLAGS) $(CXXFLAGS) $(CXXDebugFlag) $< -o $@
134 +
135 + %_Insure.o : %.C
136 +        $(Insure) -c $(CPPFLAGS) $(CXXFLAGS) $(CXXDebugFlag) $< -o $@
137 +
138 + # -- Standard Archive Libs
139 + %.o : %.cpp
140 +        $(CXX) -c $(CPPFLAGS) $(CXXFLAGS) $< -o $@
141 +
142 + %.o : %.cc
143 +        $(CXX) -c $(CPPFLAGS) $(CXXFLAGS) $< -o $@
144 +
145 + %.o : %.C
146 +        $(CXX) -c $(CPPFLAGS) $(CXXFLAGS) $< -o $@
147 +
148 + %.o : %.F
149 +        $(FC) -c $(CPPFLAGS) $(FFLAGS) $< -o $@
150 +
151 + %.o : %.f
152 +        $(FC) -c $(CPPFLAGS) $(FFLAGS) $< -o $@
153 +
154 + # Already built in
155 +
156   # -------------------------------------------------------------------------
157 < # -- Executables
158 < %.exe : %.o
159 <        $(CXX) $(CXXFLAGS) $(LDFLAGS) $< -o $@ $(LDLIBS)
157 > # Executables
158 > # -------------------------------------------------------------------------
159 >
160 > # -- Debug Executables
161 >
162 > lib_d=$(shell $(TOOL_HOME)/LibTypeExpand "_d" $(lib))
163 > LDLIBS_D=$(addprefix -l,$(lib_d))
164  
165 < # -- Debug Exexcutables
165 > #%_d.exe :
166 > #       $(CXX) $(CXXFLAGS) $(CXXDebugFlag) $(LDFLAGS) $< -o $@ $(LDLIBS_D)
167  
168 < #LDLIBS_D:=$(shell $(TOOL_HOME)/LibTypeExpand $(LDLIBS) "_d")
169 < %_d.exe :
170 <        $(CXX) $(CXXFLAGS) $(CXXDebugFlag) $(LDFLAGS) $< -o $@ \                        $(LDLIBS_D)
168 > # -- Insure Executables
169 > lib_Insure=$(shell $(TOOL_HOME)/LibTypeExpand "_Insure" $(lib))
170 > LDLIBS_I=$(addprefix -l,$(lib_Insure))
171 > #%_Insure.exe :
172 > #       $(Insure) $(CXXFLAGS) $(CXXDebugFlag) $(LDFLAGS) $< -o $@ $(LDLIBS_D)
173 >
174 > # -- Executables
175 > #%.exe :
176 > #       $(CXX) $(CXXFLAGS) $(LDFLAGS) $< -o $@ $(LDLIBS)
177 >
178 > # -------------------------------------------------------------------------
179  
180   realbins:=$(filter $(bintargets),$(notdir $(wildcard $(LOCALTOP)/$(INTbin)/*)))
181   clean ::
# Line 157 | Line 209 | $(shlibname)_picd.$(SharedSuffix) : $(Ss
209   $(shlibname)_d.$(SharedSuffix) : $(Ssharedlibdebugobjs)
210          @mv $< $(librarystore)/$@
211  
212 + # -- Insure Shared Objects Libs
213 + $(shlibname)_picInsure.$(SharedSuffix) : $(SsharedlibInsureobjs)
214 +        $(SharedCCTool)
215 +
216 + $(shlibname)_Insure.$(SharedSuffix) : $(SsharedlibInsureobjs)
217 +        @mv $< $(librarystore)/$@
218 +
219   # -- Standard Archive Libs
220   $(arlibname).$(ArchiveSuffix) : $(Sarchivelibobjs)
221          $(ArchiveCCTool)
# Line 167 | Line 226 | $(arlibname)_d.$(ArchiveSuffix) : $(Sarc
226          $(ArchiveCCTool)
227          @mv $@ $(librarystore)/$@
228  
229 + # -- Insure Archive libs
230 + $(arlibname)_Insure.$(ArchiveSuffix) : $(SarchivelibInsureobjs)
231 +        $(ArchiveCCTool)
232 +        @mv $@ $(librarystore)/$@
233 +
234   # -- Dependencies
235   dependencies.mk: $(files)
236          @$(DependencyCCTool)
237          @$(TOOL_HOME)/DependencyMangler $@
238 +
239 + %.dep:
240 +        @$(DependencyCCTool)
241 +        @$(TOOL_HOME)/DependencyMangler $@
242 +

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines