diff --git a/config b/config index 33b98e9..0535768 100644 --- a/config +++ b/config @@ -28,7 +28,7 @@ export CPOPTS="-Os -g0 -fPIC" if [ -f ${ROOT}/dev ] then - export COPTS="-O0 -g3 -fPIC" + export COPTS="-O1 -g3 -fPIC" export QUIET="" else export COPTS="-Os -g0 -fPIC" diff --git a/python-wasm-sdk.sh b/python-wasm-sdk.sh index 03d283c..11138d0 100755 --- a/python-wasm-sdk.sh +++ b/python-wasm-sdk.sh @@ -21,7 +21,7 @@ ORIGIN=$(pwd) # 3.12 3.11 3.10 -BUILDS=${BUILDS:-3.12 3.11} +BUILDS=${BUILDS:-3.12 3.11 3.10} for PYBUILD in $BUILDS do diff --git a/scripts/cpython-build-emsdk-deps.sh b/scripts/cpython-build-emsdk-deps.sh index 47e54b8..3eca792 100755 --- a/scripts/cpython-build-emsdk-deps.sh +++ b/scripts/cpython-build-emsdk-deps.sh @@ -53,7 +53,7 @@ cd $ROOT # http://code.google.com/intl/en-US/speed/webp/index.html ALL="-fPIC -s USE_SDL=2 -sUSE_LIBPNG -sUSE_LIBJPEG $CPPFLAGS" -CNF="emconfigure ./configure --prefix=$PREFIX --with-pic --disable-shared" +CNF="emconfigure ./configure --prefix=$PREFIX --with-pic --disable-shared --host $(clang -dumpmachine)" # ncurses ncursesw @@ -110,17 +110,19 @@ then " else #[ -d SDL_image ] || git clone https://github.com/libsdl-org/SDL_image - if [ -d SDL2_image-2.5.1 ] + if [ -d SDL2_image-2.6.1 ] then echo " * build SDL2_image pre release " 1>&2 else - wget -c -q https://github.com/libsdl-org/SDL_image/releases/download/candidate-2.5.1/SDL2_image-2.5.1.tar.gz - tar xfz SDL2_image-2.5.1.tar.gz + #bad png+grayscale https://github.com/libsdl-org/SDL_image/releases/download/candidate-2.5.1/SDL2_image-2.5.1.tar.gz + wget -c -q https://github.com/libsdl-org/SDL_image/releases/download/release-2.6.1/SDL2_image-2.6.1.tar.gz + + tar xfz SDL2_image-2.6.1.tar.gz fi - pushd SDL2_image-2.5.1 + pushd SDL2_image-2.6.1 CFLAGS=$CPOPTS EMCC_CFLAGS="$ALL" CC=emcc $CNF \ --disable-sdltest --disable-jpg-shared --disable-png-shared #--disable-tif-shared diff --git a/scripts/cpython-build-emsdk.sh b/scripts/cpython-build-emsdk.sh index 08c247a..6efa070 100755 --- a/scripts/cpython-build-emsdk.sh +++ b/scripts/cpython-build-emsdk.sh @@ -244,10 +244,11 @@ fi cp -Rfv $ROOT/support/__EMSCRIPTEN__.patches/${PYBUILD}/. $PREFIX/lib/python${PYBUILD}/ cp -vf build/cpython-wasm/libpython${PYBUILD}.a prebuilt/emsdk/ - if [ -f build/cpython-wasm/Modules/expat/libexpat.a ] - then - cp build/cpython-wasm/Modules/expat/libexpat.a prebuilt/emsdk/libexpat${PYBUILD}.a - fi + for lib in $(find build/cpython-wasm/|grep lib.*.a$) + do + name=$(basename $lib .a) + cp $lib prebuilt/emsdk/${name}${PYBUILD}.a + done rmdir $PREFIX/lib/python${PYBUILD}/lib-dynload fi fi diff --git a/scripts/emsdk-fetch.sh b/scripts/emsdk-fetch.sh index a047ace..057cd8e 100755 --- a/scripts/emsdk-fetch.sh +++ b/scripts/emsdk-fetch.sh @@ -134,6 +134,7 @@ else fi END + cat emsdk/upstream/emscripten/emcc > emsdk/upstream/emscripten/em++ cat > emsdk/upstream/emscripten/emar <