Skip to content

Commit 797f770

Browse files
committed
fix stools/dist/pkgr path on prefix
1 parent e328668 commit 797f770

File tree

2 files changed

+12
-24
lines changed

2 files changed

+12
-24
lines changed

scripts/cpython-build-emsdk-deps.sh

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,23 +4,21 @@
44

55
. ./scripts/emsdk-fetch.sh
66

7-
HPFX=./devices/x86_64/usr/lib/python${PYBUILD}
7+
HPFX=./devices/$(arch)/usr/lib/python${PYBUILD}
8+
TPFX=./devices/emsdk/usr/lib/python${PYBUILD}
9+
10+
rm $TPFX/ensurepip/_bundled/setuptools-*.whl
811

912
for moveit in setuptools distutils _distutils _distutils_hack pkg_resources
1013
do
11-
if [ -d $HPFX/site-packages/${moveit} ]
12-
then
13-
echo "
14-
* migrating ${moveit}
14+
echo "
15+
* migrating ${moveit}
1516
"
16-
cp -rf $HPFX/site-packages/${moveit} $HPFX/
17-
cp -rf $HPFX/site-packages/${moveit}-* $HPFX/
18-
fi
17+
cp -rf $HPFX/site-packages/${moveit} $TPFX/
18+
cp -rf $HPFX/site-packages/${moveit}-* $TPFX/
1919
done
2020

2121

22-
23-
2422
# ../../devices/x86_64/usr/bin/python3-wasm -mpip install .
2523
# not working because python startup is skipped
2624

scripts/cpython-fetch.sh

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -59,14 +59,7 @@ then
5959
wget -q -c https://www.python.org/ftp/python/3.10.5/Python-3.10.5.tar.xz
6060
tar xf Python-3.10.5.tar.xz
6161

62-
if [ -d Python-3.10.5-pydk ]
63-
then
64-
PYPATCH=false
65-
ln -s Python-3.10.5 cpython
66-
else
67-
PYPATCH=true
68-
ln -s Python-3.10.5 cpython
69-
fi
62+
ln -s Python-3.10.5 cpython
7063

7164
NOPATCH=true
7265
export REBUILD=true
@@ -76,7 +69,7 @@ fi
7669
popd
7770

7871
# 3.10 is not wasm stable
79-
if [ -f support/__EMSCRIPTEN__.patches/${PYBUILD}.diff ]
72+
if [ -f support/__EMSCRIPTEN__.patches/${PYBUILD}-host.diff ]
8073
then
8174
pushd src/cpython 2>&1 >/dev/null
8275
patch -p1 < ../../support/__EMSCRIPTEN__.patches/${PYBUILD}-host.diff
@@ -89,17 +82,14 @@ fi
8982

9083
if $NOPATCH
9184
then
92-
echo "
93-
* assuming cpython tree already patched, press <enter>
94-
"
85+
echo -n
9586
else
96-
# do some patching
87+
# do some patching for 3.11+ to allow more shared libs
9788
pushd src/cpython 2>&1 >/dev/null
9889
patch -p1 < ../../support/__EMSCRIPTEN__.embed/cpython.diff
9990
popd 2>&1 >/dev/null
10091
fi
10192

102-
10393
echo "
10494
* fetched cpython source, status is :
10595
REBUILD=${REBUILD}

0 commit comments

Comments
 (0)