From 5cc0ac1594f064b8338751e05a745c111a11924a Mon Sep 17 00:00:00 2001 From: Trevor Woerner Date: Fri, 20 Feb 2015 14:57:48 -0500 Subject: functions.sh: hook for local download directory If the user defines the environment variable "LOCALDLDIR" before calling init-and-build.sh, conf/site.conf will have a DL_DIR variable added to it defined as the string in $LOCALDLDIR. This allows a user to specify a local, pre-existing download directory to use when performing local OE builds instead of having a separate download area for each such build. Change-Id: I7e116e153da898d27ba2b2bb62d5858ab3c97fc3 Signed-off-by: Trevor Woerner --- functions.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/functions.sh b/functions.sh index 462d6bd..0df7cf1 100755 --- a/functions.sh +++ b/functions.sh @@ -24,6 +24,7 @@ show_setup() echo "Manifest groups: $manifest_groups" echo "Init env: $init_env" echo "Verbose: $bitbake_verbose" + echo "Local download directory: $LOCALDLDIR" if [ $external_url ]; then echo "External toolchain URL: $external_url" @@ -176,6 +177,15 @@ fi # enable a distro feature that is compatible with the minimal goal we have echo 'DISTRO_FEATURES = "pam x11 alsa argp ext2 largefile usbgadget usbhost xattr nfs zeroconf opengl ${DISTRO_FEATURES_LIBC} ${DISTRO_FEATURES_INITMAN}"' >>conf/site.conf + +# allow the user to specify a local, pre-existing download directory +if [ -n "$LOCALDLDIR" ]; then + cat >> conf/site.conf <