build-setup.sh: prevent git clone when only building container
When someone wants to just build the container, there's no need to clone
openbmc.
Tested:
- Confirmed no clone when CONTAINER_ONLY set to true
- Confirmed a clone when CONTAINER_ONLY is not set
Change-Id: I7765c8511cffe2db9b94f3e8e5815300fd9c65f1
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
diff --git a/build-setup.sh b/build-setup.sh
index d0b0431..b4e678d 100755
--- a/build-setup.sh
+++ b/build-setup.sh
@@ -124,7 +124,7 @@
echo "Build started, $(date)"
# If the obmc_dir directory doesn't exist clone it in
-if [ ! -d "${obmc_dir}" ]; then
+if [ ! -d "${obmc_dir}" ] && [ "${container_only}" = false ]; then
echo "Clone in openbmc master to ${obmc_dir}"
git clone https://github.com/openbmc/openbmc "${obmc_dir}"
fi