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
14 # use a package name with srpm in it:
15 # so the source rpm is created by running make srpm in the codebase
18 kernel-MODULES := linux-2.6
19 kernel-SPEC := kernel-2.6.spec
20 kernel-BUILD-FROM-SRPM := yes
21 ifeq "$(HOSTARCH)" "i386"
22 kernel-RPMFLAGS:= --target i686
24 kernel-RPMFLAGS:= --target $(HOSTARCH)
26 kernel-SPECVARS += kernelconfig=planetlab
29 kernel-STOCK-DEVEL-RPMS += elfutils-libelf-devel
30 # help out spec2make on f8 and centos5, due to a bug in rpm
31 # ditto on f16 for spec2make.py - tmp hopefully
32 ifeq "$(DISTRONAME)" "$(filter $(DISTRONAME),f8 f16 centos5)"
33 kernel-WHITELIST-RPMS := kernel-devel,kernel-headers
37 kernels-clean: $(foreach package,$(KERNELS),$(package)-clean)
40 # this is to mark on which image a given rpm is supposed to go
41 IN_BOOTCD += $(KERNELS)
42 #IN_SLICEIMAGE += $(KERNELS)
43 IN_NODEIMAGE += $(KERNELS)
46 # ipfw: root context module, and slice companion
48 ipfwroot-MODULES := ipfw
49 ipfwroot-SPEC := planetlab/ipfwroot.spec
50 ipfwroot-LOCAL-DEVEL-RPMS += kernel-devel
51 ipfwroot-SPECVARS = kernel_version=$(kernel.rpm-version) \
52 kernel_release=$(kernel.rpm-release) \
53 kernel_arch=$(kernel.rpm-arch)
55 IN_NODEIMAGE += ipfwroot
57 ipfwslice-MODULES := ipfw
58 ipfwslice-SPEC := planetlab/ipfwslice.spec
64 # skip this with k32/f8
65 ifneq "" "$(findstring k32,$(PLDISTROTAGS))"
66 ifneq "$(DISTRONAME)" "f8"
67 madwifi-MODULES := madwifi
68 madwifi-SPEC := madwifi.spec
69 madwifi-BUILD-FROM-SRPM := yes
70 madwifi-LOCAL-DEVEL-RPMS += kernel-devel
71 madwifi-SPECVARS = kernel_version=$(kernel.rpm-version) \
72 kernel_release=$(kernel.rpm-release) \
73 kernel_arch=$(kernel.rpm-arch)
75 IN_NODEIMAGE += madwifi
82 comgt-MODULES := comgt
83 comgt-SPEC := comgt.spec
88 # umts: root context stuff
90 umts-backend-MODULES := planetlab-umts-tools
91 umts-backend-SPEC := backend.spec
92 IN_NODEIMAGE += umts-backend
98 umts-frontend-MODULES := planetlab-umts-tools
99 umts-frontend-SPEC := frontend.spec
100 IN_SLICEIMAGE += umts-frontend
106 iptables-MODULES := iptables
107 iptables-SPEC := iptables.spec
108 iptables-BUILD-FROM-SRPM := yes
109 iptables-LOCAL-DEVEL-RPMS += kernel-devel kernel-headers
111 IN_NODEIMAGE += iptables
114 # we use the stock iproute2 with 2.6.32, since our gre patch is not needed anymore with that kernel
115 # note that this should be consistently reflected in nodeyumexclude
119 # iproute-MODULES := iproute2
120 # iproute-SPEC := iproute.spec
121 # iproute-BUILD-FROM-SRPM := yes
123 # IN_NODEIMAGE += iproute
124 # IN_SLICEIMAGE += iproute
125 # IN_BOOTCD += iproute
130 util-vserver-MODULES := util-vserver
131 util-vserver-SPEC := util-vserver.spec
133 util-vserver-BUILD-FROM-SRPM := yes
134 util-vserver-RPMFLAGS:= --without dietlibc --without doc
136 IN_NODEIMAGE += util-vserver
139 # libnl - local import
140 # we need either 1.1 or at least 1.0.pre6
141 # rebuild this on centos5 - see yumexclude
144 ifeq "$(DISTRONAME)" "centos5"
148 ifeq "$(local_libnl)" "true"
149 libnl-MODULES := libnl
150 libnl-SPEC := libnl.spec
151 libnl-BUILD-FROM-SRPM := yes
152 # this sounds like the thing to do, but in fact linux/if_vlan.h comes with kernel-headers
153 libnl-LOCAL-DEVEL-RPMS += kernel-devel kernel-headers
155 IN_NODEIMAGE += libnl
161 util-vserver-pl-MODULES := util-vserver-pl
162 util-vserver-pl-SPEC := util-vserver-pl.spec
163 util-vserver-pl-LOCAL-DEVEL-RPMS += util-vserver-lib util-vserver-devel util-vserver-core
164 ifeq "$(local_libnl)" "true"
165 util-vserver-pl-LOCAL-DEVEL-RPMS += libnl libnl-devel
167 ALL += util-vserver-pl
168 IN_NODEIMAGE += util-vserver-pl
173 nodeupdate-MODULES := nodeupdate
174 nodeupdate-SPEC := NodeUpdate.spec
176 IN_NODEIMAGE += nodeupdate
181 ipod-MODULES := PingOfDeath
182 ipod-SPEC := ipod.spec
189 plnode-utils-MODULES := plnode-utils
190 plnode-utils-SPEC := plnode-utils-vs.spec
192 IN_NODEIMAGE += plnode-utils
197 nodemanager-MODULES := nodemanager
198 nodemanager-SPEC := nodemanager.spec
200 IN_NODEIMAGE += nodemanager
205 sshd-MODULES := pl_sshd
206 sshd-SPEC := pl_sshd.spec
211 # codemux: Port 80 demux
213 codemux-MODULES := codemux
214 codemux-SPEC := codemux.spec
216 IN_NODEIMAGE += codemux
221 fprobe-ulog-MODULES := fprobe-ulog
222 fprobe-ulog-SPEC := fprobe-ulog.spec
224 IN_NODEIMAGE += fprobe-ulog
227 # DistributedRateLimiting
229 # on f16 somehow configure screws up and defines LDFLAGS=-Wl,-z,relro which ld does not like..
230 ifneq "$(DISTRONAME)" "f16"
231 DistributedRateLimiting-MODULES := DistributedRateLimiting
232 DistributedRateLimiting-SPEC := DistributedRateLimiting.spec
233 ALL += DistributedRateLimiting
234 IN_NODEREPO += DistributedRateLimiting
240 pf2slice-MODULES := pf2slice
241 pf2slice-SPEC := pf2slice.spec
245 # PlanetLab Mom: Cleans up your mess
248 mom-SPEC := pl_mom.spec
253 # inotify-tools - local import
254 # rebuild this on centos5 (not found) - see yumexclude
256 local_inotify_tools=false
257 ifeq "$(DISTRONAME)" "centos5"
258 local_inotify_tools=true
261 ifeq "$(DISTRONAME)" "sl6"
262 local_inotify_tools=true
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_NODEIMAGE += inotify-tools
276 # openvswitch-MODULES := openvswitch
277 # openvswitch-SPEC := openvswitch.spec
278 # openvswitch-LOCAL-DEVEL-RPMS += kernel-devel
280 # ifeq "$(DISTRONAME)" "$(filter $(DISTRONAME),f14 f15 f16)"
281 # IN_NODEIMAGE += openvswitch
289 vsys-SPEC := vsys.spec
290 # ocaml-docs is not needed anymore but keep it on a tmp basis as some tags may still have it
291 vsys-STOCK-DEVEL-RPMS += ocaml-ocamldoc ocaml-docs
292 ifeq "$(local_inotify_tools)" "true"
293 vsys-LOCAL-DEVEL-RPMS += inotify-tools inotify-tools-devel
299 # vsyssh : installed in slivers
301 vsyssh-MODULES := vsys
302 vsyssh-SPEC := vsyssh.spec
303 IN_SLICEIMAGE += vsyssh
309 vsys-scripts-MODULES := vsys-scripts
310 vsys-scripts-SPEC := root-context/vsys-scripts.spec
311 IN_NODEIMAGE += vsys-scripts
314 vsys-wrapper-MODULES := vsys-scripts
315 vsys-wrapper-SPEC := slice-context/vsys-wrapper.spec
316 IN_SLICEIMAGE += vsys-wrapper
319 # openvswitch requires an autoconf more recent than what f12 has
320 ifeq "$(DISTRONAME)" "f12"
321 autoconf-MODULES := autoconf
322 autoconf-SPEC := autoconf.spec
323 autoconf-BUILD-FROM-SRPM := yes
330 bind_public-MODULES := bind_public
331 bind_public-SPEC := bind_public.spec
332 IN_SLICEIMAGE += bind_public
338 sliver-openvswitch-MODULES := sliver-openvswitch
339 sliver-openvswitch-SPEC := sliver-openvswitch.spec
340 ifeq "$(DISTRONAME)" "f12"
341 sliver-openvswitch-LOCAL-DEVEL-RPMS-CRUCIAL := autoconf
343 IN_SLICEIMAGE += sliver-openvswitch
344 ALL += sliver-openvswitch
349 plcapi-MODULES := plcapi
350 plcapi-SPEC := plcapi.spec
357 drupal-MODULES := drupal
358 drupal-SPEC := drupal.spec
359 drupal-BUILD-FROM-SRPM := yes
364 # use the plewww module instead
366 plewww-MODULES := plewww
367 plewww-SPEC := plewww.spec
372 # www-register-wizard
374 www-register-wizard-MODULES := www-register-wizard
375 www-register-wizard-SPEC := www-register-wizard.spec
376 ALL += www-register-wizard
377 IN_MYPLC += www-register-wizard
382 pcucontrol-MODULES := pcucontrol
383 pcucontrol-SPEC := pcucontrol.spec
389 monitor-MODULES := monitor
390 monitor-SPEC := Monitor.spec
391 monitor-STOCK-DEVEL-RPMS += net-snmp net-snmp-devel
393 IN_NODEIMAGE += monitor
398 plcrt-MODULES := PLCRT
399 plcrt-SPEC := plcrt.spec
402 # f12 has 0.9-1 already
403 ifeq "$(DISTRONAME)" "$(filter $(DISTRONAME),f8 centos5)"
407 pyopenssl-MODULES := pyopenssl
408 pyopenssl-SPEC := pyOpenSSL.spec
409 pyopenssl-BUILD-FROM-SRPM := yes
416 pyaspects-MODULES := pyaspects
417 pyaspects-SPEC := pyaspects.spec
418 pyaspects-BUILD-FROM-SRPM := yes
424 nodeconfig-MODULES := nodeconfig
425 nodeconfig-SPEC := nodeconfig.spec
427 IN_MYPLC += nodeconfig
432 bootmanager-MODULES := bootmanager
433 bootmanager-SPEC := bootmanager.spec
435 IN_MYPLC += bootmanager
438 # pypcilib : used in bootcd
440 pypcilib-MODULES := pypcilib
441 pypcilib-SPEC := pypcilib.spec
443 IN_BOOTCD += pypcilib
448 pyplnet-MODULES := pyplnet
449 pyplnet-SPEC := pyplnet.spec
451 IN_NODEIMAGE += pyplnet
456 # for OMF resource controller as a gem : rvm-ruby has right version of ruby and related gem stuff
458 rvm-ruby-MODULES := rvm-ruby
459 rvm-ruby-SPEC := rpm/rvm-ruby.spec
460 rvm-ruby-STOCK-DEVEL-RPMS := chrpath libyaml-devel libffi-devel libxslt-devel
464 # OML measurement library
467 oml-STOCK-DEVEL-RPMS += sqlite-devel
468 oml-SPEC := liboml.spec
474 bootcd-MODULES := bootcd build
475 bootcd-SPEC := bootcd.spec
476 bootcd-DEPEND-PACKAGES := $(IN_BOOTCD)
477 bootcd-DEPEND-FILES := RPMS/yumgroups.xml
478 bootcd-RPMDATE := yes
485 sliceimage-MODULES := sliceimage build
486 sliceimage-SPEC := sliceimage.spec
487 sliceimage-DEPEND-PACKAGES := $(IN_SLICEIMAGE)
488 sliceimage-DEPEND-FILES := RPMS/yumgroups.xml
489 sliceimage-RPMDATE := yes
491 IN_NODEIMAGE += sliceimage
494 # vserver-specific sliceimage initialization
496 vserver-sliceimage-MODULES := sliceimage
497 vserver-sliceimage-SPEC := vserver-sliceimage.spec
498 vserver-sliceimage-RPMDATE := yes
499 ALL += vserver-sliceimage
500 IN_NODEIMAGE += vserver-sliceimage
505 nodeimage-MODULES := nodeimage build
506 nodeimage-SPEC := nodeimage.spec
507 nodeimage-DEPEND-PACKAGES := $(IN_NODEIMAGE)
508 nodeimage-DEPEND-FILES := RPMS/yumgroups.xml
509 nodeimage-RPMDATE := yes
511 IN_MYPLC += nodeimage
516 # all rpms resulting from packages marked as being in nodeimage and sliceimage
517 NODEREPO_RPMS = $(foreach package,$(IN_NODEIMAGE) $(IN_NODEREPO) $(IN_SLICEIMAGE),$($(package).rpms))
518 # replace space with +++ (specvars cannot deal with spaces)
520 NODEREPO_RPMS_3PLUS = $(subst $(SPACE),+++,$(NODEREPO_RPMS))
522 noderepo-MODULES := nodeimage
523 noderepo-SPEC := noderepo.spec
524 # package requires all embedded packages
525 noderepo-DEPEND-PACKAGES := $(IN_NODEIMAGE) $(IN_NODEREPO) $(IN_SLICEIMAGE)
526 noderepo-DEPEND-FILES := RPMS/yumgroups.xml
527 #export rpm list to the specfile
528 noderepo-SPECVARS = node_rpms_plus=$(NODEREPO_RPMS_3PLUS)
529 noderepo-RPMDATE := yes
536 # all rpms resulting from packages marked as being in vserver
537 SLICEREPO_RPMS = $(foreach package,$(IN_SLICEIMAGE),$($(package).rpms))
538 # replace space with +++ (specvars cannot deal with spaces)
540 SLICEREPO_RPMS_3PLUS = $(subst $(SPACE),+++,$(SLICEREPO_RPMS))
542 slicerepo-MODULES := nodeimage
543 slicerepo-SPEC := slicerepo.spec
544 # package requires all embedded packages
545 slicerepo-DEPEND-PACKAGES := $(IN_SLICEIMAGE)
546 slicerepo-DEPEND-FILES := RPMS/yumgroups.xml
547 #export rpm list to the specfile
548 slicerepo-SPECVARS = slice_rpms_plus=$(SLICEREPO_RPMS_3PLUS)
549 slicerepo-RPMDATE := yes
553 # MyPLC : lightweight packaging, dependencies are yum-installed in a vserver
555 myplc-MODULES := myplc
556 myplc-SPEC := myplc.spec
557 myplc-DEPEND-FILES := myplc-release RPMS/yumgroups.xml
560 # myplc-docs only contains docs for PLCAPI and NMAPI, but
561 # we still need to pull MyPLC, as it is where the specfile lies,
562 # together with the utility script docbook2drupal.sh
563 myplc-docs-MODULES := myplc plcapi nodemanager monitor
564 myplc-docs-SPEC := myplc-docs.spec
567 # using some other name than myplc-release, as this is a make target already
568 release-MODULES := myplc
569 release-SPEC := myplc-release.spec
570 release-RPMDATE := yes
573 ##############################
575 # sfa - Slice Facility Architecture