mirror of https://github.com/pyodide/pyodide.git
Remove freetype and png from the main module (#2813)
This commit is contained in:
parent
7d7b7e899d
commit
9fbb2972eb
|
@ -100,8 +100,7 @@ export MAIN_MODULE_LDFLAGS= $(LDFLAGS_BASE) \
|
|||
-s EXPORT_NAME="'_createPyodideModule'" \
|
||||
-s EXCEPTION_CATCHING_ALLOWED=['we only want to allow exception handling in side modules'] \
|
||||
-s DEMANGLE_SUPPORT=1 \
|
||||
-s USE_FREETYPE=1 \
|
||||
-s USE_LIBPNG=1 \
|
||||
-s USE_ZLIB=1 \
|
||||
-s FORCE_FILESYSTEM=1 \
|
||||
-s TOTAL_MEMORY=20971520 \
|
||||
-s ALLOW_MEMORY_GROWTH=1 \
|
||||
|
|
|
@ -10,11 +10,13 @@ source:
|
|||
- - src/setup.cfg
|
||||
- ./setup.cfg
|
||||
build:
|
||||
# RELOCATABLE flag is required because if affects how emscripten build ports.
|
||||
cflags: |
|
||||
-s RELOCATABLE=1
|
||||
-s USE_ZLIB=1
|
||||
-s USE_LIBJPEG=1
|
||||
-s USE_FREETYPE=1
|
||||
-s SIDE_MODULE=1
|
||||
-s USE_LIBPNG=1
|
||||
-s USE_LIBJPEG=1
|
||||
ldflags: |
|
||||
-ljpeg
|
||||
|
||||
|
|
|
@ -9,6 +9,18 @@ source:
|
|||
build:
|
||||
library: true
|
||||
script: |
|
||||
mkdir build && cd build && emcmake cmake -DCMAKE_C_FLAGS="-fPIC" -DCMAKE_INSTALL_PREFIX=${WASM_LIBRARY_DIR} ../
|
||||
mkdir build && cd build && emcmake cmake \
|
||||
-DCMAKE_C_FLAGS="-fPIC" \
|
||||
-DCMAKE_INSTALL_PREFIX=${WASM_LIBRARY_DIR} \
|
||||
-DWEBP_BUILD_CWEBP=OFF \
|
||||
-DWEBP_BUILD_DWEBP=OFF \
|
||||
-DWEBP_BUILD_VWEBP=OFF \
|
||||
-DWEBP_BUILD_GIF2WEBP=OFF \
|
||||
-DWEBP_BUILD_IMG2WEBP=OFF \
|
||||
-DWEBP_BUILD_WEBPINFO=OFF \
|
||||
-DWEBP_BUILD_WEBPINFO=OFF \
|
||||
-DWEBP_BUILD_WEBPMUX=OFF \
|
||||
-DWEBP_BUILD_EXTRAS=OFF \
|
||||
../
|
||||
emmake make -j ${PYODIDE_JOBS:-3}
|
||||
emmake make install
|
||||
|
|
|
@ -22,8 +22,13 @@ source:
|
|||
- ./mplsetup.cfg
|
||||
|
||||
build:
|
||||
cflags: -s USE_FREETYPE=1 -s USE_LIBPNG=1 -s USE_ZLIB=1
|
||||
ldflags: -s USE_FREETYPE=1 -s USE_LIBPNG=1 -s USE_ZLIB=1
|
||||
# RELOCATABLE flag is required because if affects how emscripten build ports.
|
||||
cflags: |
|
||||
-s RELOCATABLE=1
|
||||
-s USE_FREETYPE=1
|
||||
-s USE_LIBPNG=1
|
||||
-s USE_ZLIB=1
|
||||
-fno-lto
|
||||
script: export SETUPTOOLS_SCM_PRETEND_VERSION=$PKG_VERSION
|
||||
post: |
|
||||
cd build/matplotlib-$PKG_VERSION/dist/matplotlib-$PKG_VERSION/
|
||||
|
|
|
@ -25,12 +25,12 @@ requirements:
|
|||
- libwebp
|
||||
- libtiff
|
||||
build:
|
||||
# RELOCATABLE flag is required because if affects how emscripten build ports.
|
||||
cxxflags: |
|
||||
-fPIC
|
||||
-s RELOCATABLE=1
|
||||
-s USE_ZLIB=1
|
||||
-s USE_LIBJPEG=1
|
||||
-s USE_LIBPNG=1
|
||||
-s SIDE_MODULE=1
|
||||
ldflags: |
|
||||
-ljpeg
|
||||
-lz
|
||||
|
|
|
@ -241,8 +241,7 @@ def replay_genargs_handle_dashl(arg: str, used_libs: set[str]) -> str | None:
|
|||
if arg == "-lffi":
|
||||
return None
|
||||
|
||||
# See https://github.com/emscripten-core/emscripten/issues/8650
|
||||
if arg in ["-lfreetype", "-lz", "-lpng", "-lgfortran"]:
|
||||
if arg == "-lgfortran":
|
||||
return None
|
||||
|
||||
# WASM link doesn't like libraries being included twice
|
||||
|
|
Loading…
Reference in New Issue