1 martin 1.31 #//%2005////////////////////////////////////////////////////////////////////////
2 #//
3 #// Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
4 #// Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
5 #// Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.;
6 #// IBM Corp.; EMC Corporation, The Open Group.
7 #// Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
8 #// IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
9 #// Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
10 #// EMC Corporation; VERITAS Software Corporation; The Open Group.
11 #//
12 #// Permission is hereby granted, free of charge, to any person obtaining a copy
13 #// of this software and associated documentation files (the "Software"), to
14 #// deal in the Software without restriction, including without limitation the
15 #// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
16 #// sell copies of the Software, and to permit persons to whom the Software is
17 #// furnished to do so, subject to the following conditions:
18 #//
19 #// THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
20 #// ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
21 #// "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
22 martin 1.31 #// LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
23 #// PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
24 #// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
25 #// ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
26 #// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27 #//
28 #//==============================================================================
|
29 karl 1.6 # Pegasus top level make file
|
30 jim.wunderlich 1.34 # see the usage rule for options
31
|
32 mike 1.1 ROOT = .
33
|
34 konrad.r 1.24 include $(ROOT)/env_var.status
|
35 mike 1.1 include $(ROOT)/mak/config.mak
36
|
37 karl 1.11 # This is a recurse make file
|
38 karl 1.6 # Defines subdirectorys to go to recursively
39
|
40 mike 1.3 # DIRS = src cgi
|
41 konrad.r 1.23 DIRS = src test rpm Schemas
|
42 mike 1.1
|
43 karl 1.11 # Define the inclusion of the recurse.mak file to execute the next
44 # level of makefiles defined by the DIRS variable
|
45 karl 1.6
|
46 jim.wunderlich 1.34 defaultrule: all setupdevserver
47
|
48 mike 1.1 include $(ROOT)/mak/recurse.mak
49
|
50 jim.wunderlich 1.34 .PHONY: FORCE
|
51 jim.wunderlich 1.32
|
52 jim.wunderlich 1.34 FORCE:
|
53 jim.wunderlich 1.32
|
54 jim.wunderlich 1.34 usage: FORCE
55 $(USAGE)
56 $(USAGE)"Makefile targets:"
57 $(USAGE)
58 $(USAGE)"Recursive rules - These are the primatives that traverse the tree"
59 $(USAGE)"invoking the specified command in each subdirectory directory."
60 $(USAGE)"NOTE: all is special, it specifies no target and therefore invokes"
61 $(USAGE)"the default rule for that directory."
62 $(USAGE)"all - recursive DEFAULT rule"
63 $(USAGE)"clean - recursive clean"
64 $(USAGE)"depend - buildmu recursive depend"
65 $(USAGE)"messages - rootbundle recursive messages"
66 $(USAGE)"tests - recursive tests"
67 $(USAGE)"poststarttests - recursive poststarttests"
68 $(USAGE)
69 $(USAGE)"Combinational rules - Combine other rules to achieve results"
70 $(USAGE)"DEFAULT RULE - all, setupdevserver"
71 $(USAGE)"new - clean repositoryclean"
72 $(USAGE)"build - depend all, setupdevserver"
73 $(USAGE)"smallworld - build unittests serverquicktests"
74 $(USAGE)"world - build unittests servertests"
75 jim.wunderlich 1.34 $(USAGE)
76 $(USAGE)"Functional rules - Other rules to achieve specified results"
77 $(USAGE)"buildmu - builds the mu utility"
78 $(USAGE)"setupdevserver - setup the development server env"
79 $(USAGE)"cleandevserver - cleans the development server env"
80 $(USAGE)"repository - builds the base repository"
81 $(USAGE)"testrepository - builds items for the test suites into the repository"
82 $(USAGE)"removetestrepository- removes test items from the repository"
83 $(USAGE)"repositoryclean - cleans the repository"
84 $(USAGE)"listplatforms - List all valid platforms"
85 $(USAGE)
86 $(USAGE)"Test rules (accessable here but implemented in TestMakefile)"
87 $(USAGE)"alltests - unittests and servertests"
88 $(USAGE)"unittests - runs the unit functional test"
89 $(USAGE)"serverquicktests - runs quick server tests"
90 $(USAGE)"servertests - runs basic server tests"
91 $(USAGE)"standardtests - runs server extended tests"
92 $(USAGE)"testusage - TestMakefile usage"
93 $(USAGE)"testusage2 - TestMakefile usage2"
94 $(USAGE)
95 $(USAGE)"--------------------"
96 jim.wunderlich 1.34 $(USAGE)"Quick start:"
97 $(USAGE)" After checkout of new tree:"
98 $(USAGE)" use \"make listplatforms\" to view a list of platforms"
99 $(USAGE)" set PEGASUS_PLATFORM=<your platofrm>"
100 $(USAGE)" set PEGASUS_ROOT=<location of your pegasus source>"
101 $(USAGE)" set PEGASUS_HOME=<build output location"
102 $(USAGE)" make smallworld"
103 $(USAGE)
104 $(USAGE)" This will build everthing with a default configuration"
105 $(USAGE)" and run some tests."
106 $(USAGE)
107 $(USAGE)" For a more extensive test use \"make world\""
108 $(USAGE)
109 $(USAGE)"--------------------"
110 $(USAGE)"Examples:"
111 $(USAGE)" After \"cvs checkout\" of new tree: make smallworld"
112 $(USAGE)" OR make world"
113 $(USAGE)
114 $(USAGE)" After changes to include files: make"
115 $(USAGE)
116 $(USAGE)" After changes to the files included: make build"
117 jim.wunderlich 1.34 $(USAGE)
118 $(USAGE)" After \"cvs update\" or to start over: make new smallworld"
119 $(USAGE)" OR make new world"
120 $(USAGE)
121
122 listplatforms: FORCE
123 $(USAGE)
124 $(USAGE)"The $(words $(VALID_PLATFORMS)) valid platforms are:"
125 $(USAGE)" $(foreach w, $(VALID_PLATFORMS), " $w ")"
126 $(USAGE)
127 $(USAGE)
128
129 #########################################################################
130 # This section defines any prerequisites that are required by the
131 # recursive rules.
132 #
133 # NOTE: You can add prerequisties for the recursive rules but you cannot
134 # add any commands to run as part of the rule. You can define them
135 # and make will quietly ignore them and they will not be run either
136 # before or after the recursive rule.
137 #
138 jim.wunderlich 1.34 #
139 messages: rootbundle
|
140 karl 1.6
|
141 jim.wunderlich 1.34 depend: buildmu
|
142 kumpf 1.18
|
143 jim.wunderlich 1.34 #########################################################################
144 # This section defines combinational rules
145 #
|
146 jim.wunderlich 1.32 #-----------------------
|
147 jim.wunderlich 1.34 # build target: builds all source
|
148 jim.wunderlich 1.32 #
|
149 jim.wunderlich 1.34 build: depend all setupdevserver
|
150 jim.wunderlich 1.32
|
151 jim.wunderlich 1.34 #------------------------
152 # rebuild target is being deprecated instead use "make new build"
153 #
154 rebuild_msg: FORCE
155 @$(ECHO) "==============================================================================="
156 @$(ECHO) "Makefile: The rebuild target is being deprecated."
157 @$(ECHO) " Use \"make usage\" for a description of the usage model."
158 @$(ECHO) " Consider using \"make new smallworld\" ."
159 @$(ECHO) " Invoking the old rebuild rule now."
160 @$(ECHO) "==============================================================================="
161
162 rebuild: rebuild_msg shortsleep new build s_unittests repository
|
163 jim.wunderlich 1.32
164 #-----------------------
|
165 jim.wunderlich 1.34 # new target: cleans everthing
166 #
167 # This can be combined on the command line with other rules like:
|
168 jim.wunderlich 1.32 #
|
169 jim.wunderlich 1.34 # make new build
170 # make new world
|
171 jim.wunderlich 1.32
|
172 jim.wunderlich 1.34 new: clean repositoryclean
|
173 jim.wunderlich 1.32
174 #-----------------------
|
175 jim.wunderlich 1.34 # world targets: builds everything and dependent on which target may do testing
|
176 jim.wunderlich 1.32 #
177 # Typically used after a fresh checkout from CVS
|
178 jim.wunderlich 1.34
179 smallworld: build s_unittests serverquicktests
180
181 world: build s_unittests servertests
182
183
184 ############################
185 #
186 # rules defined in TestMakefile that are repeated here for convenience
|
187 jim.wunderlich 1.32 #
|
188 jim.wunderlich 1.34 shortsleep: FORCE
189 @$(MAKE) -f TestMakefile shortsleep
190
191 servertests: FORCE
192 @ $(MAKE) -f TestMakefile servertests
193
194 s_unittests: FORCE
195 @ $(MAKE) -f TestMakefile -s unittests
196
197 unittests: FORCE
198 @ $(MAKE) -f TestMakefile unittests
199
200 standardtests: FORCE
201 @ $(MAKE) -f TestMakefile standardtests
202
203 serverquicktests: FORCE
204 @ $(MAKE) -f TestMakefile serverquicktests
205
206 alltests: FORCE
207 @ $(MAKE) -f TestMakefile alltests
208
209 jim.wunderlich 1.34 testusage: FORCE
210 @ $(MAKE) -f TestMakefile usage
|
211 jim.wunderlich 1.32
|
212 jim.wunderlich 1.34 testusage2: FORCE
213 @ $(MAKE) -f TestMakefile usage2
|
214 mike 1.1
|
215 jim.wunderlich 1.34
216 ##########################################################################
217 #
218 # This section defines functional rules
219 #
|
220 jim.wunderlich 1.32 #---------------------
221 # buildmu target: build mu the make utility that among other things
222 # includes depend
223 buildmu: FORCE
224 $(MKDIRHIER) $(BIN_DIR)
225 $(MAKE) --directory=$(PEGASUS_ROOT)/src/utils/mu -f Makefile
226
227 #----------------------
228 # setupdevserver and cleandevserver are used to setup and clear the
229 # server configuration files needed to run the server in a development
230 # environment.
231 #
232 setupdevserver: FORCE
233 $(MAKE) --directory=$(PEGASUS_ROOT)/src/Server -f Makefile install_run
234 @$(ECHO) "PEGASUS Development Server Runtime Environment configured "
235
236 cleandevserver: FORCE
237 $(MAKE) --directory=$(PEGASUS_ROOT)/src/Server -f Makefile install_run_clean
|
238 karl 1.6
|
239 jim.wunderlich 1.34
240 #---------------------
|
241 karl 1.6 # The repository Target removes and rebuilds the CIM repository
|
242 mike 1.4
|
243 kumpf 1.25 # Note: Arguments must be quoted to preserve upper case characters in VMS.
|
244 kumpf 1.18 repository: FORCE
|
245 kumpf 1.25 @ $(MAKE) "-SC" Schemas/Pegasus repository
|
246 mike 1.9
|
247 jim.wunderlich 1.29 repositoryclean: FORCE
248 @ $(RMREPOSITORY) $(REPOSITORY_ROOT)
249
|
250 kumpf 1.18 repositoryServer: FORCE
|
251 kumpf 1.25 @ $(MAKE) "-SC" Schemas/Pegasus repositoryServer
|
252 kumpf 1.17
|
253 kumpf 1.18 testrepository: FORCE
|
254 kumpf 1.25 @ $(MAKE) "-SC" src/Providers/sample/Load repository
255 @ $(MAKE) "-SC" test/wetest repository
256 @ $(MAKE) "-SC" src/Clients/benchmarkTest/Load repository
|
257 chuck 1.26 @ $(MAKE) "-SC" src/Pegasus/CQL/CQLCLI repository
|
258 chuck 1.27 @ $(MAKE) "-SC" src/Pegasus/Query/QueryExpression/tests repository
|
259 kumpf 1.28 @ $(MAKE) "-SC" src/Providers/TestProviders/Load repository
|
260 a.arora 1.30 @ $(MAKE) "-SC" src/Pegasus/ControlProviders/QueryCapabilitiesProvider/tests repository
|
261 kumpf 1.17
|
262 kumpf 1.18 testrepositoryServer: FORCE
|
263 kumpf 1.25 @ $(MAKE) "-SC" src/Providers/sample/Load repositoryServer
264 @ $(MAKE) "-SC" test/wetest repositoryServer
265 @ $(MAKE) "-SC" src/Clients/benchmarkTest/Load repositoryServer
|
266 chuck 1.26 @ $(MAKE) "-SC" src/Pegasus/CQL/CQLCLI repositoryServer
|
267 chuck 1.27 @ $(MAKE) "-SC" src/Pegasus/Query/QueryExpression/tests repositoryServer
|
268 kumpf 1.28 @ $(MAKE) "-SC" src/Providers/TestProviders/Load repositoryServer
|
269 a.arora 1.30 @ $(MAKE) "-SC" src/Pegasus/ControlProviders/QueryCapabilitiesProvider/tests repositoryServer
|
270 kumpf 1.16
|
271 kumpf 1.18 removetestrepository: FORCE
|
272 kumpf 1.25 @ $(MAKE) "-SC" src/Providers/sample/Load removerepository
273 @ $(MAKE) "-SC" test/wetest removerepository
274 @ $(MAKE) "-SC" src/Clients/benchmarkTest/Load removerepository
|
275 kumpf 1.28 @ $(MAKE) "-SC" src/Providers/TestProviders/Load removerepository
|
276 karl 1.15
|
277 konrad.r 1.24 config:
278 @ $(ROOT)/SetConfig_EnvVar
279
|
280 humberto 1.21 rootbundle:
281 $(MAKE) --directory=$(PEGASUS_ROOT)/src/utils/cnv2rootbundle -f Makefile
282
|
283 jim.wunderlich 1.34
|