Commit 560f9458 authored by Enrico Scholz's avatar Enrico Scholz

make: allow to pass extra env to bitbake

+ some minor cleanups
Signed-off-by: Enrico Scholz's avatarEnrico Scholz <enrico.scholz@sigma-chemnitz.de>
parent 14d92928
......@@ -16,13 +16,15 @@ DEPLOY_DIR = ${BUILDDIR}/tmp/deploy
top_srcdir = $(dir $(abspath $(firstword $(MAKEFILE_LIST))))
top_builddir = $(abspath .)
SHELL_PS1 ?= [\[\033[1;31m\]${PROJECT}\[\033[0;39m\]|\u@\h \W]\044\040
SHELL_PS1 ?= [\[\033[1;31m\]${PROJECT}\[\033[0;39m\]|\u@\h \W]\044\040
META_SIGMA_DIR = sources/de.sigma-chemnitz.core
BB_ENV_EXTRAWHITE = BB_GENERATE_MIRROR_TARBALLS
export BB_ENV_EXTRAWHITE
_bitbake = env ${EXTRA_ENV} ${BITBAKE} ${BITBAKE_FLAGS}
## include local customizations
-include ${HOME}/.config/openembedded/toplevel.mk
-include $(HOME)/.config/openembedded/${PROJECT}.mk
......@@ -31,11 +33,13 @@ init_build_env = \
'.' $(top_srcdir)/sources/poky/oe-init-build-env \
$(abspath $1) $(top_srcdir)/sources/poky/bitbake
_bitbake = ${BITBAKE} ${BITBAKE_FLAGS}
# Usage: $(call bitbake,<builddir>,<recipes>*)
#
# Uses default ${MACHINE}
bitbake = \
$(call bitbake_machine,$1,$2,${MACHINE})
# Usage: $(call bitbake_machine,<builddir>,<recipes>*,<machine>)
bitbake_machine = \
$(call init_build_env,$1) && env MACHINE='$3' $(_bitbake) $O $2
......@@ -70,7 +74,7 @@ mrproper: clean
shell: export _PS1=${SHELL_PS1}
shell:
$(call init_build_env,$(BUILDDIR)) && cd $(abspath .) && env PS1="$$_PS1" bash
$(call init_build_env,$(BUILDDIR)) && cd $(abspath .) && env ${EXTRA_ENV} MACHINE='${MACHINE}' PS1="$$_PS1" bash
start-nfsd stop-nfsd status-nfsd:%-nfsd:
${MAKE} -f ${META_SIGMA_DIR}/mk/nfsd.mk BUILDVARS_DATA='${DEPLOY_DIR}/buildvars/${MACHINE}/${IMAGE}.mk' $*-daemon
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment