use stock libvirt starting with fedora22
[build.git] / lxc.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 # see doc in Makefile  
9 #
10
11 ### the madwifi drivers ship with fedora16's kernel rpm
12
13 #
14 # lxc-userspace: scripts for entering containers
15 #
16 lxc-userspace-MODULES := lxc-userspace
17 lxc-userspace-SPEC := lxc-userspace.spec
18 ALL += lxc-userspace
19 IN_NODEIMAGE += lxc-userspace
20
21 #
22 #
23 # transforward: root context module for transparent port forwarding
24 #
25 transforward-MODULES := transforward
26 transforward-SPEC := transforward.spec
27 ALL += transforward
28 IN_NODEIMAGE += transforward
29
30 #
31 # procprotect: root context module for protecting against weaknesses in /proc
32 #
33 ### remove procprotect from the nodes on f20 and above, needs more work starting with 3.19
34 ifneq "$(DISTRONAME)" "$(filter $(DISTRONAME),f20 f21 f22)"
35 procprotect-MODULES := procprotect
36 procprotect-SPEC := procprotect.spec
37 ALL += procprotect
38 IN_NODEIMAGE += procprotect
39 endif
40
41 #
42 # ipfw: root context module, and slice companion
43 #
44 ipfwroot-MODULES := ipfw
45 ipfwroot-SPEC := planetlab/ipfwroot.spec
46 ALL += ipfwroot
47 IN_NODEIMAGE += ipfwroot
48
49 ipfwslice-MODULES := ipfw
50 ipfwslice-SPEC := planetlab/ipfwslice.spec
51 ALL += ipfwslice
52
53 #
54 # comgt - a companion to umts tools
55
56 comgt-MODULES := comgt
57 comgt-SPEC := comgt.spec
58 IN_NODEIMAGE += comgt
59 ALL += comgt
60
61 #
62 # umts: root context stuff
63 #
64 umts-backend-MODULES := planetlab-umts-tools
65 umts-backend-SPEC := backend.spec
66 IN_NODEIMAGE += umts-backend
67 ALL += umts-backend
68
69 #
70 # umts: slice tools
71 #
72 umts-frontend-MODULES := planetlab-umts-tools
73 umts-frontend-SPEC := frontend.spec
74 IN_SLICEIMAGE += umts-frontend
75 ALL += umts-frontend
76
77 #
78 # NodeUpdate
79 #
80 nodeupdate-MODULES := nodeupdate
81 nodeupdate-SPEC := NodeUpdate.spec
82 ALL += nodeupdate
83 IN_NODEIMAGE += nodeupdate
84
85 #
86 # ipod
87 #
88 ipod-MODULES := PingOfDeath
89 ipod-SPEC := ipod.spec
90 ALL += ipod
91 IN_NODEIMAGE += ipod
92
93 #
94 # plnode-utils
95
96 plnode-utils-MODULES := plnode-utils
97 plnode-utils-SPEC := plnode-utils-lxc.spec
98 ALL += plnode-utils
99 IN_NODEIMAGE += plnode-utils
100
101 #
102 # nodemanager
103 #
104 nodemanager-MODULES := nodemanager
105 nodemanager-SPEC := nodemanager.spec
106 ALL += nodemanager
107 IN_NODEIMAGE += nodemanager
108
109 #
110 # pl_sshd
111 #
112 sshd-MODULES := pl_sshd
113 sshd-SPEC := pl_sshd.spec
114 ALL += sshd
115 IN_NODEIMAGE += sshd
116
117 #
118 # codemux: Port 80 demux
119 #
120 codemux-MODULES := codemux
121 codemux-SPEC   := codemux.spec
122 ALL += codemux
123 IN_NODEIMAGE += codemux
124
125 #
126 # fprobe-ulog
127 #
128 # xxx temporarily turning this off on f20 and above
129 ifneq "$(DISTRONAME)" "$(filter $(DISTRONAME),f20 f21 f22)"
130 fprobe-ulog-MODULES := fprobe-ulog
131 fprobe-ulog-SPEC := fprobe-ulog.spec
132 ALL += fprobe-ulog
133 IN_NODEIMAGE += fprobe-ulog
134 endif
135
136 #################### libvirt version selection
137
138 # use fedora's libvirt starting with f22
139 ifneq "$(DISTRONAME)" "$(filter $(DISTRONAME),f18 f20 f21)"
140 local_libvirt=true
141 endif
142
143 #
144 # libvirt
145 #
146 ifeq "$(local_libvirt)" "true"
147
148 libvirt-MODULES := libvirt
149 libvirt-SPEC    := libvirt.spec
150 libvirt-BUILD-FROM-SRPM := yes
151 # The --without options are breaking spec2make : hard-wired in the specfile instead
152 libvirt-STOCK-DEVEL-RPMS += xhtml1-dtds
153 libvirt-STOCK-DEVEL-RPMS += libattr-devel augeas libpciaccess-devel yajl-devel 
154 libvirt-STOCK-DEVEL-RPMS += libpcap-devel radvd ebtables device-mapper-devel 
155 libvirt-STOCK-DEVEL-RPMS += ceph-devel numactl-devel libcap-ng-devel scrub 
156 # for 1.2.1 - first seen on f20, not sure for the other ones
157 libvirt-STOCK-DEVEL-RPMS += libblkid-devel glusterfs-api-devel glusterfs-devel
158 # strictly speaking fuse-devel is not required anymore but we might wish to turn fuse back on again in the future
159 libvirt-STOCK-DEVEL-RPMS += fuse-devel libssh2-devel dbus-devel numad 
160 libvirt-STOCK-DEVEL-RPMS += systemd-devel libnl3-devel iptables-services netcf-devel
161 # 1.2.11
162 libvirt-STOCK-DEVEL-RPMS += wireshark-devel
163 libvirt-STOCK-DEVEL-RPMS += ceph-devel-compat
164 ALL += libvirt
165 IN_NODEREPO += libvirt
166 IN_NODEIMAGE += libvirt
167
168 #
169 ## libvirt-python
170 #
171 libvirt-python-MODULES := libvirt-python
172 libvirt-python-SPEC    := libvirt-python.spec
173 libvirt-python-BUILD-FROM-SRPM := yes
174 libvirt-python-STOCK-DEVEL-RPMS += pm-utils
175 # for 1.2.11
176 libvirt-python-STOCK-DEVEL-RPMS += python-nose
177 # it would make sense to do something like this if we wanted to
178 # build against python3 as well, but for now I turned this feature off
179 # in libvirt-python
180 #ifeq "$(distro)" "Fedora"
181 #xxx if $(distrorelease) > 18
182 #libvirt-python-STOCK-DEVEL-RPMS += python3-devel python3-nose python3-lxml
183 #endif
184 #endif
185 libvirt-python-LOCAL-DEVEL-RPMS += libvirt-devel libvirt-docs libvirt-client
186 libvirt-python-RPMFLAGS :=     --define 'packager PlanetLab'
187 ALL += libvirt-python
188 IN_NODEREPO += libvirt-python
189 IN_NODEIMAGE += libvirt-python
190
191 endif # local_libvirt
192
193 #
194 # DistributedRateLimiting
195 #
196 #DistributedRateLimiting-MODULES := DistributedRateLimiting
197 #DistributedRateLimiting-SPEC := DistributedRateLimiting.spec
198 #ALL += DistributedRateLimiting
199 #IN_NODEREPO += DistributedRateLimiting
200
201 #
202 # pf2slice
203 #
204 pf2slice-MODULES := pf2slice
205 pf2slice-SPEC := pf2slice.spec
206 ALL += pf2slice
207
208 ##
209 ## PlanetLab Mom: Cleans up your mess
210 ##
211 #mom-MODULES := mom
212 #mom-SPEC := pl_mom.spec
213 #ALL += mom
214 #IN_NODEIMAGE += mom
215
216 #
217 # openvswitch
218 #
219 # openvswitch-MODULES := openvswitch
220 # openvswitch-SPEC := openvswitch.spec
221 # openvswitch-STOCK-DEVEL-RPMS += kernel-devel
222 # IN_NODEIMAGE += openvswitch
223 # # build only on f14 as f16 has this natively
224 # ifeq "$(DISTRONAME)" "$(filter $(DISTRONAME),f14)"
225 # ALL += openvswitch
226 # endif
227
228 #
229 # vsys
230 #
231 vsys-MODULES := vsys
232 vsys-SPEC := vsys.spec
233 # ocaml-docs is not needed anymore but keep it on a tmp basis as some tags may still have it
234 vsys-STOCK-DEVEL-RPMS += ocaml-ocamldoc ocaml-docs
235 IN_NODEIMAGE += vsys
236 ALL += vsys
237
238 #
239 # vsyssh : installed in slivers
240 #
241 vsyssh-MODULES := vsys
242 vsyssh-SPEC := vsyssh.spec
243 IN_SLICEIMAGE += vsyssh
244 ALL += vsyssh
245
246 #
247 # vsys-scripts
248 #
249 vsys-scripts-MODULES := vsys-scripts
250 vsys-scripts-SPEC := root-context/vsys-scripts.spec
251 IN_NODEIMAGE += vsys-scripts
252 ALL += vsys-scripts
253
254 vsys-wrapper-MODULES := vsys-scripts
255 vsys-wrapper-SPEC := slice-context/vsys-wrapper.spec
256 IN_SLICEIMAGE += vsys-wrapper
257 ALL += vsys-wrapper
258
259 #
260 # bind_public
261 #
262 bind_public-MODULES := bind_public
263 bind_public-SPEC := bind_public.spec
264 IN_SLICEIMAGE += bind_public
265 ALL += bind_public
266
267 #
268 # sliver-openvswitch
269 #
270 sliver-openvswitch-MODULES := sliver-openvswitch
271 sliver-openvswitch-SPEC := sliver-openvswitch.spec
272 IN_SLICEIMAGE += sliver-openvswitch
273 ALL += sliver-openvswitch
274
275 #
276 # plcapi
277 #
278 plcapi-MODULES := plcapi
279 plcapi-SPEC := plcapi.spec
280 ALL += plcapi
281 IN_MYPLC += plcapi
282
283 #
284 # drupal
285
286 drupal-MODULES := drupal
287 drupal-SPEC := drupal.spec
288 drupal-BUILD-FROM-SRPM := yes
289 ALL += drupal
290 IN_MYPLC += drupal
291
292 #
293 # use the plewww module instead
294 #
295 plewww-MODULES := plewww
296 plewww-SPEC := plewww.spec
297 ALL += plewww
298 IN_MYPLC += plewww
299
300 #
301 # www-register-wizard
302 #
303 www-register-wizard-MODULES := www-register-wizard
304 www-register-wizard-SPEC := www-register-wizard.spec
305 ALL += www-register-wizard
306 IN_MYPLC += www-register-wizard
307
308 #
309 # pcucontrol
310 #
311 pcucontrol-MODULES := pcucontrol
312 pcucontrol-SPEC := pcucontrol.spec
313 ALL += pcucontrol
314
315 #
316 # monitor
317 #
318 #monitor-MODULES := monitor
319 #monitor-SPEC := Monitor.spec
320 #monitor-STOCK-DEVEL-RPMS += net-snmp net-snmp-devel
321 #ALL += monitor
322 #IN_NODEIMAGE += monitor
323
324 #
325 # PLC RT
326 #
327 plcrt-MODULES := PLCRT
328 plcrt-SPEC := plcrt.spec
329 ALL += plcrt
330
331 # f12 has 0.9-1 already
332 ifeq "$(DISTRONAME)" "$(filter $(DISTRONAME),f8 centos5)"
333 #
334 # pyopenssl
335 #
336 pyopenssl-MODULES := pyopenssl
337 pyopenssl-SPEC := pyOpenSSL.spec
338 pyopenssl-BUILD-FROM-SRPM := yes
339 ALL += pyopenssl
340 endif
341
342 #
343 # pyaspects
344 #
345 pyaspects-MODULES := pyaspects
346 pyaspects-SPEC := pyaspects.spec
347 pyaspects-BUILD-FROM-SRPM := yes
348 ALL += pyaspects
349
350 #
351 # nodeconfig
352 #
353 nodeconfig-MODULES := nodeconfig
354 nodeconfig-SPEC := nodeconfig.spec
355 ALL += nodeconfig
356 IN_MYPLC += nodeconfig
357
358 #
359 # bootmanager
360 #
361 bootmanager-MODULES := bootmanager
362 bootmanager-SPEC := bootmanager.spec
363 ALL += bootmanager
364 IN_MYPLC += bootmanager
365
366 #
367 # pypcilib : used in bootcd
368
369 pypcilib-MODULES := pypcilib
370 pypcilib-SPEC := pypcilib.spec
371 ALL += pypcilib
372 IN_BOOTCD += pypcilib
373
374 #
375 # pyplnet
376 #
377 pyplnet-MODULES := pyplnet
378 pyplnet-SPEC := pyplnet.spec
379 ALL += pyplnet
380 IN_NODEIMAGE += pyplnet
381 IN_MYPLC += pyplnet
382 IN_BOOTCD += pyplnet
383
384 #
385 # OML measurement library
386 #
387 oml-MODULES := oml
388 oml-STOCK-DEVEL-RPMS += sqlite-devel 
389 oml-SPEC := liboml.spec
390 ALL += oml
391
392 #
393 # bootcd
394 #
395 bootcd-MODULES := bootcd build
396 bootcd-SPEC := bootcd.spec
397 bootcd-DEPEND-PACKAGES := $(IN_BOOTCD)
398 bootcd-DEPEND-FILES := RPMS/yumgroups.xml
399 bootcd-RPMDATE := yes
400 ALL += bootcd
401 IN_MYPLC += bootcd
402
403 #
404 # images for slices
405 #
406 sliceimage-MODULES := sliceimage build
407 sliceimage-SPEC := sliceimage.spec
408 sliceimage-DEPEND-PACKAGES := $(IN_SLICEIMAGE)
409 sliceimage-DEPEND-FILES := RPMS/yumgroups.xml
410 sliceimage-RPMDATE := yes
411 ALL += sliceimage
412 IN_NODEIMAGE += sliceimage
413
414 #
415 # lxc-specific sliceimage initialization
416
417 lxc-sliceimage-MODULES  := sliceimage
418 lxc-sliceimage-SPEC     := lxc-sliceimage.spec
419 lxc-sliceimage-RPMDATE  := yes
420 ALL                     += lxc-sliceimage
421 IN_NODEIMAGE            += lxc-sliceimage
422
423 #
424 # nodeimage
425 #
426 nodeimage-MODULES := nodeimage build
427 nodeimage-SPEC := nodeimage.spec
428 nodeimage-DEPEND-PACKAGES := $(IN_NODEIMAGE)
429 nodeimage-DEPEND-FILES := RPMS/yumgroups.xml
430 nodeimage-RPMDATE := yes
431 ALL += nodeimage
432 IN_MYPLC += nodeimage
433
434 #
435 # noderepo
436 #
437 # all rpms resulting from packages marked as being in nodeimage and sliceimage
438 NODEREPO_RPMS = $(foreach package,$(IN_NODEIMAGE) $(IN_NODEREPO) $(IN_SLICEIMAGE),$($(package).rpms))
439 # replace space with +++ (specvars cannot deal with spaces)
440 SPACE=$(subst x, ,x)
441 NODEREPO_RPMS_3PLUS = $(subst $(SPACE),+++,$(NODEREPO_RPMS))
442
443 noderepo-MODULES := nodeimage
444 noderepo-SPEC := noderepo.spec
445 # package requires all embedded packages
446 noderepo-DEPEND-PACKAGES := $(IN_NODEIMAGE) $(IN_NODEREPO) $(IN_SLICEIMAGE)
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 # slicerepo
456 #
457 # all rpms resulting from packages marked as being in vserver
458 SLICEREPO_RPMS = $(foreach package,$(IN_SLICEIMAGE),$($(package).rpms))
459 # replace space with +++ (specvars cannot deal with spaces)
460 SPACE=$(subst x, ,x)
461 SLICEREPO_RPMS_3PLUS = $(subst $(SPACE),+++,$(SLICEREPO_RPMS))
462
463 slicerepo-MODULES := nodeimage
464 slicerepo-SPEC := slicerepo.spec
465 # package requires all embedded packages
466 slicerepo-DEPEND-PACKAGES := $(IN_SLICEIMAGE)
467 slicerepo-DEPEND-FILES := RPMS/yumgroups.xml
468 #export rpm list to the specfile
469 slicerepo-SPECVARS = slice_rpms_plus=$(SLICEREPO_RPMS_3PLUS)
470 slicerepo-RPMDATE := yes
471 ALL += slicerepo
472
473 #
474 # MyPLC : lightweight packaging, dependencies are yum-installed in a vserver
475 #
476 myplc-MODULES := myplc
477 myplc-SPEC := myplc.spec
478 myplc-DEPEND-FILES := myplc-release RPMS/yumgroups.xml
479 ALL += myplc
480
481 # myplc-docs only contains docs for PLCAPI and NMAPI, but
482 # we still need to pull MyPLC, as it is where the specfile lies, 
483 # together with the utility script docbook2drupal.sh
484 myplc-docs-MODULES := myplc plcapi nodemanager monitor
485 myplc-docs-SPEC := myplc-docs.spec
486 ALL += myplc-docs
487
488 # using some other name than myplc-release, as this is a make target already
489 release-MODULES := myplc
490 release-SPEC := myplc-release.spec
491 release-RPMDATE := yes
492 ALL += release
493
494 ##############################
495 #
496 # sfa - Slice Facility Architecture
497 #
498 sfa-MODULES := sfa
499 sfa-SPEC := sfa.spec
500 ALL += sfa