File tree Expand file tree Collapse file tree 5 files changed +11
-5
lines changed
Expand file tree Collapse file tree 5 files changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -67,6 +67,7 @@ export EMSDK_NUM_CORES=1
6767
6868# for shared modules
6969export PYDK_PYTHON_HOST_PLATFORM=wasm32-${WASM_FLAVOUR} -emscripten
70+ export PYDK_SYSCONFIG_PLATFORM=$( echo -n $PYDK_PYTHON_HOST_PLATFORM | cut -d- -f1) -$( echo -n $PYDK_PYTHON_HOST_PLATFORM | cut -d- -f3)
7071
7172# ============== wasi sdk ===============
7273
Original file line number Diff line number Diff line change 175175 # wget https://github.com/bytecodealliance/wasmtime/releases/download/v26.0.1/wasmtime-v26.0.1-$(arch)-$(PLATFORM).tar.xz \
176176# TODO: window only has a zip archive, better use wasmtime-py instead.
177177
178- wget https://github.com/bytecodealliance/wasmtime/releases/download/v27.0.0/wasmtime-v27.0.0-$( arch) -$( PLATFORM) .tar.xz \
178+ wget https://github.com/bytecodealliance/wasmtime/releases/download/v27.0.0/wasmtime-v27.0.0-$( arch) -${ PLATFORM} .tar.xz \
179179 -O-| xzcat| tar xfv -
180180 mv -vf $( find wasmtime* | grep /wasmtime$) ${SDKROOT} /devices/$( arch) /usr/bin
181181 fi
299299 > ${SDKROOT} /wasm32-${TARGET} -shell.sh
300300
301301 CPU=wasm32 TARGET=$TARGET \
302- PYDK_PYTHON_HOST_PLATFORM =wasm32-${TARGET} \
302+ PYDK_SYSCONFIG_PLATFORM =wasm32-${TARGET} \
303303 PREFIX=/opt/python-wasm-sdk/devices/wasisdk/usr \
304304 ./scripts/make-shells.sh
305305
Original file line number Diff line number Diff line change 175175 # wget https://github.com/bytecodealliance/wasmtime/releases/download/v26.0.1/wasmtime-v26.0.1-$(arch)-$(PLATFORM).tar.xz \
176176# TODO: window only has a zip archive, better use wasmtime-py instead.
177177
178- wget https://github.com/bytecodealliance/wasmtime/releases/download/v27.0.0/wasmtime-v27.0.0-$( arch) -$( PLATFORM) .tar.xz \
178+ wget https://github.com/bytecodealliance/wasmtime/releases/download/v27.0.0/wasmtime-v27.0.0-$( arch) -${ PLATFORM} .tar.xz \
179179 -O-| xzcat| tar xfv -
180180 mv -vf $( find wasmtime* | grep /wasmtime$) ${SDKROOT} /devices/$( arch) /usr/bin
181181 fi
299299 > ${SDKROOT} /wasm32-${TARGET} -shell.sh
300300
301301 CPU=wasm32 TARGET=$TARGET \
302- PYDK_PYTHON_HOST_PLATFORM =wasm32-${TARGET} \
302+ PYDK_SYSCONFIG_PLATFORM =wasm32-${TARGET} \
303303 PREFIX=/opt/python-wasm-sdk/devices/wasisdk/usr \
304304 ./scripts/make-shells.sh
305305
Original file line number Diff line number Diff line change @@ -348,6 +348,9 @@ include_dirs = $PREFIX/include
348348NUMPY
349349
350350
351+
352+
353+
351354. scripts/make-shells.sh
352355
353356# C/C++/cmake shell
381384
382385export SYS_PYTHON=${SYS_PYTHON}
383386export EMSDK_PYTHON=${SYS_PYTHON}
384- export _PYTHON_SYSCONFIGDATA_NAME=_sysconfigdata__emscripten_
387+ export _PYTHON_SYSCONFIGDATA_NAME=\$ {_PYTHON_SYSCONFIGDATA_NAME:-_sysconfigdata__emscripten_debug}
385388
386389END
387390
391+
388392# python shell
389393cat > $HOST_PREFIX /bin/python3-wasm << END
390394#!/bin/bash
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ export SDKROOT=${SDKROOT}
1010
1111export HOST_PREFIX=$HOST_PREFIX
1212export PYDK_PYTHON_HOST_PLATFORM=${PYDK_PYTHON_HOST_PLATFORM}
13+ export PYDK_SYSCONFIG_PLATFORM=${PYDK_SYSCONFIG_PLATFORM}
1314export PLATFORM_TRIPLET=${PYDK_PYTHON_HOST_PLATFORM}
1415
1516export PATH=${HOST_PREFIX} /bin:\$ PATH:${SDKROOT} /devices/${TARGET} /usr/bin:$( echo -n ${SDKROOT} /emsdk/node/* /bin)
You can’t perform that action at this time.
0 commit comments