Skip to content

Commit

Permalink
3.1.57.1bi
Browse files Browse the repository at this point in the history
  • Loading branch information
pmp-p committed Mar 25, 2024
1 parent e1d8c94 commit 36daddd
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
1 change: 1 addition & 0 deletions config
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ mkdir -p ${SDKROOT}/build/pycache ${SDKROOT}/build/cache
export XDG_CACHE_HOME=$(realpath ${SDKROOT}/build/cache)
export PYTHONPYCACHEPREFIX=${PYTHONPYCACHEPREFIX:-$(realpath ${SDKROOT}/build/pycache)}

export WHEELS=/data/git/archives/repo

export HOME=${SDKROOT}

Expand Down
20 changes: 12 additions & 8 deletions scripts/cpython-build-emsdk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,17 +65,10 @@ else
#TODO: check if export PATH=${HOST_PREFIX}/bin:$PATH is really set to avoid system python with different bytecode
#and no loder lib-dynload in the way.

if echo $PYBUILD|grep 13$
then
GIL="--disable-gil"
else
GIL=""
fi


EMCC_CFLAGS="-O0 -g0 -fPIC" CFLAGS="-O0 -g0 -fPIC" CC=${SDKROOT}/emsdk/upstream/emscripten/emcc \
emconfigure $ROOT/src/libffi/configure --host=wasm32-bi-emscripten \
$GIL \
--prefix=$PREFIX --enable-static --disable-shared --disable-dependency-tracking\
--disable-builddir --disable-multi-os-directory --disable-raw-api --disable-docs

Expand Down Expand Up @@ -203,11 +196,22 @@ END
# please let compiler/user decide what to do with wasm CPU.
sed -i 's|-sWASM_BIGINT||g' configure
sed -i 's|-sWASM_BIGINT||g' configure.ac

# do not mess with wasm sysconfig name
if echo $PYBUILD|grep -q 13$
then
GIL="--disable-gil"
sed -i 's|{ABIFLAGS}t|{ABIFLAGS}|g' configure
sed -i 's|{ABIFLAGS}t|{ABIFLAGS}|g' configure.ac
else
GIL=""
fi

popd


PKG_CONFIG_PATH="${PREFIX}/lib/pkgconfig" CONFIG_SITE=$ROOT/src/cpython${PYBUILD}/Tools/wasm/config.site-wasm32-pydk \
emconfigure $ROOT/src/cpython${PYBUILD}/configure -C --with-emscripten-target=browser \
emconfigure $ROOT/src/cpython${PYBUILD}/configure -C --with-emscripten-target=browser $GIL \
--cache-file=${PYTHONPYCACHEPREFIX}/config.cache \
--enable-wasm-dynamic-linking $TESTSUITE\
--host=$PYDK_PYTHON_HOST_PLATFORM \
Expand Down

0 comments on commit 36daddd

Please sign in to comment.