mirror of
https://github.com/pyenv/pyenv.git
synced 2024-11-21 20:47:00 -05:00
Use version suffixed executable (e.g. python3.4
) for internal use of python (#255)
This commit is contained in:
parent
45b45bcf25
commit
eef8ac2701
1 changed files with 17 additions and 1 deletions
|
@ -1687,9 +1687,25 @@ if [[ "Darwin" == "$(uname -s)" ]]; then
|
|||
fi
|
||||
fi
|
||||
|
||||
python_bin_suffix() {
|
||||
local version_name version_info
|
||||
case "$1" in
|
||||
2.* | 3.* )
|
||||
version_name="$1"
|
||||
version_info=(${version_name//./ })
|
||||
echo "${version_info[0]}.${version_info[1]}"
|
||||
;;
|
||||
stackless-2.* | stackless-3.* )
|
||||
version_name="${1#stackless-}"
|
||||
version_info=(${version_name//./ })
|
||||
echo "${version_info[0]}.${version_info[1]}"
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
SEED="$(date "+%Y%m%d%H%M%S").$$"
|
||||
LOG_PATH="${TMP}/python-build.${SEED}.log"
|
||||
PYTHON_BIN="${PREFIX_PATH}/bin/python"
|
||||
PYTHON_BIN="${PREFIX_PATH}/bin/python$(python_bin_suffix "${DEFINITION_PATH##*/}")"
|
||||
CWD="$(pwd)"
|
||||
|
||||
if [ -z "$PYTHON_BUILD_BUILD_PATH" ]; then
|
||||
|
|
Loading…
Reference in a new issue