classilla / tenfourfox

Mozilla for Power Macintosh.
http://www.tenfourfox.com/
Other
270 stars 38 forks source link

async/await using external mozjs? #653

Open kencu opened 2 years ago

kencu commented 2 years ago

mozjs52, 60, and 68 all build on 10.6.8 now via MacPorts, and up to 60 are available for ppc Tiger I believe.

Those js versions all fully support the async/await features that so many websites like github and others are using now, that are a thorn for TenFourFox.

I tried just changing the "js" binary in the bundle to a symlink to a MacPorts-installed mozjs 52, 60, and 68, but that does not seem to be enough to actually make the websites work.

Do you have an idea how someone might go about using one of those external mozjs versions?

Does TFF call into a js-supporting library (ie does the js version have to be the same architecture?) or does it just call the binary as a js-interpreter, andcould you for example use an x86_64 mozjs binary from an i386 TenFourFox.

Many, most, or all the subparts of TenFourFox are available as ports in MacPorts -- perhaps factoring it out like that would keep it more maintainable?

kencu commented 2 years ago

FYI - rust now works on 10.6.8 as well, as of recently, allowing some of these new things to build.

The current compiler/toolchain on MacPorts of 10.6.8 is:

gcc11 / libgcc11 clang13/llvm13/flang13 libcxx 5.0.1 thread_local support is available both in libgcc11 and libc++ cctools 949 ld64 450 rust 1.54 and then current versions of cmake, yasm, ninja, etc all exist.

kencu commented 2 years ago

the previous full async/await discussion for TFF is here, by the way https://github.com/classilla/tenfourfox/issues/521

classilla commented 2 years ago

Ignoring the absence of the JIT, it's not just the parser and bytecode support -- async/await are full co-routines and need support within the browser's own runtime. The shell just stubs this out.

It is possible to backport those changes, but there were a lot of regressions, so it wouldn't be a small undertaking.