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