这是indexloc提供的服务,不要输入任何密码
Skip to content

scripts: fix conflicts due to __pycache__ #23736

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions scripts/build/setup/termux_setup_python_pip.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
termux_setup_python_pip() {
unset PYTHONPYCACHEPREFIX
if [ "$TERMUX_ON_DEVICE_BUILD" = "true" ]; then
if [[ "$TERMUX_APP_PACKAGE_MANAGER" = "apt" && "$(dpkg-query -W -f '${db:Status-Status}\n' python-pip 2>/dev/null)" != "installed" ]] ||
[[ "$TERMUX_APP_PACKAGE_MANAGER" = "pacman" && ! "$(pacman -Q python-pip 2>/dev/null)" ]]; then
Expand Down
6 changes: 0 additions & 6 deletions scripts/build/termux_step_massage.sh
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,6 @@ termux_step_massage() {
done < <(find ./${ADDING_PREFIX}share/man -type l ! -iname \*.gz -print0)
fi

# Remove python-glibc package files that are created
# due to its launch during package compilation.
if [ "$TERMUX_PACKAGE_LIBRARY" = "glibc" ] && [ "$TERMUX_PKG_NAME" != "python-glibc" ]; then
rm -f ./${ADDING_PREFIX}lib/python${TERMUX_PYTHON_VERSION}/__pycache__/{base64,platform,quopri}.cpython-${TERMUX_PYTHON_VERSION//./}.pyc
fi

# Check so files were actually installed. Exclude
# share/doc/$TERMUX_PKG_NAME/ as a license file is always
# installed there.
Expand Down
2 changes: 2 additions & 0 deletions scripts/build/termux_step_setup_variables.sh
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,8 @@ termux_step_setup_variables() {
TERMUX_PKG_MESON_NATIVE=false
TERMUX_PKG_CMAKE_CROSSCOMPILING=true

export PYTHONPYCACHEPREFIX=$TERMUX_COMMON_CACHEDIR-$TERMUX_ARCH

unset CFLAGS CPPFLAGS LDFLAGS CXXFLAGS
unset TERMUX_MESON_ENABLE_SOVERSION # setenv to enable SOVERSION suffix for shared libs built with Meson
}