Patrick Williams | d849ec7 | 2016-08-17 14:59:38 -0500 | [diff] [blame] | 1 | DESCRIPTION = "Xen hypervisor" |
| 2 | HOMEPAGE = "http://xen.org" |
| 3 | LICENSE = "GPLv2" |
| 4 | SECTION = "console/tools" |
| 5 | |
| 6 | LIC_FILES_CHKSUM = "file://COPYING;md5=a6260c12cd5de27e80d89ae18e48d20a" |
| 7 | |
| 8 | COMPATIBLE_HOST = '(x86_64.*).*-linux|aarch64.*-linux' |
| 9 | |
| 10 | inherit autotools-brokensep gettext setuptools update-rc.d systemd deploy |
| 11 | |
| 12 | require xen-arch.inc |
| 13 | |
| 14 | PACKAGECONFIG ??= " \ |
| 15 | sdl \ |
| 16 | ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)} \ |
| 17 | ${@bb.utils.contains('XEN_TARGET_ARCH', 'x86_64', 'hvm', '', d)} \ |
| 18 | " |
| 19 | |
| 20 | FLASK_POLICY_FILE ?= "xenpolicy-${PV}" |
| 21 | |
| 22 | PACKAGECONFIG[sdl] = "--enable-sdl,--disable-sdl,virtual/libsdl," |
| 23 | PACKAGECONFIG[xsm] = "--enable-xsmpolicy,--disable-xsmpolicy,checkpolicy-native," |
| 24 | PACKAGECONFIG[systemd] = "--enable-systemd,--disable-systemd,systemd," |
| 25 | PACKAGECONFIG[hvm] = "--with-system-seabios="${STAGING_DIR_HOST}/usr/share/firmware/bios.bin",--disable-seabios,seabios ipxe vgabios," |
| 26 | |
| 27 | DEPENDS = " \ |
| 28 | bison-native \ |
| 29 | dev86-native \ |
| 30 | flex-native \ |
| 31 | file-native \ |
| 32 | iasl-native \ |
| 33 | util-linux-native \ |
| 34 | xz-native \ |
| 35 | bridge-utils \ |
| 36 | curl \ |
| 37 | dtc \ |
| 38 | gettext \ |
| 39 | glib-2.0 \ |
| 40 | gnutls \ |
| 41 | iproute2 \ |
| 42 | libnl \ |
| 43 | ncurses \ |
| 44 | openssl \ |
| 45 | pciutils \ |
| 46 | pixman \ |
| 47 | procps \ |
| 48 | python \ |
| 49 | libaio \ |
| 50 | lzo \ |
| 51 | util-linux \ |
| 52 | xz \ |
| 53 | yajl \ |
| 54 | zlib \ |
| 55 | " |
| 56 | |
| 57 | # inherit setuptools adds python to RDEPENDS, override it |
| 58 | RDEPENDS_${PN} = "" |
| 59 | |
| 60 | RDEPENDS_${PN}-base = "\ |
| 61 | bash perl xz \ |
| 62 | ${PN}-blktap \ |
| 63 | ${PN}-console \ |
| 64 | ${PN}-libblktapctl \ |
| 65 | ${PN}-libxenguest \ |
| 66 | ${PN}-libxenlight \ |
| 67 | ${PN}-libxenvchan \ |
| 68 | ${PN}-libxenctrl \ |
| 69 | ${PN}-libxlutil \ |
| 70 | ${PN}-libvhd \ |
| 71 | ${PN}-libxenstat \ |
| 72 | ${PN}-libxenstore \ |
| 73 | ${PN}-libfsimage \ |
| 74 | ${PN}-fsimage \ |
| 75 | ${PN}-scripts-block \ |
| 76 | ${PN}-scripts-network \ |
| 77 | ${PN}-xen-watchdog \ |
| 78 | ${PN}-xencommons \ |
| 79 | ${PN}-xendomains \ |
| 80 | ${PN}-xenstore \ |
| 81 | ${PN}-xenstored \ |
| 82 | ${PN}-xl \ |
| 83 | " |
| 84 | |
| 85 | RDEPENDS_${PN}-dev = "" |
| 86 | |
| 87 | RRECOMMENDS_${PN}-base = " \ |
| 88 | ${PN}-libblktap \ |
| 89 | ${PN}-flask \ |
| 90 | ${PN}-hvmloader \ |
| 91 | ${PN}-xenpaging \ |
| 92 | " |
| 93 | |
| 94 | RDEPENDS_${PN}-devd = " \ |
| 95 | ${PN}-xl \ |
| 96 | " |
| 97 | |
| 98 | RDEPENDS_${PN}-fsimage = " \ |
| 99 | libext2fs \ |
| 100 | " |
| 101 | |
| 102 | RDEPENDS_${PN}-misc = " \ |
| 103 | perl \ |
| 104 | python \ |
| 105 | " |
| 106 | |
| 107 | RDEPENDS_${PN}-remus = " \ |
| 108 | bash \ |
| 109 | python \ |
| 110 | " |
| 111 | |
| 112 | RDEPENDS_${PN}-scripts-block = "\ |
| 113 | bash \ |
| 114 | ${PN}-scripts-common \ |
| 115 | ${PN}-volatiles \ |
| 116 | " |
| 117 | |
| 118 | RDEPENDS_${PN}-scripts-common = "bash" |
| 119 | |
| 120 | RDEPENDS_${PN}-scripts-network = "\ |
| 121 | bash \ |
| 122 | bridge-utils \ |
| 123 | ${PN}-scripts-common \ |
| 124 | ${PN}-volatiles \ |
| 125 | " |
| 126 | |
| 127 | RDEPENDS_${PN}-xencommons = "\ |
| 128 | bash \ |
| 129 | ${PN}-console \ |
| 130 | ${PN}-xenstore \ |
| 131 | ${PN}-xenstored \ |
| 132 | ${PN}-xl \ |
| 133 | ${PN}-scripts-common \ |
| 134 | " |
| 135 | |
| 136 | RDEPENDS_${PN}-xendomains = "\ |
| 137 | bash \ |
| 138 | ${PN}-console \ |
| 139 | ${PN}-scripts-block \ |
| 140 | ${PN}-scripts-common \ |
| 141 | ${PN}-xenstored \ |
| 142 | " |
| 143 | |
| 144 | RDEPENDS_${PN}-xl = "libgcc" |
| 145 | |
| 146 | RDEPENDS_${PN}-xentrace = "python" |
| 147 | |
| 148 | RDEPENDS_${PN}-xen-watchdog = "bash" |
| 149 | |
| 150 | PACKAGES = "\ |
| 151 | ${PN}-base \ |
| 152 | ${PN}-blktap \ |
| 153 | ${PN}-console \ |
| 154 | ${PN}-dbg \ |
| 155 | ${PN}-dev \ |
| 156 | ${PN}-devd \ |
| 157 | ${PN}-doc \ |
| 158 | ${PN}-efi \ |
| 159 | ${PN}-flask \ |
| 160 | ${PN}-flask-tools \ |
| 161 | ${PN}-fsimage \ |
| 162 | ${PN}-gdbsx \ |
| 163 | ${PN}-hvmloader \ |
| 164 | ${PN}-hypervisor \ |
| 165 | ${PN}-init-xenstore-dom \ |
| 166 | ${PN}-kdd \ |
| 167 | ${PN}-libblktap \ |
| 168 | ${PN}-libblktapctl \ |
| 169 | ${PN}-libblktapctl-dev \ |
| 170 | ${PN}-libblktap-dev \ |
| 171 | ${PN}-libfsimage \ |
| 172 | ${PN}-libfsimage-dev \ |
| 173 | ${PN}-libvhd \ |
| 174 | ${PN}-libvhd-dev \ |
| 175 | ${PN}-libxencall \ |
| 176 | ${PN}-libxencall-dev \ |
| 177 | ${PN}-libxenctrl \ |
| 178 | ${PN}-libxenctrl-dev \ |
| 179 | ${PN}-libxenevtchn \ |
| 180 | ${PN}-libxenevtchn-dev \ |
| 181 | ${PN}-libxenforeignmemory \ |
| 182 | ${PN}-libxenforeignmemory-dev \ |
| 183 | ${PN}-libxengnttab \ |
| 184 | ${PN}-libxengnttab-dev \ |
| 185 | ${PN}-libxenguest \ |
| 186 | ${PN}-libxenguest-dev \ |
| 187 | ${PN}-libxenlight \ |
| 188 | ${PN}-libxenlight-dev \ |
| 189 | ${PN}-libxenstat \ |
| 190 | ${PN}-libxenstat-dev \ |
| 191 | ${PN}-libxenstore \ |
| 192 | ${PN}-libxenstore-dev \ |
| 193 | ${PN}-libxentoollog \ |
| 194 | ${PN}-libxentoollog-dev \ |
| 195 | ${PN}-libxenvchan \ |
| 196 | ${PN}-libxenvchan-dev \ |
| 197 | ${PN}-libxlutil \ |
| 198 | ${PN}-libxlutil-dev \ |
| 199 | ${PN}-misc \ |
| 200 | ${PN}-pygrub \ |
| 201 | ${PN}-python \ |
| 202 | ${PN}-qemu \ |
| 203 | ${PN}-remus \ |
| 204 | ${PN}-scripts-block \ |
| 205 | ${PN}-scripts-common \ |
| 206 | ${PN}-scripts-network \ |
| 207 | ${PN}-staticdev \ |
| 208 | ${PN}-volatiles \ |
| 209 | ${PN}-xcutils \ |
| 210 | ${PN}-xencommons \ |
| 211 | ${PN}-xend \ |
| 212 | ${PN}-xend-examples \ |
| 213 | ${PN}-xendomains \ |
| 214 | ${PN}-xenmon \ |
| 215 | ${PN}-xenpaging \ |
| 216 | ${PN}-xenpmd \ |
| 217 | ${PN}-xenstat \ |
| 218 | ${PN}-xenstore \ |
| 219 | ${PN}-xenstored \ |
| 220 | ${PN}-xentrace \ |
| 221 | ${PN}-xen-watchdog \ |
| 222 | ${PN}-xl \ |
| 223 | ${PN}-xl-examples \ |
| 224 | ${PN}-xm \ |
| 225 | ${PN}-xm-examples \ |
| 226 | " |
| 227 | |
| 228 | FILES_${PN}-dbg += "\ |
| 229 | ${libdir}/.debug \ |
| 230 | ${libdir}/debug/* \ |
| 231 | ${libdir}/xen/bin/.debug \ |
| 232 | ${libdir}/python2.7/site-packages/.debug \ |
| 233 | ${libdir}/python2.7/site-packages/xen/lowlevel/.debug \ |
| 234 | ${libdir}/fs/xfs/.debug \ |
| 235 | ${libdir}/fs/ufs/.debug \ |
| 236 | ${libdir}/fs/ext2fs-lib/.debug \ |
| 237 | ${libdir}/fs/fat/.debug \ |
| 238 | ${libdir}/fs/zfs/.debug \ |
| 239 | ${libdir}/fs/reiserfs/.debug \ |
| 240 | ${libdir}/fs/iso9660/.debug \ |
| 241 | ${libdir}/fs/*/.debug \ |
| 242 | ${sbindir}/.debug \ |
| 243 | ${libdir}exec/.debug \ |
| 244 | ${libdir}/xen/libexec/.debug \ |
| 245 | ${bindir}/.debug \ |
| 246 | ${libdir}/python2.7/dist-packages/.debug \ |
| 247 | ${libdir}/python2.7/dist-packages/xen/lowlevel/.debug \ |
| 248 | " |
| 249 | |
| 250 | FILES_${PN}-dev = "\ |
| 251 | ${includedir} \ |
| 252 | " |
| 253 | |
| 254 | FILES_${PN}-doc = "\ |
| 255 | ${sysconfdir}/xen/README \ |
| 256 | ${sysconfdir}/xen/README.incompatibilities \ |
| 257 | ${datadir}/doc \ |
| 258 | ${datadir}/man \ |
| 259 | " |
| 260 | |
| 261 | FILES_${PN}-staticdev += "\ |
| 262 | ${libdir}/libblktapctl.a \ |
| 263 | ${libdir}/libxenguest.a \ |
| 264 | ${libdir}/libxenlight.a \ |
| 265 | ${libdir}/libxenvchan.a \ |
| 266 | ${libdir}/libxenctrl.a \ |
| 267 | ${libdir}/libxlutil.a \ |
| 268 | ${libdir}/libvhd.a \ |
| 269 | ${libdir}/libxenstat.a \ |
| 270 | ${libdir}/libxenstore.a \ |
| 271 | ${libdir}/libblktap.a \ |
| 272 | " |
| 273 | |
| 274 | FILES_${PN}-libblktapctl = "${libdir}/libblktapctl.so.*" |
| 275 | FILES_${PN}-libblktapctl-dev = "${libdir}/libblktapctl.so" |
| 276 | |
| 277 | FILES_${PN}-libxencall = "${libdir}/libxencall.so.*" |
| 278 | FILES_${PN}-libxencall-dev = "${libdir}/libxencall.so" |
| 279 | |
| 280 | FILES_${PN}-libxenctrl = "${libdir}/libxenctrl.so.*" |
| 281 | FILES_${PN}-libxenctrl-dev = "${libdir}/libxenctrl.so" |
| 282 | |
| 283 | FILES_${PN}-libxenevtchn = "${libdir}/libxenevtchn.so.*" |
| 284 | FILES_${PN}-libxenevtchn-dev = "${libdir}/libxenevtchn.so" |
| 285 | |
| 286 | FILES_${PN}-libxenforeignmemory = "${libdir}/libxenforeignmemory.so.*" |
| 287 | FILES_${PN}-libxenforeignmemory-dev = "${libdir}/libxenforeignmemory.so" |
| 288 | |
| 289 | FILES_${PN}-libxengnttab = "${libdir}/libxengnttab.so.*" |
| 290 | FILES_${PN}-libxengnttab-dev = "${libdir}/libxengnttab.so" |
| 291 | |
| 292 | FILES_${PN}-libxenguest = "${libdir}/libxenguest.so.*" |
| 293 | FILES_${PN}-libxenguest-dev = "${libdir}/libxenguest.so" |
| 294 | |
| 295 | FILES_${PN}-libxenlight = "${libdir}/libxenlight.so.*" |
| 296 | FILES_${PN}-libxenlight-dev = " \ |
| 297 | ${libdir}/libxenlight.so \ |
| 298 | ${datadir}/pkgconfig/xenlight.pc \ |
| 299 | " |
| 300 | |
| 301 | FILES_${PN}-libxenstat = "${libdir}/libxenstat.so.*" |
| 302 | FILES_${PN}-libxenstat-dev = "${libdir}/libxenstat.so" |
| 303 | |
| 304 | FILES_${PN}-libxenstore = "${libdir}/libxenstore.so.*" |
| 305 | FILES_${PN}-libxenstore-dev = "${libdir}/libxenstore.so" |
| 306 | |
| 307 | FILES_${PN}-libxentoollog = "${libdir}/libxentoollog.so.*" |
| 308 | FILES_${PN}-libxentoollog-dev = "${libdir}/libxentoollog.so" |
| 309 | |
| 310 | FILES_${PN}-libxenvchan = "${libdir}/libxenvchan.so.*" |
| 311 | FILES_${PN}-libxenvchan-dev = "${libdir}/libxenvchan.so" |
| 312 | |
| 313 | FILES_${PN}-libxlutil = "${libdir}/libxlutil.so.*" |
| 314 | FILES_${PN}-libxlutil-dev = " \ |
| 315 | ${libdir}/libxlutil.so \ |
| 316 | ${datadir}/pkgconfig/xlutil.pc \ |
| 317 | " |
| 318 | FILES_${PN}-libvhd = "${libdir}/libvhd.so.*" |
| 319 | FILES_${PN}-libvhd-dev = "${libdir}/libvhd.so" |
| 320 | |
| 321 | FILES_${PN}-libblktap = "${libdir}/libblktap.so.*" |
| 322 | FILES_${PN}-libblktap-dev = "${libdir}/libblktap.so" |
| 323 | |
| 324 | FILES_${PN}-libfsimage = "${libdir}/libfsimage.so.*" |
| 325 | FILES_${PN}-libfsimage-dev = "${libdir}/libfsimage.so" |
| 326 | |
| 327 | FILES_${PN}-fsimage = "${libdir}/fs/*/*fsimage.so" |
| 328 | |
| 329 | FILES_${PN}-hypervisor = "\ |
| 330 | /boot/xen-* \ |
| 331 | /boot/xen \ |
| 332 | /boot/xen-*.gz \ |
| 333 | /boot/xen.gz \ |
| 334 | /boot/xen-syms-* \ |
| 335 | " |
| 336 | |
| 337 | FILES_${PN}-init-xenstore-dom = "${libdir}/xen/bin/init-xenstore-domain" |
| 338 | |
| 339 | FILES_${PN}-efi = "\ |
| 340 | ${exec_prefix}/lib64 \ |
| 341 | ${exec_prefix}/lib64/xen* \ |
| 342 | " |
| 343 | |
| 344 | FILES_${PN}-base = "\ |
| 345 | ${sysconfdir}/xen/auto \ |
| 346 | ${sysconfdir}/xen/cpupool \ |
| 347 | ${localstatedir}/xen/dump \ |
| 348 | " |
| 349 | |
| 350 | FILES_${PN}-blktap = "\ |
| 351 | ${sbindir}/blktapctrl \ |
| 352 | ${sbindir}/img2qcow \ |
| 353 | ${sbindir}/lock-util \ |
| 354 | ${sbindir}/qcow2raw \ |
| 355 | ${sbindir}/qcow-create \ |
| 356 | ${sbindir}/tap-ctl \ |
| 357 | ${sbindir}/tapdisk \ |
| 358 | ${sbindir}/tapdisk2 \ |
| 359 | ${sbindir}/tapdisk-client \ |
| 360 | ${sbindir}/tapdisk-diff \ |
| 361 | ${sbindir}/tapdisk-stream \ |
| 362 | ${sbindir}/td-util \ |
| 363 | ${sbindir}/vhd-update \ |
| 364 | ${sbindir}/vhd-util \ |
| 365 | " |
| 366 | |
| 367 | FILES_${PN}-console = "\ |
| 368 | ${libdir}/xen/bin/xenconsole \ |
| 369 | ${sbindir}/xenconsoled \ |
| 370 | " |
| 371 | |
| 372 | FILES_${PN}-devd = "\ |
| 373 | ${sysconfdir}/init.d/xendriverdomain \ |
| 374 | " |
| 375 | |
| 376 | FILES_${PN}-flask = "\ |
| 377 | /boot/${FLASK_POLICY_FILE} \ |
| 378 | " |
| 379 | |
| 380 | FILES_${PN}-flask-tools = "\ |
| 381 | ${sbindir}/flask-get-bool \ |
| 382 | ${sbindir}/flask-getenforce \ |
| 383 | ${sbindir}/flask-label-pci \ |
| 384 | ${sbindir}/flask-loadpolicy \ |
| 385 | ${sbindir}/flask-set-bool \ |
| 386 | ${sbindir}/flask-setenforce \ |
| 387 | " |
| 388 | |
| 389 | FILES_${PN}-gdbsx = "\ |
| 390 | ${sbindir}/gdbsx \ |
| 391 | " |
| 392 | |
| 393 | INSANE_SKIP_${PN}-hvmloader = "arch" |
| 394 | FILES_${PN}-hvmloader = "\ |
| 395 | ${libdir}/xen/boot/hvmloader \ |
| 396 | " |
| 397 | |
| 398 | FILES_${PN}-kdd = "\ |
| 399 | ${sbindir}/kdd \ |
| 400 | " |
| 401 | |
| 402 | FILES_${PN}-misc = "\ |
| 403 | ${bindir}/xencons \ |
| 404 | ${bindir}/xencov_split \ |
| 405 | ${bindir}/xen-detect \ |
| 406 | ${libdir}/xen/bin/xenpvnetboot \ |
| 407 | ${sbindir}/gtracestat \ |
| 408 | ${sbindir}/gtraceview \ |
| 409 | ${sbindir}/xen-bugtool \ |
| 410 | ${sbindir}/xencov \ |
| 411 | ${sbindir}/xenperf \ |
| 412 | ${sbindir}/xenpm \ |
| 413 | ${sbindir}/xsview \ |
| 414 | ${sbindir}/xen-tmem-list-parse \ |
| 415 | ${sbindir}/xen-python-path \ |
| 416 | ${sbindir}/xen-ringwatch \ |
| 417 | ${sbindir}/xen-hptool \ |
| 418 | ${sbindir}/xen-hvmcrash \ |
| 419 | ${sbindir}/xen-hvmctx \ |
| 420 | ${sbindir}/xenlockprof \ |
| 421 | ${sbindir}/xen-lowmemd \ |
| 422 | ${sbindir}/xen-mfndump \ |
| 423 | ${libdir}/xen/bin/verify-stream-v2 \ |
| 424 | ${libdir}/xen/bin/convert-legacy-stream \ |
| 425 | " |
| 426 | |
| 427 | FILES_${PN}-pygrub = "\ |
| 428 | ${bindir}/pygrub \ |
| 429 | ${libdir}/xen/bin/pygrub \ |
| 430 | " |
| 431 | |
| 432 | FILES_${PN}-python = "\ |
| 433 | ${libdir}/python2.7 \ |
| 434 | " |
| 435 | |
| 436 | INSANE_SKIP_${PN} = "already-stripped" |
| 437 | INSANE_SKIP_${PN}-qemu = "arch" |
| 438 | FILES_${PN}-qemu = " \ |
| 439 | ${datadir}/xen/qemu \ |
| 440 | ${libdir}/xen/bin/qemu-system-i386 \ |
| 441 | ${libdir}/xen/bin/qemu-system-x86_64 \ |
| 442 | ${libdir}/xen/bin/qemu-img \ |
| 443 | ${libdir}/xen/bin/qemu-nbd \ |
| 444 | ${libdir}/xen/bin/qemu-ga \ |
| 445 | ${libdir}/xen/bin/qemu-io \ |
| 446 | ${libdir}/xen/bin/qemu-dm \ |
| 447 | ${libdir}/xen/bin/virtfs-proxy-helper \ |
| 448 | /usr/libexec/qemu-bridge-helper \ |
| 449 | ${libdir}/xen/libexec/qemu-bridge-helper \ |
| 450 | /usr/etc/qemu \ |
| 451 | /usr/etc/qemu/target-x86_64.conf \ |
| 452 | ${libdir}/xen/etc/qemu/target-x86_64.conf \ |
| 453 | ${datadir}/qemu-xen \ |
| 454 | ${datadir}/qemu-xen/qemu \ |
| 455 | ${datadir}/qemu-xen/qemu/bamboo.dtb \ |
| 456 | ${datadir}/qemu-xen/qemu/pxe-pcnet.rom \ |
| 457 | ${datadir}/qemu-xen/qemu/vgabios-vmware.bin \ |
| 458 | ${datadir}/qemu-xen/qemu/pxe-eepro100.rom \ |
| 459 | ${datadir}/qemu-xen/qemu/pxe-e1000.rom \ |
| 460 | ${datadir}/qemu-xen/qemu/openbios-ppc \ |
| 461 | ${datadir}/qemu-xen/qemu/multiboot.bin \ |
| 462 | ${datadir}/qemu-xen/qemu/vgabios-cirrus.bin \ |
| 463 | ${datadir}/qemu-xen/qemu/bios.bin \ |
| 464 | ${datadir}/qemu-xen/qemu/vgabios-stdvga.bin \ |
| 465 | ${datadir}/qemu-xen/qemu/palcode-clipper \ |
| 466 | ${datadir}/qemu-xen/qemu/pxe-ne2k_pci.rom \ |
| 467 | ${datadir}/qemu-xen/qemu/spapr-rtas.bin \ |
| 468 | ${datadir}/qemu-xen/qemu/slof.bin \ |
| 469 | ${datadir}/qemu-xen/qemu/vgabios-qxl.bin \ |
| 470 | ${datadir}/qemu-xen/qemu/pxe-rtl8139.rom \ |
| 471 | ${datadir}/qemu-xen/qemu/openbios-sparc64 \ |
| 472 | ${datadir}/qemu-xen/qemu/pxe-virtio.rom \ |
| 473 | ${datadir}/qemu-xen/qemu/kvmvapic.bin \ |
| 474 | ${datadir}/qemu-xen/qemu/openbios-sparc32 \ |
| 475 | ${datadir}/qemu-xen/qemu/petalogix-s3adsp1800.dtb \ |
| 476 | ${datadir}/qemu-xen/qemu/sgabios.bin \ |
| 477 | ${datadir}/qemu-xen/qemu/linuxboot.bin \ |
| 478 | ${datadir}/qemu-xen/qemu/qemu-icon.bmp \ |
| 479 | ${datadir}/qemu-xen/qemu/ppc_rom.bin \ |
| 480 | ${datadir}/qemu-xen/qemu/vgabios.bin \ |
| 481 | ${datadir}/qemu-xen/qemu/s390-zipl.rom \ |
| 482 | ${datadir}/qemu-xen/qemu/petalogix-ml605.dtb \ |
| 483 | ${datadir}/qemu-xen/qemu/keymaps \ |
| 484 | ${datadir}/qemu-xen/qemu/keymaps/common \ |
| 485 | ${datadir}/qemu-xen/qemu/keymaps/th \ |
| 486 | ${datadir}/qemu-xen/qemu/keymaps/is \ |
| 487 | ${datadir}/qemu-xen/qemu/keymaps/en-gb \ |
| 488 | ${datadir}/qemu-xen/qemu/keymaps/ar \ |
| 489 | ${datadir}/qemu-xen/qemu/keymaps/fr-be \ |
| 490 | ${datadir}/qemu-xen/qemu/keymaps/ru \ |
| 491 | ${datadir}/qemu-xen/qemu/keymaps/hu \ |
| 492 | ${datadir}/qemu-xen/qemu/keymaps/de-ch \ |
| 493 | ${datadir}/qemu-xen/qemu/keymaps/no \ |
| 494 | ${datadir}/qemu-xen/qemu/keymaps/fr \ |
| 495 | ${datadir}/qemu-xen/qemu/keymaps/pl \ |
| 496 | ${datadir}/qemu-xen/qemu/keymaps/fr-ca \ |
| 497 | ${datadir}/qemu-xen/qemu/keymaps/de \ |
| 498 | ${datadir}/qemu-xen/qemu/keymaps/fr-ch \ |
| 499 | ${datadir}/qemu-xen/qemu/keymaps/bepo \ |
| 500 | ${datadir}/qemu-xen/qemu/keymaps/lv \ |
| 501 | ${datadir}/qemu-xen/qemu/keymaps/ja \ |
| 502 | ${datadir}/qemu-xen/qemu/keymaps/da \ |
| 503 | ${datadir}/qemu-xen/qemu/keymaps/lt \ |
| 504 | ${datadir}/qemu-xen/qemu/keymaps/hr \ |
| 505 | ${datadir}/qemu-xen/qemu/keymaps/es \ |
| 506 | ${datadir}/qemu-xen/qemu/keymaps/modifiers \ |
| 507 | ${datadir}/qemu-xen/qemu/keymaps/sl \ |
| 508 | ${datadir}/qemu-xen/qemu/keymaps/it \ |
| 509 | ${datadir}/qemu-xen/qemu/keymaps/nl \ |
| 510 | ${datadir}/qemu-xen/qemu/keymaps/fo \ |
| 511 | ${datadir}/qemu-xen/qemu/keymaps/mk \ |
| 512 | ${datadir}/qemu-xen/qemu/keymaps/pt-br \ |
| 513 | ${datadir}/qemu-xen/qemu/keymaps/tr \ |
| 514 | ${datadir}/qemu-xen/qemu/keymaps/sv \ |
| 515 | ${datadir}/qemu-xen/qemu/keymaps/fi \ |
| 516 | ${datadir}/qemu-xen/qemu/keymaps/en-us \ |
| 517 | ${datadir}/qemu-xen/qemu/keymaps/et \ |
| 518 | ${datadir}/qemu-xen/qemu/keymaps/nl-be \ |
| 519 | ${datadir}/qemu-xen/qemu/keymaps/pt \ |
| 520 | ${bindir}/qemu-nbd-xen \ |
| 521 | ${bindir}/qemu-img-xen \ |
| 522 | " |
| 523 | |
| 524 | FILES_${PN}-remus = "\ |
| 525 | ${bindir}/remus \ |
| 526 | ${sysconfdir}/xen/scripts/remus-netbuf-setup \ |
| 527 | " |
| 528 | |
| 529 | FILES_${PN}-scripts-network = " \ |
| 530 | ${sysconfdir}/xen/scripts/network-bridge \ |
| 531 | ${sysconfdir}/xen/scripts/network-nat \ |
| 532 | ${sysconfdir}/xen/scripts/network-route \ |
| 533 | ${sysconfdir}/xen/scripts/qemu-ifup \ |
| 534 | ${sysconfdir}/xen/scripts/vif2 \ |
| 535 | ${sysconfdir}/xen/scripts/vif-bridge \ |
| 536 | ${sysconfdir}/xen/scripts/vif-common.sh \ |
| 537 | ${sysconfdir}/xen/scripts/vif-nat \ |
| 538 | ${sysconfdir}/xen/scripts/vif-openvswitch \ |
| 539 | ${sysconfdir}/xen/scripts/vif-route \ |
| 540 | ${sysconfdir}/xen/scripts/vif-setup \ |
| 541 | " |
| 542 | |
| 543 | FILES_${PN}-scripts-block = " \ |
| 544 | ${sysconfdir}/xen/scripts/blktap \ |
| 545 | ${sysconfdir}/xen/scripts/block \ |
| 546 | ${sysconfdir}/xen/scripts/block-common.sh \ |
| 547 | ${sysconfdir}/xen/scripts/block-enbd \ |
| 548 | ${sysconfdir}/xen/scripts/block-iscsi \ |
| 549 | ${sysconfdir}/xen/scripts/block-nbd \ |
| 550 | ${sysconfdir}/xen/scripts/block-drbd-probe \ |
| 551 | ${sysconfdir}/xen/scripts/block-tap \ |
| 552 | ${sysconfdir}/xen/scripts/vscsi \ |
| 553 | " |
| 554 | |
| 555 | FILES_${PN}-scripts-common = " \ |
| 556 | ${sysconfdir}/xen/scripts/external-device-migrate \ |
| 557 | ${sysconfdir}/xen/scripts/hotplugpath.sh \ |
| 558 | ${sysconfdir}/xen/scripts/locking.sh \ |
| 559 | ${sysconfdir}/xen/scripts/logging.sh \ |
| 560 | ${sysconfdir}/xen/scripts/xen-hotplug-cleanup \ |
| 561 | ${sysconfdir}/xen/scripts/xen-hotplug-common.sh \ |
| 562 | ${sysconfdir}/xen/scripts/xen-network-common.sh \ |
| 563 | ${sysconfdir}/xen/scripts/xen-script-common.sh \ |
| 564 | " |
| 565 | |
| 566 | FILES_${PN}-volatiles = "\ |
| 567 | ${sysconfdir}/default/volatiles/99_xen \ |
| 568 | ${sysconfdir}/tmpfiles.d/xen.conf \ |
| 569 | " |
| 570 | |
| 571 | FILES_${PN}-xcutils = "\ |
| 572 | ${libdir}/xen/bin/lsevtchn \ |
| 573 | ${libdir}/xen/bin/readnotes \ |
| 574 | ${libdir}/xen/bin/xc_restore \ |
| 575 | ${libdir}/xen/bin/xc_save \ |
| 576 | " |
| 577 | |
| 578 | FILES_${PN}-xend-examples = "\ |
| 579 | ${sysconfdir}/xen/xend-config.sxp \ |
| 580 | ${sysconfdir}/xen/xend-pci-permissive.sxp \ |
| 581 | ${sysconfdir}/xen/xend-pci-quirks.sxp \ |
| 582 | " |
| 583 | |
| 584 | FILES_${PN}-xenpaging = "\ |
| 585 | ${libdir}/xen/bin/xenpaging \ |
| 586 | ${localstatedir}/lib/xen/xenpaging \ |
| 587 | " |
| 588 | |
| 589 | FILES_${PN}-xenpmd = "\ |
| 590 | ${sbindir}/xenpmd \ |
| 591 | " |
| 592 | |
| 593 | FILES_${PN}-xenstat = "\ |
| 594 | ${sbindir}/xentop \ |
| 595 | " |
| 596 | |
| 597 | FILES_${PN}-xenstore = "\ |
| 598 | ${bindir}/xenstore \ |
| 599 | ${bindir}/xenstore-chmod \ |
| 600 | ${bindir}/xenstore-control \ |
| 601 | ${bindir}/xenstore-exists \ |
| 602 | ${bindir}/xenstore-list \ |
| 603 | ${bindir}/xenstore-ls \ |
| 604 | ${bindir}/xenstore-read \ |
| 605 | ${bindir}/xenstore-rm \ |
| 606 | ${bindir}/xenstore-watch \ |
| 607 | ${bindir}/xenstore-write \ |
| 608 | " |
| 609 | |
| 610 | FILES_${PN}-xenstored = "\ |
| 611 | ${sbindir}/xenstored \ |
| 612 | ${localstatedir}/lib/xenstored \ |
| 613 | " |
| 614 | |
| 615 | FILES_${PN}-xentrace = "\ |
| 616 | ${bindir}/xentrace \ |
| 617 | ${bindir}/xentrace_format \ |
| 618 | ${bindir}/xentrace_setsize \ |
| 619 | ${libdir}/xen/bin/xenctx \ |
| 620 | ${bindir}/xenalyze \ |
| 621 | ${sbindir}/xentrace \ |
| 622 | ${sbindir}/xentrace_setsize \ |
| 623 | " |
| 624 | |
| 625 | FILES_${PN}-xen-watchdog = "\ |
| 626 | ${sbindir}/xenwatchdogd \ |
| 627 | ${sysconfdir}/init.d/xen-watchdog \ |
| 628 | ${systemd_unitdir}/system/xen-watchdog.service \ |
| 629 | " |
| 630 | |
| 631 | FILES_${PN}-xl = "\ |
| 632 | ${sysconfdir}/bash_completion.d/xl.sh \ |
| 633 | ${sysconfdir}/xen/xl.conf \ |
| 634 | ${libdir}/xen/bin/libxl-save-helper \ |
| 635 | ${sbindir}/xl \ |
| 636 | ${libdir}/xen/bin/xen-init-dom0 \ |
| 637 | " |
| 638 | |
| 639 | FILES_${PN}-xl-examples = "\ |
| 640 | ${sysconfdir}/xen/xlexample.hvm \ |
| 641 | ${sysconfdir}/xen/xlexample.pvlinux \ |
| 642 | " |
| 643 | |
| 644 | FILES_${PN}-xm-examples = "\ |
| 645 | ${sysconfdir}/xen/xmexample1 \ |
| 646 | ${sysconfdir}/xen/xmexample2 \ |
| 647 | ${sysconfdir}/xen/xmexample3 \ |
| 648 | ${sysconfdir}/xen/xmexample.hvm \ |
| 649 | ${sysconfdir}/xen/xmexample.hvm-stubdom \ |
| 650 | ${sysconfdir}/xen/xmexample.nbd \ |
| 651 | ${sysconfdir}/xen/xmexample.pv-grub \ |
| 652 | ${sysconfdir}/xen/xmexample.vti \ |
| 653 | " |
| 654 | |
| 655 | FILES_${PN}-xenmon = "\ |
| 656 | ${sbindir}/xenbaked \ |
| 657 | ${sbindir}/xentrace_setmask \ |
| 658 | ${sbindir}/xenmon.py \ |
| 659 | " |
| 660 | |
| 661 | FILES_${PN}-xm = "\ |
| 662 | ${sysconfdir}/xen/xm-config.xml \ |
| 663 | ${datadir}/xen/create.dtd \ |
| 664 | ${sbindir}/xm \ |
| 665 | " |
| 666 | |
| 667 | FILES_${PN}-xencommons += "\ |
| 668 | ${sysconfdir}/default/xencommons \ |
| 669 | ${sysconfdir}/init.d/xencommons \ |
| 670 | ${systemd_unitdir}/modules-load.d/xen.conf \ |
| 671 | ${systemd_unitdir}/system/proc-xen.mount \ |
| 672 | ${systemd_unitdir}/system/xen-qemu-dom0-disk-backend.service \ |
| 673 | ${systemd_unitdir}/system/xenconsoled.service \ |
| 674 | ${systemd_unitdir}/system/xen-init-dom0.service \ |
| 675 | ${systemd_unitdir}/system/xenstored.service \ |
| 676 | ${systemd_unitdir}/system/xenstored.socket \ |
| 677 | ${systemd_unitdir}/system/xenstored_ro.socket \ |
| 678 | ${systemd_unitdir}/system/var-lib-xenstored.mount \ |
| 679 | " |
| 680 | |
| 681 | FILES_${PN}-xend += " \ |
| 682 | ${sysconfdir}/init.d/xend \ |
| 683 | ${sbindir}/xend \ |
| 684 | " |
| 685 | |
| 686 | FILES_${PN}-xendomains += "\ |
| 687 | ${libdir}/xen/bin/xendomains \ |
| 688 | ${sysconfdir}/default/xendomains \ |
| 689 | ${sysconfdir}/init.d/xendomains \ |
| 690 | ${sysconfdir}/sysconfig/xendomains \ |
| 691 | ${systemd_unitdir}/system/xendomains.service \ |
| 692 | " |
| 693 | |
| 694 | # configure init.d scripts |
| 695 | INITSCRIPT_PACKAGES = "${PN}-xend ${PN}-xencommons ${PN}-xen-watchdog ${PN}-xendomains ${PN}-devd" |
| 696 | INITSCRIPT_NAME_${PN}-xencommons = "xencommons" |
| 697 | INITSCRIPT_PARAMS_${PN}-xencommons = "defaults 80" |
| 698 | INITSCRIPT_NAME_${PN}-xen-watchdog = "xen-watchdog" |
| 699 | INITSCRIPT_PARAMS_${PN}-xen-watchdog = "defaults 81" |
| 700 | INITSCRIPT_NAME_${PN}-xend = "xend" |
| 701 | INITSCRIPT_PARAMS_${PN}-xend = "defaults 82" |
| 702 | INITSCRIPT_NAME_${PN}-xendomains = "xendomains" |
| 703 | INITSCRIPT_PARAMS_${PN}-xendomains = "defaults 83" |
| 704 | INITSCRIPT_NAME_${PN}-devd = "xendriverdomain" |
| 705 | INITSCRIPT_PARAMS_${PN}-devd = "defaults 82" |
| 706 | |
| 707 | # systemd packages |
| 708 | SYSTEMD_PACKAGES = "${PN}-xen-watchdog ${PN}-xencommons ${PN}-xendomains" |
| 709 | SYSTEMD_SERVICE_${PN}-watchdog = "xen-watchdog.service" |
| 710 | SYSTEMD_SERVICE_${PN}-xencommons = " \ |
| 711 | proc-xen.mount \ |
| 712 | var-lib-xenstored.mount \ |
| 713 | xen-qemu-dom0-disk-backend.service \ |
| 714 | xenconsoled.service \ |
| 715 | xen-init-dom0.service \ |
| 716 | xenstored.service \ |
| 717 | xenstored.socket \ |
| 718 | xenstored_ro.socket \ |
| 719 | " |
| 720 | SYSTEMD_SERVICE_${PN}-xendomains = "xendomains.service" |
| 721 | |
| 722 | #### REQUIRED ENVIRONMENT VARIABLES #### |
| 723 | export BUILD_SYS |
| 724 | export HOST_SYS |
| 725 | export STAGING_INCDIR |
| 726 | export STAGING_LIBDIR |
| 727 | |
| 728 | # specify xen hypervisor to build/target |
| 729 | export XEN_TARGET_ARCH = "${@map_xen_arch(d.getVar('TARGET_ARCH', True), d)}" |
| 730 | export XEN_COMPILE_ARCH = "${@map_xen_arch(d.getVar('BUILD_ARCH', True), d)}" |
| 731 | |
| 732 | python () { |
| 733 | if d.getVar('XEN_TARGET_ARCH', True) == 'INVALID': |
| 734 | raise bb.parse.SkipPackage('Cannot map `%s` to a xen architecture' % d.getVar('TARGET_ARCH', True)) |
| 735 | } |
| 736 | |
| 737 | # Yocto appends ${PN} to libexecdir by default and Xen appends 'xen' as well |
| 738 | # the result is a nested xen/xen/ so let's avoid that by shunning Yocto's |
| 739 | # extra ${PN} appended. |
| 740 | libexecdir = "${libdir}" |
| 741 | |
| 742 | # hardcoded as Linux, as the only compatible hosts are Linux. |
| 743 | export XEN_OS = "Linux" |
| 744 | |
| 745 | # this is used for the header (#!${bindir}/python) of the install python scripts |
| 746 | export PYTHONPATH="${bindir}/python" |
| 747 | |
| 748 | # seabios forcefully sets HOSTCC to CC - fixup to allow it to build native conf executable |
| 749 | export HOSTCC="${BUILD_CC}" |
| 750 | |
| 751 | # make xen requires CROSS_COMPILE set by hand as it does not abide by ./configure |
| 752 | export CROSS_COMPILE="${TARGET_PREFIX}" |
| 753 | |
| 754 | # overide LDFLAGS to allow xen to build without: "x86_64-oe-linux-ld: unrecognized option '-Wl,-O1'" |
| 755 | export LDFLAGS="" |
| 756 | |
| 757 | # Yocto injects -mfpmath=sse for some machine types into the CFLAGS which |
| 758 | # conflicts with -mno-sse so instead we strip -mfpmath=sse instead of |
| 759 | # patching the build to be ok with this |
| 760 | TUNE_CCARGS := "${@oe_filter_out('-mfpmath=sse', '${TUNE_CCARGS}', d)}" |
| 761 | |
| 762 | EXTRA_OECONF += " \ |
| 763 | --exec-prefix=/usr \ |
| 764 | --prefix=/usr \ |
| 765 | --host=${HOST_SYS} \ |
| 766 | --with-systemd=${systemd_unitdir}/system \ |
| 767 | --with-systemd-modules-load=${systemd_unitdir}/modules-load.d \ |
| 768 | --disable-stubdom \ |
| 769 | --disable-ioemu-stubdom \ |
| 770 | --disable-pv-grub \ |
| 771 | --disable-xenstore-stubdom \ |
| 772 | --disable-rombios \ |
| 773 | --disable-ocamltools \ |
| 774 | --with-initddir=${INIT_D_DIR} \ |
| 775 | --with-sysconfig-leaf-dir=default \ |
| 776 | --with-system-qemu=/usr/bin/qemu-system-i386 \ |
| 777 | --disable-qemu-traditional \ |
| 778 | " |
| 779 | |
| 780 | EXTRA_OEMAKE += "STDVGA_ROM=${STAGING_DIR_HOST}/usr/share/firmware/vgabios-0.7a.bin" |
| 781 | EXTRA_OEMAKE += "CIRRUSVGA_ROM=${STAGING_DIR_HOST}/usr/share/firmware/vgabios-0.7a.cirrus.bin" |
| 782 | EXTRA_OEMAKE += "SEABIOS_ROM=${STAGING_DIR_HOST}/usr/share/firmware/bios.bin" |
| 783 | EXTRA_OEMAKE += "ETHERBOOT_ROMS=${STAGING_DIR_HOST}/usr/share/firmware/rtl8139.rom" |
| 784 | |
| 785 | # prevent the Xen build scripts from fetching things during the build |
| 786 | # all dependencies should be reflected in the Yocto recipe |
| 787 | EXTRA_OEMAKE += "WGET=/bin/false" |
| 788 | EXTRA_OEMAKE += "GIT=/bin/false" |
| 789 | |
| 790 | # check for XSM in package config to allow XSM_ENABLE to be set |
| 791 | python () { |
| 792 | pkgconfig = d.getVar('PACKAGECONFIG', True) |
| 793 | if ('xsm') in pkgconfig.split(): |
| 794 | d.setVar('XSM_ENABLED', '1') |
| 795 | else: |
| 796 | d.setVar('XSM_ENABLED', '0') |
| 797 | } |
| 798 | |
| 799 | do_post_patch() { |
| 800 | # fixup AS/CC/CCP/etc variable within StdGNU.mk |
| 801 | for i in LD CC CPP CXX; do |
| 802 | sed -i "s/^\($i\s\s*\).*=/\1?=/" ${S}/config/StdGNU.mk |
| 803 | done |
| 804 | # fixup environment passing in some makefiles |
| 805 | sed -i 's#\(\w*\)=\(\$.\w*.\)#\1="\2"#' ${S}/tools/firmware/Makefile |
| 806 | |
| 807 | # libsystemd-daemon -> libsystemd for newer systemd versions |
| 808 | sed -i 's#libsystemd-daemon#libsystemd#' ${S}/tools/configure |
| 809 | } |
| 810 | |
| 811 | addtask post_patch after do_patch before do_configure |
| 812 | |
| 813 | do_stubs() { |
| 814 | # no stubs-32.h in our 64-bit sysroot - hack it into tools/include/gnu |
| 815 | if ! test -f ${STAGING_DIR_TARGET}/usr/include/gnu/stubs-32.h ; then |
| 816 | if test -f ${STAGING_DIR_TARGET}/usr/include/gnu/stubs-64.h ; then |
| 817 | test -d ${S}/tools/include/gnu || mkdir ${S}/tools/include/gnu |
| 818 | cat ${STAGING_DIR_TARGET}/usr/include/gnu/stubs-64.h | grep -v stub_bdflush | grep -v stub_getmsg | grep -v stub_putmsg > ${S}/tools/include/gnu/stubs-32.h |
| 819 | echo \#define __stub___kernel_cosl >> ${S}/tools/include/gnu/stubs-32.h |
| 820 | echo \#define __stub___kernel_sinl >> ${S}/tools/include/gnu/stubs-32.h |
| 821 | echo \#define __stub___kernel_tanl >> ${S}/tools/include/gnu/stubs-32.h |
| 822 | fi |
| 823 | fi |
| 824 | } |
| 825 | |
| 826 | addtask stubs after do_configure before do_compile |
| 827 | |
| 828 | do_configure() { |
| 829 | |
| 830 | #./configure --enable-xsmpolicy does not set XSM_ENABLE must be done manually |
| 831 | if [ "${XSM_ENABLED}" = "1" ]; then |
| 832 | echo "XSM_ENABLE := y" > ${S}/.config |
| 833 | fi |
| 834 | |
| 835 | # do configure |
| 836 | oe_runconf |
| 837 | } |
| 838 | |
| 839 | do_compile() { |
| 840 | oe_runmake |
| 841 | } |
| 842 | |
| 843 | do_install() { |
| 844 | oe_runmake DESTDIR="${D}" install |
| 845 | |
| 846 | # remove installed volatiles |
| 847 | rm -rf ${D}${localstatedir}/run \ |
| 848 | ${D}${localstatedir}/lock \ |
| 849 | ${D}${localstatedir}/log \ |
| 850 | ${D}${localstatedir}/volatile \ |
| 851 | ${D}${localstatedir}/lib/xen |
| 852 | |
| 853 | VOLATILE_DIRS=" \ |
| 854 | ${localstatedir}/run/xenstored \ |
| 855 | ${localstatedir}/run/xend \ |
| 856 | ${localstatedir}/run/xend/boot \ |
| 857 | ${localstatedir}/run/xen \ |
| 858 | ${localstatedir}/log/xen \ |
| 859 | ${localstatedir}/lock/xen \ |
| 860 | ${localstatedir}/lock/subsys \ |
| 861 | ${localstatedir}/lib/xen \ |
| 862 | " |
| 863 | |
| 864 | # install volatiles using populate_volatiles mechanism |
| 865 | install -d ${D}${sysconfdir}/default/volatiles |
| 866 | for i in $VOLATILE_DIRS; do |
| 867 | echo "d root root 0755 $i none" >> ${D}${sysconfdir}/default/volatiles/99_xen |
| 868 | done |
| 869 | |
| 870 | # workaround for xendomains script which searchs sysconfig if directory exists |
| 871 | install -d ${D}${sysconfdir}/sysconfig |
| 872 | ln -sf ${sysconfdir}/default/xendomains ${D}${sysconfdir}/sysconfig/xendomains |
| 873 | |
| 874 | # systemd |
| 875 | if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then |
| 876 | # install volatiles using systemd tmpfiles.d |
| 877 | install -d ${D}${sysconfdir}/tmpfiles.d |
| 878 | for i in $VOLATILE_DIRS; do |
| 879 | echo "d $i 0755 root root - -" >> ${D}${sysconfdir}/tmpfiles.d/xen.conf |
| 880 | done |
| 881 | fi |
| 882 | |
| 883 | # fixup default path to qemu-system-i386 |
| 884 | sed -i 's#\(test -z "$QEMU_XEN" && QEMU_XEN=\).*$#\1"/usr/bin/qemu-system-i386"#' ${D}/etc/init.d/xencommons |
| 885 | |
| 886 | if [ -e ${D}${systemd_unitdir}/system/xen-qemu-dom0-disk-backend.service ]; then |
| 887 | sed -i 's#ExecStart=.*qemu-system-i386\(.*\)$#ExecStart=/usr/bin/qemu-system-i386\1#' \ |
| 888 | ${D}${systemd_unitdir}/system/xen-qemu-dom0-disk-backend.service |
| 889 | fi |
| 890 | } |
| 891 | |
| 892 | pkg_postinst_${PN}-volatiles() { |
| 893 | if [ -z "$D" ]; then |
| 894 | if command -v systemd-tmpfiles >/dev/null; then |
| 895 | systemd-tmpfiles --create ${sysconfdir}/tmpfiles.d/xen.conf |
| 896 | elif [ -e ${sysconfdir}/init.d/populate-volatile.sh ]; then |
| 897 | ${sysconfdir}/init.d/populate-volatile.sh update |
| 898 | fi |
| 899 | fi |
| 900 | } |
| 901 | |
| 902 | do_deploy() { |
| 903 | install -d ${DEPLOYDIR} |
| 904 | |
| 905 | if [ -f ${D}/boot/xen ]; then |
| 906 | install -m 0644 ${D}/boot/xen ${DEPLOYDIR}/xen-${MACHINE} |
| 907 | fi |
| 908 | |
| 909 | if [ -f ${D}/boot/xen.gz ]; then |
| 910 | install -m 0644 ${D}/boot/xen.gz ${DEPLOYDIR}/xen-${MACHINE}.gz |
| 911 | fi |
| 912 | |
| 913 | if [ -f ${D}/usr/lib64/efi/xen.efi ]; then |
| 914 | install -m 0644 ${D}/usr/lib64/efi/xen.efi ${DEPLOYDIR}/xen-${MACHINE}.efi |
| 915 | fi |
| 916 | |
| 917 | # Install the flask policy in the deploy directory if it exists |
| 918 | if [ -f ${D}/boot/${FLASK_POLICY_FILE} ]; then |
| 919 | install -m 0644 ${D}/boot/${FLASK_POLICY_FILE} ${DEPLOYDIR} |
| 920 | ln -sf ${FLASK_POLICY_FILE} ${DEPLOYDIR}/xenpolicy-${MACHINE} |
| 921 | fi |
| 922 | } |
| 923 | |
| 924 | addtask deploy after do_populate_sysroot |