Open jack828 opened 1 year ago
As far as I know the latest version of nan
should be node v20.x compatible.
true update nan to 2.17 solve the issue
Apologies, I ran into this issue, but it's not clear what you mean by update non to 2.17? Where would I do this?
actually in package.json we add an override node-gyp version :
"resolutions": {
"node-gyp": "9.4.0"
},
but since then we move forward to @picturae/mmmagic to fix an other issue too.
so I was able to install @picturae/mmmagic without issue.. the weird thing is that it looks like exactly the same code base as the default mmmagic in this repo.
In @picturae/mmmagic node-20
branch has to be selected: https://github.com/picturae/mmmagic/commit/eb0091adae967e55bc57b865f72479ae43290696
Thanks @jonmaim!
We adoped the following changes via pnpm patch:
package.json
"nan": "^2.17.0"
binding.gyp
'MACOSX_DEPLOYMENT_TARGET': '10.15',
'CLANG_CXX_LANGUAGE_STANDARD': 'c++17', # -std=gnu++1y
those changes came from this commit: https://github.com/mscdex/mmmagic/commit/35978fb29faa3848651e417537b87b4463061f81#diff-7ae45ad102eab3b6d7e7896acd08c427a9b25b346470d7bc6507b6481575d519
We plan to stay with @mscdex / mmmagic, so it would be nice to have those changes merged, when verified no other conflicts occur.
Edit: It already has an pr: https://github.com/mscdex/mmmagic/pull/171
I've just updated the @picturae/mmmagic package to support node 22 as well. It's now all in the master branch, but I've left the node-20 branch for now. An updated scoped version (@picturae/mmmagic) has also been published to npm.org (v0.5.5)
@dthornley Thank you. @picturae/mmmagic solve our issues with installation on node 20 (mac)
Hello, I am trying to upgrade a project that uses mmmagic to node 20.
The following compile issues occur: