diff options
-rw-r--r-- | meta/classes/populate_sdk_base.bbclass | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/meta/classes/populate_sdk_base.bbclass b/meta/classes/populate_sdk_base.bbclass index ac34c32b52..f1fcde6f44 100644 --- a/meta/classes/populate_sdk_base.bbclass +++ b/meta/classes/populate_sdk_base.bbclass | |||
@@ -143,11 +143,20 @@ else | |||
143 | target_sdk_dir=$(readlink -m $target_sdk_dir) | 143 | target_sdk_dir=$(readlink -m $target_sdk_dir) |
144 | fi | 144 | fi |
145 | 145 | ||
146 | printf "You are about to install the SDK to \"$target_sdk_dir\". Proceed[Y/n]?" | 146 | if [ -e "$target_sdk_dir/environment-setup-${REAL_MULTIMACH_TARGET_SYS}" ]; then |
147 | echo "The directory \"$target_sdk_dir\" already contains a SDK for this architecture." | ||
148 | printf "If you continue, existing files will be overwritten! Proceed[y/N]?" | ||
149 | |||
150 | default_answer="n" | ||
151 | else | ||
152 | printf "You are about to install the SDK to \"$target_sdk_dir\". Proceed[Y/n]?" | ||
153 | |||
154 | default_answer="y" | ||
155 | fi | ||
147 | read answer | 156 | read answer |
148 | 157 | ||
149 | if [ "$answer" = "" ]; then | 158 | if [ "$answer" = "" ]; then |
150 | answer="y" | 159 | answer="$default_answer" |
151 | fi | 160 | fi |
152 | 161 | ||
153 | if [ "$answer" != "Y" -a "$answer" != "y" ]; then | 162 | if [ "$answer" != "Y" -a "$answer" != "y" ]; then |
@@ -188,7 +197,7 @@ find $native_sysroot -type f -exec file '{}' \;|grep ":.*ASCII.*text"|cut -d':' | |||
188 | 197 | ||
189 | # change all symlinks pointing to ${SDKPATH} | 198 | # change all symlinks pointing to ${SDKPATH} |
190 | for l in $(find $native_sysroot -type l); do | 199 | for l in $(find $native_sysroot -type l); do |
191 | ln -sf $(readlink $l|sed -e "s:$DEFAULT_INSTALL_DIR:$target_sdk_dir:") $l | 200 | ln -sfn $(readlink $l|sed -e "s:$DEFAULT_INSTALL_DIR:$target_sdk_dir:") $l |
192 | done | 201 | done |
193 | 202 | ||
194 | echo done | 203 | echo done |