diff options
author | Leif Lindholm <leif.lindholm@linaro.org> | 2018-09-03 20:18:05 +0100 |
---|---|---|
committer | Leif Lindholm <leif.lindholm@linaro.org> | 2018-09-03 20:18:05 +0100 |
commit | 8b269a6f3ea8c3f4e7e2751f890c6d80acfb6b93 (patch) | |
tree | 376e173deeff80dd95676aaa760b3fc26ed14b2f | |
parent | b7d1ab39be11301013a55c74419f7e6b7557d005 (diff) |
build.sh: add separate handling of "executable" output
Executable output (UEFI drivers or applications) are not placed
in the Build directory in the same way as flash images generated
with GenFd.
The uefi-tools parse-platforms.py script has had a new command
added 'executables', corresponding to the 'images' command, but
giving output useable for executables (listed at EXEC_FILES in
the platform config file). Add support for that in the output
copying bit.
Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>
-rwxr-xr-x | build.sh | 40 |
1 files changed, 29 insertions, 11 deletions
@@ -147,22 +147,40 @@ copy_images() echo PLATFORM=$platform IMAGE_DIR="`uefi-tools/parse-platforms.py $CONFIG_OPTIONS -p $platform -o UEFI_IMAGE_DIR get`" IMAGES="`uefi-tools/parse-platforms.py $CONFIG_OPTIONS -p $platform images`" + EXECUTABLES="`uefi-tools/parse-platforms.py $CONFIG_OPTIONS -p $platform executables`" DEBUG_DIR="$PWD/out/debug/$platform/" RELEASE_DIR="$PWD/out/release/$platform/" echo "Copying images for platform '$platform':" - pushd Build/$IMAGE_DIR/RELEASE_*/FV/ >/dev/null 2>&1 - if [ $? -eq 0 ]; then - mkdir -p "$RELEASE_DIR" - cp `eval echo $IMAGES` $RELEASE_DIR - popd >/dev/null + if [ -n "$IMAGES" ]; then + pushd Build/$IMAGE_DIR/RELEASE_*/FV/ >/dev/null 2>&1 + if [ $? -eq 0 ]; then + mkdir -p "$RELEASE_DIR" + cp `eval echo $IMAGES` $RELEASE_DIR + popd >/dev/null + fi + + pushd Build/$IMAGE_DIR/DEBUG_*/FV/ >/dev/null 2>&1 + if [ $? -eq 0 ]; then + mkdir -p "$DEBUG_DIR" + cp `eval echo $IMAGES` $DEBUG_DIR + popd >/dev/null + fi fi - - pushd Build/$IMAGE_DIR/DEBUG_*/FV/ >/dev/null 2>&1 - if [ $? -eq 0 ]; then - mkdir -p "$DEBUG_DIR" - cp `eval echo $IMAGES` $DEBUG_DIR - popd >/dev/null + if [ -n "$EXECUTABLES" ]; then + pushd Build/$IMAGE_DIR/RELEASE_*/ >/dev/null 2>&1 + if [ $? -eq 0 ]; then + mkdir -p "$RELEASE_DIR" + cp `eval echo $EXECUTABLES` $RELEASE_DIR + popd >/dev/null + fi + + pushd Build/$IMAGE_DIR/DEBUG_*/ >/dev/null 2>&1 + if [ $? -eq 0 ]; then + mkdir -p "$DEBUG_DIR" + cp `eval echo $EXECUTABLES` $DEBUG_DIR + popd >/dev/null + fi fi done } |