Remove USE_PYTHON3 option
The USE_PYTHON3 option has been defaulted to true for some time, and is no longer used. It was initially added to enable adoption of python3, we have long moved past needing to choose between python2 and python3, and default on python3. Also, since python2 is no longer supported, this makes the code cleaner to read. Change-Id: Ia9e62634c954446b0b47067fcdcd28cac49fbf4b
This commit is contained in:
parent
732852f31f
commit
eeeaa42b79
@ -76,10 +76,7 @@ cd $IPA_SOURCE_DIR
|
||||
rm -rf *.egg-info
|
||||
pwd
|
||||
|
||||
PYTHON_COMMAND="python"
|
||||
if [[ $USE_PYTHON3 == "True" ]]; then
|
||||
PYTHON_COMMAND="python3"
|
||||
fi
|
||||
PYTHON_COMMAND="python3"
|
||||
$PYTHON_COMMAND setup.py sdist --dist-dir "$BUILDDIR/tmp/localpip" --quiet
|
||||
|
||||
ls $BUILDDIR/tmp/localpip || true
|
||||
@ -150,10 +147,7 @@ cp $WORKDIR/build_files/fakeuname $BUILDDIR/tmp/overides/uname
|
||||
|
||||
sudo cp $WORKDIR/build_files/ntpdate $BUILDDIR/bin/ntpdate
|
||||
|
||||
PY_REQS="buildreqs_python2.lst"
|
||||
if [[ $USE_PYTHON3 == "True" ]]; then
|
||||
PY_REQS="buildreqs_python3.lst"
|
||||
fi
|
||||
PY_REQS="buildreqs_python3.lst"
|
||||
|
||||
# NOTE(rpittau) change ownership of the tce info dir to prevent writing issues
|
||||
sudo chown $TC:$STAFF $BUILDDIR/usr/local/tce.installed
|
||||
@ -162,10 +156,7 @@ while read line; do
|
||||
sudo chroot --userspec=$TC:$STAFF $BUILDDIR /usr/bin/env -i PATH=$CHROOT_PATH http_proxy=$http_proxy https_proxy=$https_proxy no_proxy=$no_proxy tce-load -wci $line
|
||||
done < <(paste $WORKDIR/build_files/$PY_REQS $WORKDIR/build_files/buildreqs.lst)
|
||||
|
||||
TINYIPA_PYTHON_EXE="python"
|
||||
if [[ $USE_PYTHON3 == "True" ]]; then
|
||||
TINYIPA_PYTHON_EXE="python3.9"
|
||||
fi
|
||||
TINYIPA_PYTHON_EXE="python3.9"
|
||||
|
||||
PIP_COMMAND="$TINYIPA_PYTHON_EXE -m pip"
|
||||
|
||||
|
@ -1,2 +0,0 @@
|
||||
python.tcz
|
||||
python-dev.tcz
|
@ -1 +0,0 @@
|
||||
python.tcz
|
@ -9,7 +9,6 @@ PIP_VERSION="21.3.1"
|
||||
|
||||
TINYIPA_REQUIRE_BIOSDEVNAME=${TINYIPA_REQUIRE_BIOSDEVNAME:-false}
|
||||
TINYIPA_REQUIRE_IPMITOOL=${TINYIPA_REQUIRE_IPMITOOL:-true}
|
||||
USE_PYTHON3=${USE_PYTHON3:-True}
|
||||
|
||||
# PYTHON_EXTRA_SOURCES_DIR_LIST is a csv list of python package dirs to include
|
||||
PYTHON_EXTRA_SOURCES_DIR_LIST=${PYTHON_EXTRA_SOURCES_DIR_LIST:-}
|
||||
|
@ -90,10 +90,7 @@ cp $WORKDIR/build_files/fakeuname $FINALDIR/tmp/overides/uname
|
||||
|
||||
sudo cp $WORKDIR/build_files/ntpdate $FINALDIR/bin/ntpdate
|
||||
sudo chmod 755 $FINALDIR/bin/ntpdate
|
||||
PY_REQS="finalreqs_python2.lst"
|
||||
if [[ $USE_PYTHON3 == "True" ]]; then
|
||||
PY_REQS="finalreqs_python3.lst"
|
||||
fi
|
||||
PY_REQS="finalreqs_python3.lst"
|
||||
|
||||
# NOTE(rpittau) change ownership of the tce info dir to prevent writing issues
|
||||
sudo chown $TC:$STAFF $FINALDIR/usr/local/tce.installed
|
||||
@ -140,12 +137,8 @@ fi
|
||||
# Ensure tinyipa picks up installed kernel modules
|
||||
$CHROOT_CMD depmod -a `$WORKDIR/build_files/fakeuname -r`
|
||||
|
||||
PIP_COMMAND="pip"
|
||||
TINYIPA_PYTHON_EXE="python"
|
||||
if [[ $USE_PYTHON3 == "True" ]]; then
|
||||
PIP_COMMAND="pip3"
|
||||
TINYIPA_PYTHON_EXE="python3"
|
||||
fi
|
||||
PIP_COMMAND="pip3"
|
||||
TINYIPA_PYTHON_EXE="python3"
|
||||
|
||||
# Install pip
|
||||
# NOTE(rpittau): pip MUST be the same version used in the build script or
|
||||
|
Loading…
Reference in New Issue
Block a user