diff options
author | Laurentiu Palcu <laurentiu.palcu@intel.com> | 2012-09-17 11:19:08 +0300 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-09-21 11:10:22 +0100 |
commit | bd73a4b615f51d6a2330fcd21a33dcdd863497d2 (patch) | |
tree | 7f975a2552e1452c0c7279b47db378f7a83cd99d /meta/recipes-devtools/installer | |
parent | b9bd372666af10f5ff0635885f23a03a0daae2b2 (diff) | |
download | poky-bd73a4b615f51d6a2330fcd21a33dcdd863497d2.tar.gz |
SDK: fix installation into symlinked directories
The SDK installation scripts should not canonicalize symlinked
directories because the entire relocation would be done to the directory
to which the symlink points. Instead, if the installation is a symlink,
use that path to relocate the binaries.
For example, if we have the following symlink: /opt/sdk -> ~/my/test/sdk
the binaries will be relocated to /opt/sdk not ~/my/test/sdk as it is
done now.
[YOCTO #3102]
(From OE-Core rev: 9e6a25e2e9a7f37c3baa0b2949a43ac4127868da)
Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/installer')
-rwxr-xr-x | meta/recipes-devtools/installer/adt-installer/adt_installer | 6 | ||||
-rwxr-xr-x | meta/recipes-devtools/installer/adt-installer/scripts/adt_installer_internal | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/meta/recipes-devtools/installer/adt-installer/adt_installer b/meta/recipes-devtools/installer/adt-installer/adt_installer index 2d252b72ad..0be5a1d607 100755 --- a/meta/recipes-devtools/installer/adt-installer/adt_installer +++ b/meta/recipes-devtools/installer/adt-installer/adt_installer | |||
@@ -340,7 +340,11 @@ if [ "$INSTALL_FOLDER" = "" ]; then | |||
340 | fi | 340 | fi |
341 | 341 | ||
342 | eval INSTALL_FOLDER=$INSTALL_FOLDER | 342 | eval INSTALL_FOLDER=$INSTALL_FOLDER |
343 | export INSTALL_FOLDER=$(readlink -m $INSTALL_FOLDER) | 343 | if [ -d $INSTALL_FOLDER ]; then |
344 | export INSTALL_FOLDER=$(cd $INSTALL_FOLDER; pwd) | ||
345 | else | ||
346 | export INSTALL_FOLDER=$(readlink -m $INSTALL_FOLDER) | ||
347 | fi | ||
344 | 348 | ||
345 | clear | 349 | clear |
346 | 350 | ||
diff --git a/meta/recipes-devtools/installer/adt-installer/scripts/adt_installer_internal b/meta/recipes-devtools/installer/adt-installer/scripts/adt_installer_internal index f113aa4b80..76acaa7e8a 100755 --- a/meta/recipes-devtools/installer/adt-installer/scripts/adt_installer_internal +++ b/meta/recipes-devtools/installer/adt-installer/scripts/adt_installer_internal | |||
@@ -207,7 +207,7 @@ $SUDO scripts/relocate_sdk_tmp.py $INSTALL_FOLDER $dl_path $executable_files | |||
207 | check_result | 207 | check_result |
208 | 208 | ||
209 | # replace /opt/${DISTRO}/${SDK_VERSION} with the install folder in all configs | 209 | # replace /opt/${DISTRO}/${SDK_VERSION} with the install folder in all configs |
210 | env_setup_script=$(find $NATIVE_INSTALL_DIR -name "environment-setup-*") | 210 | env_setup_script=$(find $NATIVE_INSTALL_DIR/ -name "environment-setup-*") |
211 | $SUDO sed -i -e "s:$DEFAULT_INSTALL_FOLDER:$NATIVE_INSTALL_DIR:g" $env_setup_script | 211 | $SUDO sed -i -e "s:$DEFAULT_INSTALL_FOLDER:$NATIVE_INSTALL_DIR:g" $env_setup_script |
212 | 212 | ||
213 | find $OECORE_NATIVE_SYSROOT -type f -exec file '{}' \;|grep ":.*ASCII.*text"|cut -d':' -f1|\ | 213 | find $OECORE_NATIVE_SYSROOT -type f -exec file '{}' \;|grep ":.*ASCII.*text"|cut -d':' -f1|\ |