testing post-commit - final
[wextoolbox.git] / wextoolbox.mk
1 #
2 # declare the packages to be built and their dependencies
3 # initial version from Mark Huang
4 # Mark Huang <mlhuang@cs.princeton.edu>
5 # Copyright (C) 2003-2006 The Trustees of Princeton University
6 # rewritten by Thierry Parmentelat - INRIA Sophia Antipolis
7 #
8 # $Id$
9 #
10 ### NOTES on diffs with onelab
11 # 2.6.27 vs 2.6.22 - does not need iwlwifi exception anymore
12 # does not include:
13 # ipfw (might just work) - svn:ipfw
14 # ipfwslice - svn:ipfw
15 # nozomi (does not work on 2.6.27) svn:nozomi
16 # comgt - svn:comgt
17 # umts-backend - svn:planetlab-umts-tools
18 # umts-frontend - svn:planetlab-umts-tools
19 # dummynet_image - svn:dummynet_image
20
21 #
22 # see doc in Makefile  
23 #
24
25 #
26 # boost
27
28 # we rebuild this one only b/c f10 only has 1.34 and gnuradio needs >= 1.35
29 # this build is based on the f11 rpm, i.e. boost-1.37
30 #
31 boost-MODULES := boost
32 boost-SPEC := boost.spec
33 boost-BUILD-FROM-SRPM := yes
34 ALL += boost
35 IN_BOOTSTRAPFS += boost
36
37 #
38 # gnuradio
39 #
40 gnuradio-MODULES := gnuradio
41 gnuradio-SPEC := gnuradio.spec
42 gnuradio-BUILD-FROM-SRPM := yes
43 # boost-devel needs boost !
44 gnuradio-DEPEND-DEVEL-RPMS := boost boost-devel
45 ALL += gnuradio
46 IN_BOOTSTRAPFS += gnuradio
47
48 #
49 # bbn
50 #
51 bbn-MODULES := bbn_80211
52 bbn-SPEC := bbn_80211.spec
53 bbn-BUILD-FROM-SRPM := yes
54 bbn-DEPEND-DEVEL-RPMS := gnuradio gnuradio-devel boost boost-devel
55 ALL += bbn
56 IN_BOOTSTRAPFS += bbn
57
58 #
59 # crunchxml
60 #
61 crunchxml-MODULES := crunchxml
62 crunchxml-SPEC := crunchxml.spec
63 crunchxml-BUILD-FROM-SRPM := yes
64 ALL += crunchxml
65 IN_BOOTSTRAPFS += crunchxml
66
67 #
68 # spectools
69 #
70 spectools-MODULES := spectools
71 spectools-SPEC := spectools.spec
72 spectools-BUILD-FROM-SRPM := yes
73 ALL += spectools
74 IN_BOOTSTRAPFS += spectools
75
76 #
77 # sge
78 #
79 sge-MODULES := sge
80 sge-SPEC := sge.spec
81 sge-BUILD-FROM-SRPM := yes
82 # turning this off - current focus is on deploying the sge box separately from myplc
83 # packaging is still broken, and we're exploring a ready-t-o-use distro on centos
84 # ALL += sge
85 # IN_BOOTSTRAPFS += sge
86
87 #
88 # kernel
89 #
90 # use a package name with srpm in it:
91 # so the source rpm is created by running make srpm in the codebase
92 #
93
94 kernel-MODULES := linux-2.6
95 kernel-SPEC := kernel-2.6.spec
96 kernel-BUILD-FROM-SRPM := yes
97 ifeq "$(HOSTARCH)" "i386"
98 kernel-RPMFLAGS:= --target i686
99 else
100 kernel-RPMFLAGS:= --target $(HOSTARCH)
101 endif
102 ### not needed with 2.6.27 anymore
103 ### kernel-SPECVARS := iwlwifi=1
104 ### tmp
105 kernel-RPMDATE := yes
106 KERNELS += kernel
107
108 kernels: $(KERNELS)
109 kernels-clean: $(foreach package,$(KERNELS),$(package)-clean)
110
111 ALL += $(KERNELS)
112 # this is to mark on which image a given rpm is supposed to go
113 IN_BOOTCD += $(KERNELS)
114 IN_VSERVER += $(KERNELS)
115 IN_BOOTSTRAPFS += $(KERNELS)
116 # turns out myplc installs kernel-vserver
117 IN_MYPLC += $(KERNELS)
118
119 #
120 # madwifi
121 #
122 madwifi-MODULES := madwifi
123 madwifi-SPEC := madwifi.spec
124 madwifi-BUILD-FROM-SRPM := yes
125 madwifi-DEPEND-DEVEL-RPMS := kernel-devel
126 madwifi-SPECVARS = kernel_version=$(kernel.rpm-version) \
127         kernel_release=$(kernel.rpm-release) \
128         kernel_arch=$(kernel.rpm-arch)
129 ALL += madwifi
130 IN_BOOTSTRAPFS += madwifi
131
132 #
133 # util-vserver
134 #
135 util-vserver-MODULES := util-vserver
136 util-vserver-SPEC := util-vserver.spec
137 util-vserver-RPMFLAGS:= --without dietlibc
138 ALL += util-vserver
139 IN_BOOTSTRAPFS += util-vserver
140
141 #
142 # libnl - local import
143 # we need either 1.1 or at least 1.0.pre6
144 # rebuild this on centos5 - see kexcludes in build.common
145 #
146 local_libnl=false
147 ifeq "$(DISTRONAME)" "centos5"
148 local_libnl=true
149 endif
150
151 ifeq "$(local_libnl)" "true"
152 libnl-MODULES := libnl
153 libnl-SPEC := libnl.spec
154 libnl-BUILD-FROM-SRPM := yes
155 # this sounds like the thing to do, but in fact linux/if_vlan.h comes with kernel-headers
156 libnl-DEPEND-DEVEL-RPMS := kernel-devel kernel-headers
157 ALL += libnl
158 IN_BOOTSTRAPFS += libnl
159 endif
160
161 #
162 # util-vserver-pl
163 #
164 util-vserver-pl-MODULES := util-vserver-pl
165 util-vserver-pl-SPEC := util-vserver-pl.spec
166 util-vserver-pl-DEPEND-DEVEL-RPMS := util-vserver-lib util-vserver-devel util-vserver-core 
167 ifeq "$(local_libnl)" "true"
168 util-vserver-pl-DEPEND-DEVEL-RPMS += libnl libnl-devel
169 endif
170 ALL += util-vserver-pl
171 IN_BOOTSTRAPFS += util-vserver-pl
172
173 #
174 # NodeUpdate
175 #
176 nodeupdate-MODULES := NodeUpdate
177 nodeupdate-SPEC := NodeUpdate.spec
178 ALL += nodeupdate
179 IN_BOOTSTRAPFS += nodeupdate
180
181 #
182 # ipod
183 #
184 ipod-MODULES := PingOfDeath
185 ipod-SPEC := ipod.spec
186 ALL += ipod
187 IN_BOOTSTRAPFS += ipod
188
189 #
190 # NodeManager
191 #
192 nodemanager-MODULES := NodeManager
193 nodemanager-SPEC := NodeManager.spec
194 ALL += nodemanager
195 IN_BOOTSTRAPFS += nodemanager
196
197 #
198 # pl_sshd
199 #
200 sshd-MODULES := pl_sshd
201 sshd-SPEC := pl_sshd.spec
202 ALL += sshd
203 IN_BOOTSTRAPFS += sshd
204
205 #
206 # codemux: Port 80 demux
207 #
208 codemux-MODULES := CoDemux
209 codemux-SPEC   := codemux.spec
210 codemux-RPMBUILD := sudo bash ./rpmbuild.sh
211 ALL += codemux
212 IN_BOOTSTRAPFS += codemux
213
214 #
215 # fprobe-ulog
216 #
217 fprobe-ulog-MODULES := fprobe-ulog
218 fprobe-ulog-SPEC := fprobe-ulog.spec
219 ALL += fprobe-ulog
220 IN_BOOTSTRAPFS += fprobe-ulog
221
222 #
223 # pf2slice
224 #
225 pf2slice-MODULES := pf2slice
226 pf2slice-SPEC := pf2slice.spec
227 ALL += pf2slice
228
229 #
230 # PlanetLab Mom: Cleans up your mess
231 #
232 mom-MODULES := Mom
233 mom-SPEC := pl_mom.spec
234 ALL += mom
235 IN_BOOTSTRAPFS += mom
236
237 #
238 # iptables
239 #
240 iptables-MODULES := iptables
241 iptables-SPEC := iptables.spec
242 iptables-DEPEND-DEVEL-RPMS := kernel-devel kernel-headers
243 ALL += iptables
244 IN_BOOTSTRAPFS += iptables
245
246 #
247 # iproute
248 #
249 iproute-MODULES := iproute2
250 iproute-SPEC := iproute.spec
251 ALL += iproute
252 IN_BOOTSTRAPFS += iproute
253 IN_VSERVER += iproute
254 IN_BOOTCD += iproute
255
256 #
257 # inotify-tools - local import
258 # rebuild this on centos5 (not found) - see kexcludes in build.common
259 #
260 local_inotify_tools=false
261 ifeq "$(DISTRONAME)" "centos5"
262 local_inotify_tools=true
263 endif
264
265 ifeq "$(local_inotify_tools)" "true"
266 inotify-tools-MODULES := inotify-tools
267 inotify-tools-SPEC := inotify-tools.spec
268 inotify-tools-BUILD-FROM-SRPM := yes
269 IN_BOOTSTRAPFS += inotify-tools
270 ALL += inotify-tools
271 endif
272
273 #
274 # vsys
275 #
276 vsys-MODULES := vsys
277 vsys-SPEC := vsys.spec
278 ifeq "$(local_inotify_tools)" "true"
279 vsys-DEPEND-DEVEL-RPMS := inotify-tools inotify-tools-devel
280 endif
281 IN_BOOTSTRAPFS += vsys
282 ALL += vsys
283
284 #
285 # vsys-scripts
286 #
287 vsys-scripts-MODULES := vsys-scripts
288 vsys-scripts-SPEC := vsys-scripts.spec
289 IN_BOOTSTRAPFS += vsys-scripts
290 ALL += vsys-scripts
291
292 #
293 # PLCAPI
294 #
295 PLCAPI-MODULES := PLCAPI
296 PLCAPI-SPEC := PLCAPI.spec
297 ALL += PLCAPI
298 IN_MYPLC += PLCAPI
299
300 #
301 # drupal
302
303 drupal-MODULES := drupal
304 drupal-SPEC := drupal.spec
305 drupal-BUILD-FROM-SRPM := yes
306 ALL += drupal
307 IN_MYPLC += drupal
308
309 #
310 # use the plewww module instead
311 #
312 plewww-MODULES := PLEWWW
313 plewww-SPEC := plewww.spec
314 ALL += plewww
315 IN_MYPLC += plewww
316
317 #
318 # www-register-wizard
319 #
320 www-register-wizard-MODULES := www-register-wizard
321 www-register-wizard-SPEC := www-register-wizard.spec
322 ALL += www-register-wizard
323 IN_MYPLC += www-register-wizard
324
325 #
326 # monitor
327 #
328 monitor-MODULES := Monitor
329 monitor-SPEC := Monitor.spec
330 ALL += monitor
331 IN_BOOTSTRAPFS += monitor
332
333 #
334 # PLC RT
335 #
336 plcrt-MODULES := PLCRT
337 plcrt-SPEC := plcrt.spec
338 ALL += plcrt
339
340 #
341 # zabbix
342 #
343 zabbix-MODULES := Monitor
344 zabbix-SPEC := zabbix.spec
345 zabbix-BUILD-FROM-SRPM := yes
346 ALL += zabbix
347
348 #
349 # pyopenssl
350 #
351 pyopenssl-MODULES := pyopenssl
352 pyopenssl-SPEC := pyOpenSSL.spec
353 pyopenssl-BUILD-FROM-SRPM := yes
354 ALL += pyopenssl
355
356
357 #
358 # sfa - Slice Facility Architecture
359 #
360 sfa-MODULES := sfa
361 sfa-SPEC := sfa.spec
362 ALL += sfa
363
364 #
365 # nodeconfig
366 #
367 nodeconfig-MODULES := nodeconfig build
368 nodeconfig-SPEC := nodeconfig.spec
369 ALL += nodeconfig
370 IN_MYPLC += nodeconfig
371
372 #
373 # bootmanager
374 #
375 bootmanager-MODULES := BootManager
376 bootmanager-SPEC := bootmanager.spec
377 ALL += bootmanager
378 IN_MYPLC += bootmanager
379
380 #
381 # pypcilib : used in bootcd
382
383 pypcilib-MODULES := pypcilib
384 pypcilib-SPEC := pypcilib.spec
385 ALL += pypcilib
386 IN_BOOTCD += pypcilib
387
388 #
389 # pyplnet
390 #
391 pyplnet-MODULES := pyplnet
392 pyplnet-SPEC := pyplnet.spec
393 ALL += pyplnet
394 IN_BOOTSTRAPFS += pyplnet
395 IN_MYPLC += pyplnet
396 IN_BOOTCD += pyplnet
397
398 #
399 # bootcd
400 #
401 bootcd-MODULES := BootCD build
402 bootcd-SPEC := bootcd.spec
403 bootcd-RPMBUILD := sudo bash ./rpmbuild.sh
404 bootcd-DEPEND-PACKAGES := $(IN_BOOTCD)
405 bootcd-DEPEND-FILES := RPMS/yumgroups.xml
406 bootcd-RPMDATE := yes
407 ALL += bootcd
408 IN_MYPLC += bootcd
409
410 #
411 # vserver : reference image for slices
412 #
413 vserver-MODULES := VserverReference build
414 vserver-SPEC := vserver-reference.spec
415 vserver-DEPEND-PACKAGES := $(IN_VSERVER)
416 vserver-DEPEND-FILES := RPMS/yumgroups.xml
417 vserver-RPMDATE := yes
418 ALL += vserver
419 IN_BOOTSTRAPFS += vserver
420
421 #
422 # bootstrapfs
423 #
424 bootstrapfs-MODULES := BootstrapFS build
425 bootstrapfs-SPEC := bootstrapfs.spec
426 bootstrapfs-RPMBUILD := sudo bash ./rpmbuild.sh
427 bootstrapfs-DEPEND-PACKAGES := $(IN_BOOTSTRAPFS)
428 bootstrapfs-DEPEND-FILES := RPMS/yumgroups.xml
429 bootstrapfs-RPMDATE := yes
430 ALL += bootstrapfs
431 IN_MYPLC += bootstrapfs
432
433 #
434 # noderepo
435 #
436 # all rpms resulting from packages marked as being in bootstrapfs and vserver
437 NODEREPO_RPMS = $(foreach package,$(IN_BOOTSTRAPFS) $(IN_VSERVER),$($(package).rpms))
438 # replace space with +++ (specvars cannot deal with spaces)
439 SPACE=$(subst x, ,x)
440 NODEREPO_RPMS_3PLUS = $(subst $(SPACE),+++,$(NODEREPO_RPMS))
441
442 noderepo-MODULES := BootstrapFS 
443 noderepo-SPEC := noderepo.spec
444 noderepo-RPMBUILD := sudo bash ./rpmbuild.sh
445 # package requires all regular packages
446 noderepo-DEPEND-PACKAGES := $(IN_BOOTSTRAPFS) $(IN_VSERVER)
447 noderepo-DEPEND-FILES := RPMS/yumgroups.xml
448 #export rpm list to the specfile
449 noderepo-SPECVARS = node_rpms_plus=$(NODEREPO_RPMS_3PLUS)
450 noderepo-RPMDATE := yes
451 ALL += noderepo
452 IN_MYPLC += noderepo
453
454 #
455 # MyPLC : lightweight packaging, dependencies are yum-installed in a vserver
456 #
457 myplc-MODULES := MyPLC build 
458 myplc-SPEC := myplc.spec
459 myplc-DEPEND-FILES := myplc-release RPMS/yumgroups.xml
460 ALL += myplc
461
462 # myplc-docs only contains docs for PLCAPI and NMAPI, but
463 # we still need to pull MyPLC, as it is where the specfile lies, 
464 # together with the utility script docbook2drupal.sh
465 myplc-docs-MODULES := MyPLC PLCAPI NodeManager Monitor
466 myplc-docs-SPEC := myplc-docs.spec
467 ALL += myplc-docs
468
469 # using some other name than myplc-release, as this is a make target already
470 release-MODULES := MyPLC
471 release-SPEC := myplc-release.spec
472 release-RPMDATE := yes
473 ALL += release