Tools: resolve symlinks in IDF_PATH when installing

Use `pwd -P` to resolve any symlinks in the current directory path.
This makes the behavior in the shell script similar to the idf_tools.py
code, which calls `os.path.realpath()`.  Without this, multiple entries
can get created in the `idfInstalled` dictionary in idf-env.json, and
the installed targets and features are not fully present in all entries.
This results in a broken installation, where `export.sh` cannot set up
the environment correctly afterwards.
pull/9446/head
Adam Simpkins 2022-07-17 11:18:44 -07:00 zatwierdzone przez Marek Fiala
rodzic de3990f1c0
commit ff75c4f3b5
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -4,7 +4,7 @@ set -e
set -u
basedir=$(dirname "$0")
IDF_PATH=$(cd "${basedir}"; pwd)
IDF_PATH=$(cd "${basedir}"; pwd -P)
export IDF_PATH
echo "Detecting the Python interpreter"