-
-
Notifications
You must be signed in to change notification settings - Fork 107
src: update node.js to v16.17.1 #9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Note to self: compilation for Android arm64 on macOS (M1) failed after some 20min with this: |
|
|
It seems like the problem isn't that trap handlers should be disabled on Android (because they already should be disabled), it seems like the Android detection isn't working, and it could be because I'll try to compile on my Linux and see if that helps. If it does, then we can come up with a M1 clang-specific fix. |
That's not it, nope. I made a simple check where I just test if |
|
Yeah, the problem was not |
|
Alright, inspired by nodejs/node@ee9aac1#diff-2f6d66c5a80c7401c5b5bba4bdc021dbe547fc2aff0dd1ef7dbb165dcc83ad3f, I just hard-disabled the trap handler because this project is anyway only going to be compiled for Android and iOS, and made some progress. The trap-handler-related error no longer shows up! V8 compiled. Now it proceeded to compile libnode, and it succeeded with some files, but failed when compiling node_credentials.cc: PS: I'm reporting all this here also for my own sake, to recall what happened in between these very long compilation times. |
|
Okay, that one wasn't hard. It was a matter of adding more Seems like compiling for Android (on Mac M1) succeeded! But the script itself ended with an error, something about Now onto running the test suite. |
|
Compilation for iOS on Mac (M1) seems like it's working too, I'm just having to ignore the build for simulator because those are theoretically x86_64 and nodejs (with V8) can't be compiled for x86 on arm64 machines. This is unless we change the simulator build to assume that the simulator arch is arm64, but that's an issue for the future, when "all" Macs are M1+. Technically the only thing missing is running the tests. Those just take a lot of hours, so it'll be slow. |
|
After iOS compilation and during Framework creation, I got the following error: I checked, and Other files: |
|
|
|
I compared
The AFTER file has 191 It's hard to say what is the culprit here in terms of file size, because |
|
The |
This WORKED, the Framework got built, and so did the test app to run the tests on an iPhone. The test suite seems broken because the mobile app has the individual js test files in the wrong place (or missing). Will keep on working on this. |
|
Running nodejs-mobile 16.17.1 on an iPhone X (A11 chip) I learned that it crashes with This was built on an Apple M1 Pro macOS computer. Next, I'll try to build nodejs-mobile 16.17.1 on an older x86_64 macOS computer, maybe that would generate armv8.0-A compatible instructions. Useful links:
|
This failed to compile because of something related to |
|
Took me a while to figure out why the |
|
Compilation lasts about 2h and then I get this (on x64 macbook): |
|
I made some progress on the Now, need to figure out what to do with v8_libsampler. It seems it is taken into account when compiling |
|
Yeah, found a solution to that by updating the Next, I'm going to see whether the NodeMobile framework can be used in a React Native app, successfully in runtime. |
Yes, it can! Final steps is massaging the test suite so that all tests pass (or skip) on both iOS and Android. |
|
All tests handled! All done! |
|
This is excellent, thank you so much for this work @staltz it really helps us with the work on mapeo mobile |
|
@gmaclennan You're welcome! I'm now busy compiling everything and making a release of nodejs-mobile. After that, I'll make a release for nodejs-mobile-react-native |
|
@staltz |
configurefor Android on Linux workingconfigurefor Android on macOS workinggccversion check on macs in./android-configureconfigurefor iOS on macOS workingparallel/test-async-hooks-fatal-errorfailure on Androidparallel/test-common-expect-warningfailure on Androidparallel/test-crypto-secure-heapfailure on Androidparallel/test-fs-write-stream-patch-openfailure on Androidparallel/test-heapsnapshot-near-heap-limit-workerfailure on Androidparallel/test-http2-clean-outputfailure on Androidparallel/test-https-agent-unref-socketfailure on Androidparallel/test-pipe-unreffailure on Androidparallel/test-policy-crypto-default-encodingfailure on Androidparallel/test-policy-manifestfailure on Androidparallel/test-policy-scopesfailure on Androidparallel/test-preload-workerfailure on Androidparallel/test-repl-array-prototype-temperingfailure on Androidparallel/test-repl-built-in-modulesfailure on Androidparallel/test-repl-clear-immediate-crashfailure on Androidparallel/test-repl-dynamic-importfailure on Androidparallel/test-repl-optionsfailure on Androidparallel/test-repl-unsafe-array-iterationfailure on Androidparallel/test-repl-unsupported-optionfailure on Androidparallel/test-runner-clifailure on Androidparallel/test-runner-exit-codefailure on Androidparallel/test-runner-import-no-schemefailure on Androidparallel/test-runner-miscfailure on Androidparallel/test-set-http-max-http-headersfailure on Androidparallel/test-stack-size-limitfailure on Androidparallel/test-stdio-undestroyfailure on Androidparallel/test-stream-pipeline-processfailure on Androidparallel/test-timers-immediate-promisifiedfailure on Androidparallel/test-timers-interval-promisifiedfailure on Androidparallel/test-timers-timeout-promisifiedfailure on Androidparallel/test-tls-wrap-econnreset-pipeon Androidparallel/test-trace-atomics-waitfailure on Androidparallel/test-trace-events-netfailure on Androidparallel/test-blob-buffer-too-largeparallel/test-corepack-versionparallel/test-fs-cpparallel/test-loaders-unknown-builtin-moduleparallel/test-process-beforeexit-throw-exit