Cyril Bur | 9a3f008 | 2017-01-12 18:13:30 +1100 | [diff] [blame] | 1 | SUMMARY = "Phosphor OpenBMC MBOX Daemon" |
| 2 | DESCRIPTION = "Phosphor OpenBMC MBOX Daemon" |
| 3 | PR = "r1" |
| 4 | LICENSE = "Apache-2.0" |
| 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=e3fc50a88d0a364313df4b21ef20c29e" |
| 6 | |
| 7 | inherit autotools pkgconfig |
| 8 | inherit obmc-phosphor-systemd |
| 9 | |
| 10 | DEPENDS += "autoconf-archive-native" |
Andrew Jeffery | 928084f | 2017-04-21 10:18:24 +0930 | [diff] [blame] | 11 | DEPENDS += "systemd" |
Patrick Williams | ea61a04 | 2017-06-30 12:01:49 -0500 | [diff] [blame] | 12 | DEPENDS += "phosphor-logging" |
Andrew Jeffery | aef4ced | 2017-04-18 16:30:10 +0930 | [diff] [blame] | 13 | RDEPENDS_${PN} += "libsystemd" |
Cyril Bur | 9a3f008 | 2017-01-12 18:13:30 +1100 | [diff] [blame] | 14 | |
| 15 | S = "${WORKDIR}/git" |
| 16 | |
Adriana Kobylak | bb6679e | 2017-06-10 09:47:58 -0500 | [diff] [blame] | 17 | SRC_URI += "git://github.com/openbmc/phosphor-mboxd.git" |
Cyril Bur | 9a3f008 | 2017-01-12 18:13:30 +1100 | [diff] [blame] | 18 | |
| 19 | SRC_URI += "file://99-aspeed-mbox.rules" |
Andrew Jeffery | a944a4b | 2017-01-25 13:17:13 +1030 | [diff] [blame] | 20 | SRC_URI += "file://99-aspeed-lpc-ctrl.rules" |
Cyril Bur | 9a3f008 | 2017-01-12 18:13:30 +1100 | [diff] [blame] | 21 | SRC_URI += "file://aspeed-lpc-ctrl-h.patch" |
| 22 | |
Andrew Geissler | 87059f8 | 2017-10-11 14:45:08 +0000 | [diff] [blame] | 23 | SRCREV="8493c33b1adbaf0adaa6bf2b7c1696e86a89ab1b" |
Andrew Jeffery | aef4ced | 2017-04-18 16:30:10 +0930 | [diff] [blame] | 24 | |
| 25 | PROVIDES += "mboxctl" |
Cyril Bur | 9a3f008 | 2017-01-12 18:13:30 +1100 | [diff] [blame] | 26 | |
| 27 | MBOXD_FLASH_SIZE ??= "32M" |
| 28 | SYSTEMD_SUBSTITUTIONS += "FLASH_SIZE:${MBOXD_FLASH_SIZE}:${PN}.service" |
| 29 | |
| 30 | # Hacks because ${STAGING_KERNEL_DIR} points to the kernel source tree, not the |
| 31 | # installed, pre-processed headers. Requires the aspeed-lpc-ctrl-h patch above. |
Saqib Khan | be0ee8e | 2017-03-09 10:28:09 -0600 | [diff] [blame] | 32 | CFLAGS_append = " -I include" |
Cyril Bur | 9a3f008 | 2017-01-12 18:13:30 +1100 | [diff] [blame] | 33 | |
| 34 | do_install_append() { |
| 35 | install -d ${D}/lib/udev/rules.d |
| 36 | install -m 0644 ${WORKDIR}/99-aspeed-mbox.rules ${D}/lib/udev/rules.d |
Andrew Jeffery | a944a4b | 2017-01-25 13:17:13 +1030 | [diff] [blame] | 37 | install -m 0644 ${WORKDIR}/99-aspeed-lpc-ctrl.rules ${D}/lib/udev/rules.d |
Cyril Bur | 9a3f008 | 2017-01-12 18:13:30 +1100 | [diff] [blame] | 38 | } |
Matt Spinler | f96194c | 2017-01-20 15:32:07 -0600 | [diff] [blame] | 39 | |
| 40 | TMPL = "mboxd-reload@.service" |
Andrew Geissler | 4a9dbb2 | 2017-07-25 09:12:37 -0500 | [diff] [blame] | 41 | TGTFMT = "obmc-chassis-poweron@{0}.target" |
Matt Spinler | f96194c | 2017-01-20 15:32:07 -0600 | [diff] [blame] | 42 | INSTFMT = "mboxd-reload@{0}.service" |
| 43 | FMT = "../${TMPL}:${TGTFMT}.wants/${INSTFMT}" |
| 44 | |
| 45 | SYSTEMD_SERVICE_${PN} += "mboxd.service" |
| 46 | SYSTEMD_SERVICE_${PN} += "mboxd-reload@.service" |
| 47 | SYSTEMD_LINK_${PN} += "${@compose_list(d, 'FMT', 'OBMC_CHASSIS_INSTANCES')}" |
Deepak Kodihalli | e1aa7fd | 2017-06-29 09:56:24 -0500 | [diff] [blame] | 48 | |
Patrick Williams | 67b3111 | 2017-08-09 16:45:03 -0500 | [diff] [blame] | 49 | # Enable virtual-pnor by MACHINE_FEATURE openpower-ubi-fs. |
| 50 | PACKAGECONFIG_append = "${@mf_enabled(d, 'openpower-ubi-fs', 'virtual-pnor')}" |
Patrick Williams | 6d641c5 | 2017-08-09 16:36:51 -0500 | [diff] [blame] | 51 | PACKAGECONFIG[virtual-pnor] = "--enable-virtual-pnor,--disable-virtual-pnor" |