Skip to content
Merged
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
4 changes: 2 additions & 2 deletions .buildconfig
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
PG_VERSION=16.4
SDK_VERSION=3.1.72.3bi
WASI_SDK_VERSION=24.0.4
SDK_VERSION=3.1.74.2bi
WASI_SDK_VERSION=24.0.5
SDKROOT=/opt/python-wasm-sdk
2 changes: 1 addition & 1 deletion .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ jobs:
issues: write # to post issue comments (changesets/action)
pull-requests: write # to create pull request (changesets/action)
name: Make a PR or publish
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
needs: [build-wasm-postgres]
steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/trigger_buildkite_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ on:
jobs:
build:
name: Build Docker image
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
steps:
- name: Trigger a Buildkite Build on Push using v2.0.0
uses: buildkite/trigger-pipeline-action@v2.0.0
Expand Down
20 changes: 13 additions & 7 deletions cibuild/sdk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,19 @@ fi

if [ -f $SDKROOT/VERSION ]
then
echo "Using installed sdk from $SDKROOT"
echo "Using tested sdk from $SDKROOT"
else
echo "Installing sdk to $SDKROOT"
SDK_ARCHIVE=${SDK_ARCHIVE:-python3.13-wasm-sdk-Ubuntu-22.04.tar.lz4}
WASI_SDK_ARCHIVE=${WASI_SDK_ARCHIVE:-python3.13-wasi-sdk-Ubuntu-22.04.tar.lz4}
if $CI
if [ -d $SDKROOT/emsdk ]
then
echo "if sdk fails here, check .yml files and https://github.com/pygame-web/python-wasm-sdk releases"
echo "Using installed sdk from $SDKROOT"
else
echo "Installing sdk to $SDKROOT"
SDK_ARCHIVE=${SDK_ARCHIVE:-python3.13-wasm-sdk-Ubuntu-22.04.tar.lz4}
WASI_SDK_ARCHIVE=${WASI_SDK_ARCHIVE:-python3.13-wasi-sdk-Ubuntu-22.04.tar.lz4}
if $CI
then
echo "if sdk fails here, check .yml files and https://github.com/pygame-web/python-wasm-sdk releases"
fi
echo https://github.com/pygame-web/python-wasm-sdk/releases/download/$SDK_VERSION/$SDK_ARCHIVE
curl -sL --retry 5 https://github.com/pygame-web/python-wasm-sdk/releases/download/$SDK_VERSION/$SDK_ARCHIVE | tar xvP --use-compress-program=lz4 | pv -p -l -s 46000 >/dev/null
echo https://github.com/pygame-web/python-wasi-sdk/releases/download/$WASI_SDK_VERSION/$WASI_SDK_ARCHIVE
Expand Down Expand Up @@ -71,7 +75,7 @@ fi

int main(int argc, char**arv){
#if defined(__EMSCRIPTEN__)
# if defined(PYDK_STATIC)
# if defined(__PYDK__)
printf("pydk" " %d.%d.%d\n",__EMSCRIPTEN_major__, __EMSCRIPTEN_minor__, __EMSCRIPTEN_tiny__);
# else
printf("emsdk" " %d.%d.%d\n",__EMSCRIPTEN_major__, __EMSCRIPTEN_minor__, __EMSCRIPTEN_tiny__);
Expand All @@ -97,10 +101,12 @@ int main(int argc, char**arv){
END

EMCC_TRACE=true DEBUG_PATTERN=* ${SDKROOT}/emsdk/upstream/emscripten/emcc -sASSERTIONS=0 -sENVIRONMENT=node,web -sGLOBAL_BASE=32B -o hello_em.html /tmp/sdk/hello_em.c
$SDKROOT/emsdk/node/*.*.*64bit/bin/node hello_em.js
$SDKROOT/emsdk/node/*.*.*64bit/bin/node hello_em.js |grep ^pydk > $SDKROOT/VERSION || exit 80
rm hello_em.js hello_em.wasm

python3 -E ${SDKROOT}/emsdk/upstream/emscripten/emcc.py -O2 -g3 -sENVIRONMENT=node,web -sGLOBAL_BASE=32B $ALL -o hello_em.js /tmp/sdk/hello_em.c
$SDKROOT/emsdk/node/*.*.*64bit/bin/node hello_em.js
$SDKROOT/emsdk/node/*.*.*64bit/bin/node hello_em.js |grep ^emsdk >> $SDKROOT/VERSION || exit 84

rm hello_em.*
Expand Down