Commit Graph

141 Commits

Author SHA1 Message Date
Christian Clauss b2201c19b1
Upgrade to Python v3.11.3 (#3741) 2023-04-12 17:38:05 +02:00
Loïc Estève 7193109f4d
Package OpenBLAS and use OpenBLAS in scipy (#3331) 2023-04-11 21:30:07 -07:00
Gyeongjae Choi 2046310460
ENH Support SDL-based packages and add pyxel (#3508)
Co-authored-by: Hood Chatham <roberthoodchatham@gmail.com>
Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
2023-03-30 08:18:31 +00:00
Roman Yurchak 601d939fdd
Fix wheel compression with the JsDelivr CDN (#3667)
Set the MIME type for wheels and zip files to application/wasm to enable CDN compression. Also optionally disable compression in zip files and wheels to make the brotli compression by the CDN more efficient.

Co-authored-by: Gyeongjae Choi <def6488@gmail.com>
2023-03-21 09:11:47 +01:00
Hood Chatham ce7880739e
Emscripten 3.1.32 (#3599) 2023-03-03 11:12:11 +01:00
Joe Marshall 0fdf9a80fa
Add Fastparquet (#3590) 2023-03-02 14:46:58 +09:00
Christian Clauss 154fbed9fa
Upgrade to Python v3.11.2 (#3614) 2023-03-01 23:57:17 +01:00
Gyeongjae Choi ed3ae1ba49
Download standard libraries in a zipfile (#3582) 2023-03-01 23:11:30 +01:00
Gyeongjae Choi c55bd2a823
Move webbrowser.py into pyodide-py (#3583) 2023-02-14 16:08:28 +09:00
Hood Chatham c221532c8c
Disable NODEJS_CATCH_EXIT (#3542) 2023-02-04 14:50:14 +01:00
Gyeongjae Choi 16d494b22b Disable AUTO_JS_LIBRARIES and AUTO_NATIVE_LIBRARIES flags (#3505) 2023-01-30 10:43:34 +09:00
Hood Chatham 122facf069
Emscripten 3.1.31 (#3517) 2023-01-27 20:05:21 -08:00
Hood Chatham 5e26d9f1ae
Build libpyodide.a (#3335)
This is work towards unvendoring the Pyodide foreign function interface. 

Prior to this point, we included a large amount of critical functionality with `--pre-js`.
So we could create an archive called `libpyodide.a` with the object files but to use it
you would have to pass `--pre-js _pyodide.out.js` at link time. This embeds all of this
stuff in an object file called `pyodide_pre.o` which goes in our archive so you get all
the needed js runtime by linking it. 

Of course someone trying to use this still has to get the Python code onto the import
path, either using `--preload-file`, using Python to unpack it as a zip archive as we now
do, with zipimporter, or otherwise. They also will have to link `libpython.a` (is CPython
going to start distributing an Emscripten libpython?) and probably various other things.

We have to use a hack to inject the JavaScript code into the object files. The normal
`EM_JS` macro cannot handle arbitrary JavaScript code -- for example it fails with many
regex. Instead we manually generate write a C source file that does what we need using
`xxd`. The generated C code is similar to what `EM_JS` generates, but it uses an array
initializer rather than a string initializer for the characters avoiding the C preprocessor /
compiler's strange opinions about strings.
2023-01-26 17:22:05 -08:00
Hood Chatham 3b2952fc92
Python3.11 (#3252) 2023-01-23 19:45:59 -08:00
Hood Chatham d9d7078d5c
Emscripten 3.1.30 (#3471) 2023-01-17 15:31:36 -08:00
Gyeongjae Choi ef112108c9
Add rust toolchain to the pyodide-env docker image (#3441)
This adds rust toolchain into our docker image so we don't have to install it every time.

make rust command still exists, but I removed it from the docs. So now a user (who wants to build a package that requires rust) is responsible for installing rust toolchain in their build setup, which is reasonable I think.

Co-authored-by: josephrocca <1167575+josephrocca@users.noreply.github.com>
Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
Co-authored-by: Hood Chatham <roberthoodchatham@gmail.com>
2023-01-10 13:28:04 +09:00
Hood Chatham 4d09958ba0
Emscripten 3.1.29 (#3408) 2023-01-04 09:30:46 +09:00
Gyeongjae Choi 2f1716b575
Relocate files inside tools directory (#3358)
This PR relocates files inside `tools` directory so that `tools` directory doesn't
have to be vendored when creating xbuildenv.

- cmake, pyo3 config ==> moved to `pyodide-build`.
- venv python script ==> moved to templates, then copied to dist during build.
2022-12-26 20:00:24 -08:00
Hood Chatham 1c34d76482
Emscripten 3.1.27 (#3314) 2022-12-02 16:12:42 -08:00
Hood Chatham 2df7a286ee
Emscripten 3.1.26 (#3280) 2022-11-21 17:34:49 -08:00
Hood Chatham 3692ff8b22
Emscripten 3.1.25 (#3239)
Co-authored-by: Gyeongjae Choi <def6488@gmail.com>

Adds a patch reverting an Emscripten commit that dropped a freetype patch.
2022-11-14 13:44:29 -08:00
Hood Chatham 201f541b63
Emscripten 3.1.24 (#3236) 2022-11-07 14:00:05 -08:00
Hood Chatham 3dfe5b35ef
Emscripten 3.1.23 (#3148) 2022-11-07 08:51:24 -08:00
Gyeongjae Choi a916ea0b34
BLD simplify building CMake based packages (#3128)
This PR makes building CMake based packages easier.
- Introduce a custom toolchain file for Pyodide. It inherits most of settings from the original Emscripten toolchain file with some modifications. Packages built by pyodide-build will automatically use that toolchain file.
- Proxy cmake in pywasmcross.py, in order to proxy other compiler toolchains.
2022-09-22 10:42:26 +09:00
Gyeongjae Choi 69b2d3f157
Add debug build option for js package (#3129) 2022-09-21 14:20:08 +09:00
Hood Chatham 0eb6036b85
Update to emscripten 3.1.21 (#3107) 2022-09-15 16:58:14 -07:00
Hood Chatham 939b615df0
Emscripten 3.1.20 (#3027)
GSW patch:
TEOS-10/GSW-Python#99

galpy patch:
jobovy/galpy#499

pyerfa patch:
liberfa/pyerfa#89

astropy patch:
astropy/astropy#13586

scipy patch:
scipy/scipy#16924
2022-08-29 18:57:05 -07:00
Hood Chatham 325291ab87
Use upstream C++ error formatting support (#2828)
The logic that we are using to format C++ exceptions has been upstreamed. 
This will also work correctly with wasm exceptions.
2022-08-25 14:41:39 -07:00
Hood Chatham 67aa16861d
Update Emscripten to 3.1.18 (#2950) 2022-08-21 17:17:49 -07:00
Gyeongjae Choi 26535e33cd
Unvendor sqlite3 from stdlib (#2946)
Unvendor the standard library sqlite3 to reduce the size of the main module. It reduces the size of pyodide.asm.wasm around ~1.4MB.

Co-authored-by: Hood Chatham <roberthoodchatham@gmail.com>
2022-08-22 08:52:50 +09:00
Hood Chatham 02644bd353
Set MIN_SAFARI_VERSION to include v14.0 (#2994) 2022-08-20 07:55:22 +02:00
Gyeongjae Choi da70299d1e
Update emscripten to 3.1.15 (#2958) 2022-08-17 19:14:10 +09:00
Gyeongjae Choi b497ce26ed
Add lzma (#2939) 2022-08-11 17:52:23 +09:00
Gyeongjae Choi a72ce423b4
BLD Use emscripten ports of bzip and zlib when building cpython (#2912) 2022-07-28 10:17:58 +02:00
Gyeongjae Choi 9fbb2972eb
Remove freetype and png from the main module (#2813) 2022-07-04 09:11:55 +02:00
Hood Chatham 52287a179d
More work on create_xbuildenv to allow building numpy (#2811)
This is more WIP on create_xbuildenv. I am including some of the WASM_LIB_DIR
but not all of it to keep size in check. The current cross build environment that we
would upload/download is 20mb.

To use this, we need an extra CLI entrypoint which I am working on.
2022-07-01 11:20:45 -07:00
Hood Chatham deb344cd37
Update Rust nightly version (#2792)
Yesterday's nightly includes rust-lang/rust#98149 which allows us to remove the
PIC setting. This also means we won't ever have to put -Zbuild-std back in.
2022-06-26 21:21:34 -07:00
John Wason 810be8869f
Add Robot Raconteur package to Pyodide (without wasm-exceptions) (#2794)
This PR adds the Robot Raconteur Pyodide package, which is a modified version
of Robot Raconteur designed to run in the Pyodide environment, using WebSockets
for communication. See robotraconteur/robotraconteur for the full version of the
package. Robot Raconteur is used to communicate with robots and other automation
components, and has a large library of drivers and packages: robotraconteur/robotraconteur-directory.
It is used as the bases for PyRI, a robotics programming environment: 
https://github.com/pyri-project/pyri-core/blob/master/README.md. Using a bridge, this package can
also be used to communicate with ROS2 networks: robotraconteur-contrib/robotraconteur_ros2_bridge
2022-06-26 21:17:58 -07:00
Hood Chatham f3e8836902
Update emscripten to v3.1.14 (#2775) 2022-06-23 15:51:06 -07:00
Hood Chatham fac51bdcf0
Default to -sSIDE_MODULE=2 in packages (#2712)
Drops the size of the dist directory from 271mb to 226 mb which is a 17% size reduction.
2022-06-23 07:15:21 -07:00
Hood Chatham be331255f7
Pass -Zlink-native-libraries=no when building Rust (#2753) 2022-06-21 08:21:33 +02:00
Hood Chatham fcdcc47d66
Drop mutable-globals flag when compiling Rust (#2723) 2022-06-15 19:37:41 -07:00
Hood Chatham 6868d2e93c
Use -sSIDE_MODULE=2 when compiling rust (#2713) 2022-06-15 07:27:34 -07:00
Hood Chatham 8d30ebdf13
Update emscripten patches again (#2684)
This drops the Rust patch and "Throw away errors in minify wasm_js" which
I suspect was fixed by an emscripten update (I'm not sure how long ago). It 
replaces the two remaining emscripten patches with new versions that match
the versions I am upstreaming.
2022-06-14 17:01:09 -07:00
Hood Chatham 9c305efc46
Fix cryptography build after emscripten update (#2683) 2022-06-14 14:54:07 +02:00
Hood Chatham c834085995
Use emscripten 3.1.13 (#2679) 2022-06-10 22:26:10 +02:00
Hood Chatham 52f27f06ad
Update to emscripten 3.1.6 (#2672) 2022-06-10 08:13:36 -07:00
Hood Chatham dbbbbb67b2
Cryptography v36.0.2 w/ Rust (#2378) 2022-06-09 10:57:34 -07:00
Hood Chatham 95b1194945
Enable Wasm BigInt (#2643)
This enables WASM_BIGINT while maintaining (hypothetical) Safari 14 support
by shimming BigInt64Array and BigUint64Array if they are missing. I think the
last time we tried to enable WASM_BIGINT was before #2019 so our chances
are significantly better this time.

This will fix dynamic linking bugs and yields a minor reduction in code size.
2022-06-02 10:09:54 -07:00
Hood Chatham 951681cfba
MAINT Improve debug settings in Makefile.envs (#2648) 2022-05-30 17:16:55 -07:00