blob: 80426b65a79fd122883c8e7579883750100f28bc [file] [log] [blame]
Brad Bishop4c3712f2019-04-24 19:44:31 -04001inherit systemd
Ed Tanous2c2a1c52018-01-29 10:56:52 -08002inherit useradd
3
4USERADD_PACKAGES = "${PN}"
5
6# add a user called httpd for the server to assume
Patrick Williams12fc9392021-08-06 09:16:53 -05007USERADD_PARAM:${PN} = "-r -s /usr/sbin/nologin bmcweb"
8GROUPADD_PARAM:${PN} = "web; redfish"
Ed Tanous2c2a1c52018-01-29 10:56:52 -08009
10LICENSE = "Apache-2.0"
Andrew Geisslere11f5e22021-07-20 18:10:59 +000011LIC_FILES_CHKSUM = "file://LICENSE;md5=175792518e4ac015ab6696d16c4f607e"
Ed Tanous2c2a1c52018-01-29 10:56:52 -080012
Andrew Geisslerbda00222022-02-02 21:30:58 +000013SRC_URI = "git://github.com/openbmc/bmcweb.git;branch=master;protocol=https;nobranch=1"
Ed Tanous2c2a1c52018-01-29 10:56:52 -080014
15PV = "1.0+git${SRCPV}"
Andrew Geisslerbda00222022-02-02 21:30:58 +000016SRCREV = "67df073b1f0950fdeafc6d30240d360bd162d0f8"
Ed Tanous2c2a1c52018-01-29 10:56:52 -080017
18S = "${WORKDIR}/git"
19
Andrew Geisslerec34cc62021-11-03 09:57:52 -050020inherit pkgconfig meson ptest
Ed Tanousa443c542021-02-26 13:28:37 -080021
22SRC_URI += " \
23 file://run-ptest \
24"
25
Ed Tanous07f48cc2021-02-22 10:49:30 -080026DEPENDS = " \
27 openssl \
28 zlib \
29 boost \
30 boost-url \
31 libpam \
32 sdbusplus \
33 gtest \
34 nlohmann-json \
35 libtinyxml2 \
Ed Tanousa443c542021-02-26 13:28:37 -080036 ${@bb.utils.contains('PTEST_ENABLED', '1', 'gtest', '', d)} \
37 ${@bb.utils.contains('PTEST_ENABLED', '1', 'gmock', '', d)} \
Ed Tanous07f48cc2021-02-22 10:49:30 -080038"
Ed Tanous2c2a1c52018-01-29 10:56:52 -080039
Patrick Williams12fc9392021-08-06 09:16:53 -050040RDEPENDS:${PN} += " \
Ed Tanous07f48cc2021-02-22 10:49:30 -080041 jsnbd \
Ed Tanous4073a4f2021-02-22 10:50:59 -080042 phosphor-mapper \
Ed Tanous07f48cc2021-02-22 10:49:30 -080043"
Adriana Kobylak7e0ff54f2018-12-13 11:01:05 -060044
Ed Tanousa443c542021-02-26 13:28:37 -080045do_install_ptest() {
46 install -d ${D}${PTEST_PATH}/test
Ed Tanousd7afac72021-04-01 16:09:06 -070047 cp -rf ${B}/*_test ${D}${PTEST_PATH}/test/
Ed Tanousa443c542021-02-26 13:28:37 -080048}
49
Patrick Williams12fc9392021-08-06 09:16:53 -050050FILES:${PN} += "${datadir}/** "
Ed Tanous2c2a1c52018-01-29 10:56:52 -080051
Ed Tanous2c2a1c52018-01-29 10:56:52 -080052
Ed Tanousa443c542021-02-26 13:28:37 -080053EXTRA_OEMESON = " \
54 --buildtype=minsize \
55 -Dtests=${@bb.utils.contains('PTEST_ENABLED', '1', 'enabled', 'disabled', d)} \
56 -Dyocto-deps=enabled \
57"
Ed Tanous2c2a1c52018-01-29 10:56:52 -080058
Patrick Williams12fc9392021-08-06 09:16:53 -050059SYSTEMD_SERVICE:${PN} += "bmcweb.service bmcweb.socket"
Ed Tanous2c2a1c52018-01-29 10:56:52 -080060
Manojkiran Edaf1f2e242020-09-02 21:48:12 +053061FULL_OPTIMIZATION = "-Os "