From 6f13bd2461f88f9658a3d94bffe9550d05fa5da4 Mon Sep 17 00:00:00 2001 From: Phil Wise Date: Tue, 28 Nov 2017 08:22:26 +0100 Subject: Fix builds outside the .repo directory The repo tool searches up the directory tree to find the .repo directory. Cleanly handle the case where it can't find anything. --- classes/image_repo_manifest.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/classes/image_repo_manifest.bbclass b/classes/image_repo_manifest.bbclass index d508574..2012363 100644 --- a/classes/image_repo_manifest.bbclass +++ b/classes/image_repo_manifest.bbclass @@ -14,9 +14,9 @@ HOSTTOOLS_NONFATAL += " repo " # Write build information to target filesystem buildinfo () { if [ $(which repo) ]; then - repo manifest --revision-as-HEAD -o ${IMAGE_ROOTFS}${sysconfdir}/manifest.xml + repo manifest --revision-as-HEAD -o ${IMAGE_ROOTFS}${sysconfdir}/manifest.xml || echo "Android repo tool failed to run; manifest not copied" else - echo "Android repo tool not food; manifest not copied." + echo "Android repo tool not found; manifest not copied." fi } -- cgit v1.2.3-54-g00ecf