-
Notifications
You must be signed in to change notification settings - Fork 118
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
[WIP]: Shared object #432
base: main
Are you sure you want to change the base?
[WIP]: Shared object #432
Conversation
So far, the investigation has indicated that I am investigating this further. Ideas and suggestions are most welcome! :) |
I would like to suggest having a feature flag or similar to enable/disable static/dynamic library-ness. |
I think it's a fair point. I have added it in todo list :) |
@atbrakhi I'm curious: Is this PR still on your todo list, or did you encounter some major blocking issue? Would it be an option to build spidermonkey (the C/C++ code) as a normal shared library object with C-ABI, and keep compiling the (small) Rust wrapper library from servo? |
@jschwe I think this was my suggestion when we need easier mozjs compilation. I chose to publish pre-built archive instead. |
@jschwe it simply got de-prioritized after @wusyong got static library working. I haven't been able to prioritize this work since then. Maybe I should pick it up again soon. We had a similar discussion in #30593. When i was working on building mozjs as shared lib I was having some issues with |
Right now we have 3 static library in mozjs:
libmozjs.a
,libjsglue.a
for mozjs/mozjs-sys glue code andlibjsglue.a
for mozjs/mozjs glue code. we are trying to have shared object instead. See servo/30593libmozjs-115.dylib
(.so/.dll
forlinux/windows
)libjsglue.dylib
libjsglue.dylib