From 4f18deb87f55096fae8e39a926680c0ec7e2bda9 Mon Sep 17 00:00:00 2001 From: Michael Marineau Date: Sun, 25 Aug 2013 00:16:44 -0400 Subject: [PATCH] fix(build_image): Add support for using git in dev images. If git is installed via coreos-dev in the STATE partition it will need some help finding its install location since it was built thinking it would be installed in /usr rather than /usr/local. --- build_library/dev_image_util.sh | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/build_library/dev_image_util.sh b/build_library/dev_image_util.sh index 3401316778..543cb46f36 100755 --- a/build_library/dev_image_util.sh +++ b/build_library/dev_image_util.sh @@ -41,9 +41,6 @@ install_dev_packages() { sudo mkdir -p ${root_fs_dir}/etc/make.profile - # Re-run ldconfig to fix /etc/ldconfig.so.cache. - sudo /sbin/ldconfig -r "${root_fs_dir}" - # Mark the image as a developer image (input to chromeos_startup). # TODO(arkaitzr): Remove this file when applications no longer rely on it # (crosbug.com/16648). The preferred way of determining developer mode status @@ -88,6 +85,16 @@ EOF sudo chmod a+rx "${path}" fi + # If git is installed in the state partition it needs some help + if [[ -x "${root_fs_dir}/usr/local/bin/git" ]]; then + sudo_clobber "${root_fs_dir}/etc/env.d/99git" <