first draft of the onelab distro
[build.git] / planetlab.mk
1 #
2 # PlanetLab standard components list
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 # see doc in Makefile  
11 #
12
13 #
14 # kernel
15 #
16 # use a package name with srpm in it:
17 # so the source rpm is created by running make srpm in the codebase
18 #
19
20 kernel-MODULES := linux-patches
21 kernel-SPEC := kernel-2.6.spec
22 kernel-BUILD-FROM-SRPM := yes
23 ifeq "$(HOSTARCH)" "i386"
24 kernel-RPMFLAGS:= --target i686
25 else
26 kernel-RPMFLAGS:= --target $(HOSTARCH)
27 endif
28 KERNELS += kernel
29
30 kernels: $(KERNELS)
31 kernels-clean: $(foreach package,$(KERNELS),$(package)-clean)
32
33 ALL += $(KERNELS)
34 # this is to mark on which image a given rpm is supposed to go
35 IN_BOOTCD += $(KERNELS)
36 IN_VSERVER += $(KERNELS)
37 IN_BOOTSTRAPFS += $(KERNELS)
38 # turns out myplc installs kernel-vserver
39 IN_MYPLC += $(KERNELS)
40
41 #
42 # kexec-tools
43 #
44 ifeq "$(DISTRO)" "Fedora"
45 ifeq "$(RELEASE)" "4"
46 kexec-tools-MODULES := kexec-tools
47 kexec-tools-SPEC := kexec-tools.spec
48 kexec-tools-CVSROOT := :pserver:anon@cvs.planet-lab.org:/cvs
49 kexec-tools-TAG := planetlab-4_1-rc2
50 ALL += kexec-tools
51 IN_BOOTCD += kexec-tools
52 endif
53 endif
54
55 #
56 # madwifi
57 #
58 madwifi-MODULES := madwifi
59 madwifi-SPEC := madwifi.spec
60 madwifi-BUILD-FROM-SRPM := yes
61 madwifi-DEPEND-DEVEL-RPMS := kernel-devel
62 madwifi-SPECVARS = kernel_version=$(kernel.rpm-version) \
63         kernel_release=$(kernel.rpm-release) \
64         kernel_arch=$(kernel.rpm-arch)
65 ALL += madwifi
66 IN_BOOTSTRAPFS += madwifi
67
68 #
69 # wireless-tools
70
71 wireless-tools-MODULES := wireless-tools
72 wireless-tools-SPEC := wireless-tools.spec
73 wireless-tools-BUILD-FROM-SRPM := yes
74 ALL += wireless-tools
75 IN_BOOTSTRAPFS += wireless-tools
76
77 #
78 # libnl
79 #
80 # [daniel]    wait for latest Fedora release 
81 # (03:29:46 PM) daniel_hozac: interfacing with the kernel directly when dealing with netlink was fugly, so... i had to find something nicer.
82 # (03:29:53 PM) daniel_hozac: the one in Fedora is lacking certain APIs i need.
83 #
84 libnl-MODULES := libnl
85 libnl-SPEC := libnl.spec
86 ALL += libnl
87
88 #
89 # util-vserver
90 #
91 util-vserver-MODULES := util-vserver
92 util-vserver-SPEC := util-vserver.spec
93 util-vserver-RPMFLAGS:= --without dietlibc
94 ALL += util-vserver
95 IN_BOOTSTRAPFS += util-vserver
96
97 #
98 # util-vserver-pl
99 #
100 util-vserver-pl-MODULES := util-vserver-pl
101 util-vserver-pl-SPEC := util-vserver-pl.spec
102 util-vserver-pl-DEPEND-DEVEL-RPMS := libnl libnl-devel util-vserver-lib util-vserver-devel util-vserver-core
103 ALL += util-vserver-pl
104 IN_BOOTSTRAPFS += util-vserver-pl
105
106 #
107 # NodeUpdate
108 #
109 NodeUpdate-MODULES := NodeUpdate
110 NodeUpdate-SPEC := NodeUpdate.spec
111 ALL += NodeUpdate
112 IN_BOOTSTRAPFS += NodeUpdate
113
114 #
115 # ipod
116 #
117 ipod-MODULES := PingOfDeath
118 ipod-SPEC := ipod.spec
119 ALL += ipod
120 IN_BOOTSTRAPFS += ipod
121
122 #
123 # NodeManager
124 #
125 NodeManager-MODULES := NodeManager
126 NodeManager-SPEC := NodeManager.spec
127 ALL += NodeManager
128 IN_BOOTSTRAPFS += NodeManager
129
130 #
131 # pl_sshd
132 #
133 pl_sshd-MODULES := pl_sshd
134 pl_sshd-SPEC := pl_sshd.spec
135 ALL += pl_sshd
136 IN_BOOTSTRAPFS += pl_sshd
137
138 #
139 # libhttpd++: 
140 #
141 # Deprecate when vsys takes over [sapan].
142 # keep in build for proper.
143 #
144 libhttpd-MODULES := libhttpd++
145 libhttpd-SPEC := libhttpd++.spec
146 ALL += libhttpd
147 IN_BOOTSTRAPFS += libhttpd
148
149 #
150 # proper: Privileged Operations Service
151 #
152 proper-MODULES := proper
153 proper-SPEC := proper.spec
154 proper-DEPEND-DEVEL-RPMS := libhttpd++-devel
155 ALL += proper
156 IN_BOOTSTRAPFS += proper
157
158 #
159 # codemux: Port 80 demux
160 #
161 codemux-MODULES := CoDemux
162 codemux-SPEC   := codemux.spec
163 codemux-RPMBUILD := sudo bash ./rpmbuild.sh
164 ALL += codemux
165 IN_BOOTSTRAPFS += codemux
166
167 #
168 # ulogd
169 #
170 ulogd-MODULES := ulogd
171 ulogd-SPEC := ulogd.spec
172 ulogd-DEPEND-DEVEL-RPMS := kernel-devel proper-libs proper-devel
173 ALL += ulogd
174 IN_VSERVER += ulogd
175
176 #
177 # fprobe-ulog
178 #
179 fprobe-ulog-MODULES := fprobe-ulog
180 fprobe-ulog-SPEC := fprobe-ulog.spec
181 ALL += fprobe-ulog
182 IN_BOOTSTRAPFS += fprobe-ulog
183
184 #
185 # netflow
186 #
187 netflow-MODULES := PlanetFlow
188 netflow-SPEC := netflow.spec
189 ALL += netflow
190 IN_BOOTSTRAPFS += netflow
191
192 #
193 # PlanetLab Mom: Cleans up your mess
194 #
195 pl_mom-MODULES := Mom
196 pl_mom-SPEC := pl_mom.spec
197 ALL += pl_mom
198 IN_BOOTSTRAPFS += pl_mom
199
200 #
201 # iptables
202 #
203 iptables-MODULES := iptables
204 iptables-SPEC := iptables.spec
205 iptables-DEPEND-DEVEL-RPMS := kernel-devel
206 ALL += iptables
207 IN_BOOTSTRAPFS += iptables
208
209 #
210 # iproute
211 #
212 iproute-MODULES := iproute2
213 iproute-SPEC := iproute.spec
214 ALL += iproute
215 IN_BOOTSTRAPFS += iproute
216
217 #
218 # vsys
219 #
220 vsys-MODULES := vsys
221 vsys-SPEC := vsys.spec
222 ifeq "$(DISTRO)" "Fedora"
223 ifeq "$(RELEASE)" "7"
224 ALL += vsys
225 endif
226 ifeq "$(RELEASE)" "8"
227 ALL += vsys
228 endif
229 endif
230
231 #
232 # PLCAPI
233 #
234 PLCAPI-MODULES := PLCAPI
235 PLCAPI-SPEC := PLCAPI.spec
236 ALL += PLCAPI
237 IN_MYPLC += PLCAPI
238
239 #
240 # PLCWWW
241 #
242 PLCWWW-MODULES := WWW
243 PLCWWW-SPEC := PLCWWW.spec
244 ALL += PLCWWW
245 IN_MYPLC += PLCWWW
246
247 #
248 # bootmanager
249 #
250 bootmanager-MODULES := BootManager
251 bootmanager-SPEC := bootmanager.spec
252 ALL += bootmanager
253 IN_MYPLC += bootmanager
254
255 #
256 # pypcilib : used in bootcd
257
258 pypcilib-MODULES := pypcilib
259 pypcilib-SPEC := pypcilib.spec
260 ALL += pypcilib
261 IN_BOOTCD += pypcilib
262
263 #
264 # bootcd
265 #
266 bootcd-MODULES := BootCD build
267 bootcd-SPEC := bootcd.spec
268 bootcd-RPMBUILD := sudo bash ./rpmbuild.sh
269 # package has *some* dependencies, at least these ones
270 bootcd-DEPEND-PACKAGES := $(IN_BOOTCD)
271 bootcd-DEPEND-FILES := RPMS/yumgroups.xml
272 ALL += bootcd
273 IN_MYPLC += bootcd
274
275 #
276 # vserver : reference image for slices
277 #
278 vserver-MODULES := VserverReference build
279 vserver-SPEC := vserver-reference.spec
280 # Package must be built as root
281 vserver-RPMBUILD := sudo bash ./rpmbuild.sh
282 # this list is useful for manual builds only, since nightly builds 
283 # always redo all sequentially - try to keep updated
284 vserver-DEPEND-PACKAGES := $(IN_VSERVER)
285 vserver-DEPEND-FILES := RPMS/yumgroups.xml
286 ALL += vserver
287 IN_BOOTSTRAPFS := vserver
288
289 #
290 # bootstrapfs
291 #
292 bootstrapfs-MODULES := BootstrapFS build
293 bootstrapfs-SPEC := bootstrapfs.spec
294 bootstrapfs-RPMBUILD := sudo bash ./rpmbuild.sh
295 # package requires all regular packages
296 bootstrapfs-DEPEND-PACKAGES := $(IN_BOOTSTRAPFS)
297 bootstrapfs-DEPEND-FILES := RPMS/yumgroups.xml
298 ALL += bootstrapfs
299 IN_MYPLC += bootstrapfs
300
301 #
302 # myplc : initial, chroot-based packaging
303 #
304 myplc-MODULES := MyPLC build
305 myplc-SPEC := myplc.spec
306 # Package must be built as root
307 myplc-RPMBUILD := sudo bash ./rpmbuild.sh
308 # myplc may require all packages
309 myplc-DEPEND-PACKAGES := $(IN_MYPLC)
310 myplc-DEPEND-FILES := RPMS/yumgroups.xml myplc-release
311 ALL += myplc
312
313 #
314 # MyPLC native : lightweight packaging, dependencies are yum-installed in a vserver
315 #
316 myplc-native-MODULES := MyPLC build 
317 myplc-native-SPEC := myplc-native.spec
318 # Package must be built as root
319 myplc-native-RPMBUILD := sudo bash ./rpmbuild.sh
320 # Thierry : don't depend on anything at build-time
321 #myplc-native-DEPEND-PACKAGES :=
322 # Thierry : dunno about this one, let's stay safe
323 myplc-native-DEPEND-FILES := myplc-release
324 ALL += myplc-native
325