From c773f0ceb10aa1d98347fbec689836cca8c53b7d Mon Sep 17 00:00:00 2001 From: klzgrad Date: Sat, 3 Oct 2020 16:11:27 +0800 Subject: [PATCH] Revert "Use python3 in build if python2 is not found" This reverts commit b63fbe9d8ad789d21c7b0d645b676d90245743ac. Sysroot scripts still use python2 --- src/build.sh | 4 ++-- src/get-clang.sh | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/build.sh b/src/build.sh index 073018be03..55db8a481f 100755 --- a/src/build.sh +++ b/src/build.sh @@ -99,9 +99,9 @@ fi rm -rf "./$out" mkdir -p out -python=$(which python2 2>/dev/null || which python 2>/dev/null || which python3 2>/dev/null) +python2=$(which python2 2>/dev/null || which python 2>/dev/null) export DEPOT_TOOLS_WIN_TOOLCHAIN=0 -./gn/out/gn gen "$out" --args="$flags $EXTRA_FLAGS" --script-executable=$python +./gn/out/gn gen "$out" --args="$flags $EXTRA_FLAGS" --script-executable=$python2 ninja -C "$out" naive diff --git a/src/get-clang.sh b/src/get-clang.sh index 3a518fd132..f3d6321063 100755 --- a/src/get-clang.sh +++ b/src/get-clang.sh @@ -26,8 +26,8 @@ if [ "$ARCH" = Linux ]; then fi # Clang -python=$(which python2 2>/dev/null || which python 2>/dev/null || which python3 2>/dev/null) -CLANG_REVISION=$($python tools/clang/scripts/update.py --print-revision) +python2=$(which python2 2>/dev/null || which python 2>/dev/null) +CLANG_REVISION=$($python2 tools/clang/scripts/update.py --print-revision) CLANG_PATH="clang-$CLANG_REVISION.tgz" case "$ARCH" in Linux) clang_url="https://commondatastorage.googleapis.com/chromium-browser-clang/Linux_x64/$CLANG_PATH";;