From 0b4f549c37acc2826c9a94bb61d1e6591c74fde5 Mon Sep 17 00:00:00 2001 From: Abhishek Patel Date: Mon, 19 Jul 2021 08:24:26 -0500 Subject: Webui-vue builds with IBM environment variables To build webui-vue with IBM theme, need to set IBM environment variable during the webui-vue build. Yocto has many layers of abstraction. To specify IBM environment variables, we use --mode npm build Commandline argument, which helps to set IBM environment variables. We need to set this environment variable during IBM build only. So created webui-vue_%.bbappend file, which sets that env variable only for IBM builds. More information could be found at https://github.com/openbmc/webui-vue/blob/master/docs/customization/build.md Tested with IBM build. Signed-off-by: Abhishek Patel Change-Id: I6ff997a94eb59b695741ccca95acb7693a4714ff --- meta-ibm/recipes-phosphor/webui/webui-vue_%.bbappend | 4 ++++ meta-phosphor/recipes-phosphor/webui/webui-vue_git.bb | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 meta-ibm/recipes-phosphor/webui/webui-vue_%.bbappend diff --git a/meta-ibm/recipes-phosphor/webui/webui-vue_%.bbappend b/meta-ibm/recipes-phosphor/webui/webui-vue_%.bbappend new file mode 100644 index 000000000..fe11d70df --- /dev/null +++ b/meta-ibm/recipes-phosphor/webui/webui-vue_%.bbappend @@ -0,0 +1,4 @@ +FILESEXTRAPATHS:prepend := "${THISDIR}/${BPN}:" + +EXTRA_OENPM:witherspoon-tacoma = "-- --mode ibm" +EXTRA_OENPM:p10bmc = "-- --mode ibm" diff --git a/meta-phosphor/recipes-phosphor/webui/webui-vue_git.bb b/meta-phosphor/recipes-phosphor/webui/webui-vue_git.bb index 3059a55af..e55072303 100644 --- a/meta-phosphor/recipes-phosphor/webui/webui-vue_git.bb +++ b/meta-phosphor/recipes-phosphor/webui/webui-vue_git.bb @@ -30,11 +30,13 @@ export CXXFLAGS = "${BUILD_CXXFLAGS}" FILES:${PN} += "${datadir}/www/*" +EXTRA_OENPM ?= "" + do_compile () { cd ${S} rm -rf node_modules npm --loglevel info --proxy=${http_proxy} --https-proxy=${https_proxy} install - npm run build + npm run build ${EXTRA_OENPM} } do_install () { -- cgit v1.2.3