Commit Graph

88 Commits

Author SHA1 Message Date
Ryan May 91fd7dbe89
Fix building CPython on macos (Fixes #2360) (#2554)
Updates the Makefile to avoid separating the source command from the build.
2022-05-12 15:50:01 -07:00
stonebig be59fae4f4
upgrade to SQLIte-3.38.5 (#2518) 2022-05-08 09:56:59 +09:00
echorand (Amit Saha) 213288f200
ENH Update sqlite (#2477) 2022-05-04 14:18:07 -06:00
Hood Chatham f04ba9d56a
Add bitarray (#2459) 2022-05-04 09:50:44 -06:00
Hood Chatham fda600e519
Fix interrupt handler patch (#2405) 2022-04-19 14:40:58 +02:00
Hood Chatham dfbf28856e
New keyboard interrupt patch from upstream (#2332) 2022-04-08 08:35:58 -07:00
Hood Chatham eb8afb00c2
Update libffi commit (#2350)
All libffi tests pass now. The only failing ctypes test is test_callback_too_many_args which doesn't segfault anymore, it only soft fails. Planning to submit a PR to cpython that fixes test_callback_too_many_args.
See also:
bugs.python.org/issue47208
https://github.com/emscripten-core/emscripten/pull/16658
2022-04-04 21:18:20 -07:00
Hood Chatham f06eb77387
Remove bad ctypes patch (#2331) 2022-03-30 15:03:36 -07:00
Hood Chatham 37057d1704
Set PLATFORM_TRIPLET, include platform in so names, only load compatible so files (#2299)
For reasons that are a bit beyond me, `--host` and `PLATFORM_TRIPLET`
seem to be independent, in particular we've had an empty
`PLATFORM_TRIPLET`. This is unfortunate because `PLATFORM_TRIPLET`
is used to generate the SOABI config variable which in turn is used
to decide whether a .so file is a good match for loading. We'd like
for linux Pythons not to try to import emscripten .so files (it
raises `ImportError: some_file.so: invalid ELF header`). Similarly,
we'd like to avoid attempting to load linux .so files in wasm. These
platform tags are our friends.

Anyways, this PR sets `PLATFORM_TRIPLET` and ensures that .so files
built by pywasmcross are tagged with our SOABI tag.

I moved the .so file renaming from pywasmcross to buildpkg just
before running the post script. That is a better place to put it in
case the package wants to look at the .so file after linking it. It
might be surprised that we moved it.

I also improved the error message if we try to `loadWebAssemblyModule`
something that is actually say a Linux .so file and updated get_dynlibs
to filter out .so files that have an incompatible abi tag.
2022-03-28 20:07:36 -07:00
Hood Chatham 22fab55b04
MAINT Bump zlib version (#2327)
Apparently zlib v1.2.11 had an out of bounds memory access bug so
they yanked it. This bumps the version and gets the build working
again.
2022-03-28 18:17:25 -07:00
Hood Chatham 5897646e04
MAINT Update emscripten to 2.0.24 (#2035) 2022-03-23 23:27:46 -07:00
Hood Chatham 0f2ce88edb
Rework core tests (#2265)
The goal of this commit is to add the capability of skipping specific tests by
glob pattern. Many core test sets have just one test that uses subprocess or
threads. Others have a few tests that are failing due to upstream problems in
emscripten. I went through and switched to skipping specific tests in as many
cases as I could. In modules where most or all tests use threading or
subprocess, I gave up and put a comment saying something like 35/50 tests fork
and I didn't want to bother to salvage the remaining ones.

In order to accommodate using patterns to skip specific tests (and also extra
comments) I switched the format of python_tests to a yaml file. This gives us
significantly more flexibility in the structure of the file and allows us to use
ruamel.yaml to update it. We gain a lot flexibility while reducing the length of
make_test_lists.py modestly from 108 to 78 loc.

In the future, hopefully we should be able to make fixes by deleting one skip
pattern and looking into why that particular test fails.
2022-03-22 13:41:43 -07:00
Hood Chatham 0e1e2ac01c
Python 3.10 (#2225) 2022-03-17 15:48:56 -07:00
Hood Chatham 19261f394c
Remove function pointer cast emulation (#2019) 2021-12-09 10:31:21 -08:00
Roman Yurchak 82aa271b4e
Remove disable-set-inheritable CPython patch (#2003) 2021-11-26 14:47:04 -08:00
Jan Max Meyer ebb75cd334
ENH Makefile targets for cpython partial and full clean (#1969) 2021-11-16 20:22:50 +01:00
Hood Chatham 70e9e19dde
Patches from joemarshall/fpcast (#1708)
Co-authored-by: joemarshall <joe.marshall@nottingham.ac.uk>
Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
2021-11-13 12:31:11 +01:00
Gyeongjae Choi 754ae621c8
Drop Python built-in pwd module support (#1883) 2021-10-12 20:45:46 +02:00
Hood Chatham 3e3d6eb8a9
ENH Support PyErr_CheckSignals interrupts (#1294) 2021-09-26 11:53:46 -07:00
Hood Chatham 6eac16825c
Update libffi to tip of tree (#1760) 2021-07-30 16:54:27 +02:00
Hood Chatham 6059fc7652
Remove fpcast calls from CALL_FUNCTION opcode (#1699) 2021-07-18 15:04:42 -07:00
Paul m. p. P d4a705bde2
Use PYMAJOR/PYMINOR according to Python devguide (#1570)
Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
2021-07-06 13:28:39 +02:00
Hood Chatham 46eee26ff8
Various improvements in core (#1673) 2021-07-01 10:47:44 -07:00
Hood Chatham 447da28e80
Up to date libffi port (with varargs support) (#1674) 2021-06-29 19:01:19 -07:00
Hood Chatham 653891b045
ENH Add Ctypes support (#1656) 2021-06-26 10:34:31 +02:00
Hood Chatham b4f4bcffdc
Update to Python 3.9.5 (#1637)
Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
2021-06-19 15:49:25 -07:00
Ian Clester 2ca25cd348
Include 'audioop' in standard library. (#1623)
Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
2021-06-06 12:01:39 +02:00
dmondev 67678a6c7f
getting bzip2,libxml,libxslt from http instead of ftp (#1400) 2021-03-31 21:04:58 -07:00
joemarshall b22b4f0c9e
Move all configuration variables for compile into Makefile.envs (#1369) 2021-03-26 15:37:59 +01:00
joemarshall 1bd8380c01
Emscripten 2.0.12 Upstream backend (#1102)
Co-authored-by: Dexter Chua <dalcde@users.noreply.github.com>
Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
2021-02-06 08:58:12 +01:00
Hood Chatham f8d363822c
Patch ceval to add callback to use for KeyboardInterrupt handling (#1148)
* Patch ceval to add interrupt handler callback

* Don't use SharedArrayBuffer in test, Firefox doesn't expose it

* Fix test

* Retest

Co-authored-by: Jan Max Meyer <jmm@phorward.de>
2021-01-20 23:27:28 +01:00
Dexter Chua 5f3528fb74
BLD Remover linker flags when building cpython (#1137)
We never link when building cpython; we simply generate object files and
put them in an archive.
2021-01-15 10:45:24 +01:00
Dexter Chua 72555048b6
BLD Don't copy artifacts to root (#1096) 2021-01-10 18:19:34 +01:00
Dexter Chua 2aa8982990
Actually generate a sysconfigdata.py (#1044)
Previously, we simply copied from the host, which has wildly incorrect
values. Fixes #1042
2021-01-05 14:14:55 +01:00
Dexter Chua a211802b44
Slightly simplify cpython patch (#1023) 2021-01-03 09:48:16 +01:00
Dexter Chua 2dfeba4c05
Build with -fPIC (#1008)
This is needed for the upstream backend, and I believe is a noop under
the fastcomp backend

Co-authored-by: Michael Droettboom <mdboom@gmail.com>
Co-authored-by: Joe Marshall <joe.marshall@nottingham.ac.uk>
2021-01-02 09:17:14 +01:00
Dexter Chua 208fa57bcf
Explicitly tell sqlite popen is not available (#999) 2021-01-01 10:45:44 +01:00
Dexter Chua 043f699c3f
Remove superfluous CPython patch (#993) 2020-12-31 18:22:33 +01:00
Dexter Chua 9e6a9f426d
Remove some unneeded CPython patches (#994) 2020-12-31 18:19:24 +01:00
Nicolas Ollinger 5d19ab2a3e
FIX update bzip2 url (#868) 2020-12-16 17:55:05 +01:00
Dexter Chua 452b379363
Upgrade to emscripten 1.38.42 (#843) 2020-12-15 08:56:43 +01:00
Dexter Chua e8cc4e8835
PKG Configure zlib, not patch (#849)
The #include <unistd.h> line is added in zconf.h, which is generated by
configure.
2020-12-12 12:33:33 +01:00
Dexter Chua 0d2a9f9ffe
BLD Remove undefined flags (#842)
In python's Makefile generated by makesetup, SQLITEBUILD and BZIP2BUILD
are not defined, so we are left with empty -I and -L commands. These
manage to build by virtue of us inserting -I/path/to/sqlite and
-I/path/to/bzip2 to every single build command.

This commit does the same for zlib for consistency.
2020-12-10 20:38:47 +01:00
Dexter Chua c870b3ebf5
BLD Replace sqlite patch with Makefile configuration (#841)
When sqlite was originally added, the issue
described was bypassed by patching the python files. An alternative
workaround is used here that doesn't require any patching.
2020-12-10 09:01:17 +01:00
Dexter Chua 688ec60a40
Remove unnecessary no_af_vsock patch (#839)
In `pyconfig.undefs.h` we have undefined `HAVE_LINUX_VM_SOCKETS_H`, and
based on that, `Modules/socketmodule.h` already undefines `AF_VSOCK` for
us.
2020-12-09 08:21:08 +01:00
Dexter Chua 0defcb3825
BLD Don't compile host python (#830) 2020-12-08 00:19:16 +01:00
Roman Yurchak 41b9ad1a7b
Remove threading patches and don't remove multiprocessing module (#796) 2020-11-22 11:25:36 +01:00
Roman Yurchak bcc4f6b521
MNT Clean-up root folder (#714)
* Move six

* Move jedi and parso

* Move lz4

* Move CLAPACK

* Move zlib and libxslt

* Move libiconv and libxml

* Remobe netlify/state.json and move remove_modules to cpython

* Move bumpversion.cfg to setup.cfg

* Reset cache

* Fix test_common.py
2020-07-08 16:58:10 +02:00
Roman Yurchak fc5495ffdb
Update to Python 3.8.2 (#712)
* Updating to CPython 3.8

* More fixes

* Skip python headers check in tools/dependency-check.sh

* Fix checksum

* Fix packages

* Fix syntax error

* Fix benchmark path

* Update CPython tests

* More test fixes

* Fix PyStone

* More Cpython test fixes

* Update docs

* Fix issue in conftest

* Add documentation

* Upload updated Docker image
2020-07-07 16:21:33 +02:00
Roman Yurchak 0e26ca0642
BLD Build CLAPACK, cpython and lz4 in parallel (#701) 2020-06-28 15:51:46 +02:00