add gzip and brotli support

This commit is contained in:
ading2210 2024-01-08 22:09:20 -05:00
parent 7472c899db
commit e4c064401e
6 changed files with 69 additions and 7 deletions

25
client/tools/zlib.sh Executable file
View file

@ -0,0 +1,25 @@
#!/bin/bash
#compile zlib for use with emscripten
set -x
set -e
CORE_COUNT=$(nproc --all)
PREFIX=$(realpath build/zlib-wasm)
cd build
rm -rf zlib
git clone -b master --depth=1 https://github.com/madler/zlib
cd zlib
emconfigure ./configure --static
emmake make -j$CORE_COUNT
rm -rf $PREFIX
mkdir -p $PREFIX/include
mkdir -p $PREFIX/lib
cp -r *.h $PREFIX/include
cp -r *.a $PREFIX/lib
cd ../../