From 8cd9f905fe9a7ba21d792dbb3961d9997c2dd3b7 Mon Sep 17 00:00:00 2001 From: Tadao Tanikawa Date: Tue, 19 Jan 2016 13:55:51 +0900 Subject: Provide template configuration for each machine or board In previous patch, meta-intel layer is added to BBLAYERS for both QEMU(qemux86/qemux86-64) and Minnowboard MAX(intel-corei7-64) although QEMU target doesn't need it. It is preffered to prepare a template configuration for each machine or board. Change-Id: I19bd4e66e8375a1760d9850f4a056651ae0fa6ca Signed-off-by: Tadao Tanikawa --- scripts/envsetup.sh | 33 +++++++++++++++++++++------------ 1 file changed, 21 insertions(+), 12 deletions(-) (limited to 'scripts') diff --git a/scripts/envsetup.sh b/scripts/envsetup.sh index adde54010..89713d968 100644 --- a/scripts/envsetup.sh +++ b/scripts/envsetup.sh @@ -5,7 +5,14 @@ if [ -z $1 ]; then return 1 fi -case "$1" in +MACHINE="$1" + +# set template conf for each +if [ -z "$TEMPLATECONF" ]; then + TEMPLATECONF="$PWD/meta-agl-demo/templates/$MACHINE/conf" +fi + +case "$MACHINE" in "porter") # setup proprietary gfx drivers and multimedia packages COPY_MM_SCRIPT=meta-renesas/meta-rcar-gen2/scripts/setup_mm_packages.sh @@ -18,28 +25,30 @@ case "$1" in fi fi - # template conf for R-Car2 M2 Porter board - TEMPLATECONF=$PWD/meta-renesas/meta-rcar-gen2/conf + if [ ! -d "$TEMPLATECONF" ]; then + # set template conf for R-Car2 M2 Porter board + TEMPLATECONF="$PWD/meta-renesas/meta-rcar-gen2/conf" + fi ;; "intel-corei7-64") - # template conf for MinnowBoard MAX - TEMPLATECONF=$PWD/meta-agl-demo/conf + ;; + "qemux86") ;; "qemux86-64") - # template conf for QEMU x86-64 - TEMPLATECONF=$PWD/meta-agl-demo/conf ;; *) # nothing to do here - echo "WARN: '$1' is not tested by AGL Distro" - if [ -z $TEMPLATECONF ]; then - TEMPLATECONF=$PWD/meta-agl-demo/conf - fi + echo "WARN: '$MACHINE' is not tested by AGL Distro" ;; esac echo "envsetup: Set '$1 as MACHINE." -export MACHINE="$1" +export MACHINE + +if [ ! -d "$TEMPLATECONF" ]; then + # Allow to use templates at meta-agl-demo/conf + TEMPLATECONF="$PWD/meta-agl-demo/conf" +fi echo "envsetup: Using templates for local.conf & bblayers.conf from :" echo " '$TEMPLATECONF'" -- cgit 1.2.3-korg