diff options
author | Leif Lindholm <leif.lindholm@linaro.org> | 2015-05-14 12:42:39 +0100 |
---|---|---|
committer | Leif Lindholm <leif.lindholm@linaro.org> | 2015-05-14 12:42:39 +0100 |
commit | 7f626ad36764d258ad4386d9bb18956d620a2815 (patch) | |
tree | c6353d6a991196250f7de4ac9e0ebb55740bdce1 | |
parent | 20d4d906bb253e3642c4568ed8c9eaa6a10e3850 (diff) |
Fixes for platform config file flag
Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>
-rwxr-xr-x | atf-build.sh | 22 | ||||
-rwxr-xr-x | uefi-build.sh | 10 |
2 files changed, 22 insertions, 10 deletions
diff --git a/atf-build.sh b/atf-build.sh index d61338a..8d52970 100755 --- a/atf-build.sh +++ b/atf-build.sh @@ -26,12 +26,16 @@ function build_platform return 1 fi - if [ X"`$TOOLS_DIR/parse-platforms.py -p $1 get -o build_atf`" = X"" ]; then + echo "PLATFORM_CONFIG: $PLATFORM_CONFIG" + echo -n "LEIF: " + $TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o build_atf + + if [ X"`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o build_atf`" = X"" ]; then echo "Platform '$1' is not configured to build ARM Trusted Firmware." return 0 fi - ATF_PLATFORM=`$TOOLS_DIR/parse-platforms.py -p $1 get -o atf_platform` + ATF_PLATFORM=`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o atf_platform` if [ X"$ATF_PLATFORM" = X"" ]; then ATF_PLATFORM=$1 fi @@ -39,14 +43,14 @@ function build_platform # # Read platform configuration # - PLATFORM_NAME="`$TOOLS_DIR/parse-platforms.py -p $1 get -o longname`" - PLATFORM_ARCH="`$TOOLS_DIR/parse-platforms.py -p $1 get -o arch`" - PLATFORM_IMAGE_DIR="`$TOOLS_DIR/parse-platforms.py -p $1 get -o uefi_image_dir`" + PLATFORM_NAME="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o longname`" + PLATFORM_ARCH="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o arch`" + PLATFORM_IMAGE_DIR="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o uefi_image_dir`" unset BL30 BL31 BL32 BL33 - BL30="`$TOOLS_DIR/parse-platforms.py -p $1 get -o scp_bin`" - BL31="`$TOOLS_DIR/parse-platforms.py -p $1 get -o el3_bin`" - BL32="`$TOOLS_DIR/parse-platforms.py -p $1 get -o tos_bin`" - BL33="$EDK2_DIR/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/`$TOOLS_DIR/parse-platforms.py -p $1 get -o uefi_bin`" + BL30="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o scp_bin`" + BL31="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o el3_bin`" + BL32="`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o tos_bin`" + BL33="$EDK2_DIR/Build/$PLATFORM_IMAGE_DIR/$BUILD_PROFILE/FV/`$TOOLS_DIR/parse-platforms.py $PLATFORM_CONFIG -p $1 get -o uefi_bin`" export BL33 # diff --git a/uefi-build.sh b/uefi-build.sh index 0201b18..486cf86 100755 --- a/uefi-build.sh +++ b/uefi-build.sh @@ -124,8 +124,16 @@ function usage if [ $1 == "-c" ]; then shift + case "$1" in + /*) + PLATFORM_CONFIG="-c $1" + ;; + *) + PLATFORM_CONFIG="-c `readlink -f \"$1\"`" + ;; + esac echo "Platform config file: '$1'" - PLATFORM_CONFIG="-c $1" + export PLATFORM_CONFIG shift fi |