-
Notifications
You must be signed in to change notification settings - Fork 162
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
Add static build when tag "static_build" is used #40
Conversation
Thanks for the proposal. I would suggest to find a way to avoid copying the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please, don't copy the content of bridge.go
in another file.
In some case, it's a lot easier to copy a single executable to another place without having to install a bunch of dependencies which need to be installed in the same place as the builder (wasmer_link_static.go in this case) unless chrpath is used. |
No problem. I modified the PR. |
BTW, I tested the static compilation in linux only and the .a file needs imo to be replaced by a release binary from https://github.com/wasmerio/wasmer |
bors try |
tryBuild succeeded |
Can you update the CircleCI configuration to test the static build please? |
I modified the justfile to build and test using also the static library |
Hi @Hywan, what is missing from this PR in order to be merged? |
Yeah, after a quicklook, everything seems good! Thank you. I'll merge it as soon as possible (today or Friday). |
Sorry, I'm in holidays, will merge it in few days! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, thank you very much! And sorry for the delay.
bors r+ |
40: Add static build when tag "static_build" is used r=Hywan a=yaslama Co-authored-by: Yaacov Akiba Slama <[email protected]>
Build failed |
Can you retry please? |
bors r+ |
40: Add static build when tag "static_build" is used r=Hywan a=yaslama Co-authored-by: Yaacov Akiba Slama <[email protected]>
Build failed |
I think the static lib is different for macOS or some Linux distrib. I wonder whether it's good to embed it directly in the repository 🤔? |
I really like the approach that this PR is taking, and a similar approach could be used for conditional compilation of various backends and metering features. |
bors try |
tryMerge conflict. |
Please can you fix the conflicts with |
@yaslama: Are you still working on this? I would love to see this merged. |
@Hywan I fixed the conflicts with master. |
The macos linker doesn't support the -l:<file> syntax, so the dynamic and static libraries cannot be in the same directory.
@Hywan Do you think that this PR can be merged soon? |
@Hywan It has been another month with no movement. Could we please get this merged? |
bors try |
@FlorianFranzen The entire team was extremely busy for a giant set of improvements for Wasmer. Hence my silence on those projects. Now I'm back on tracks. Give me time please. |
I don't think the provided |
tryBuild succeeded: |
We can put the static libraries in a folder per arch. But on second thought, it's perhaps better to let the user build herself the static libraries. What do you think? |
@Hywan Of course, thank you for taking another look. My main concern would be that it is easy to use with the default go tool chain. I am not sure how far that is possible if you are required to compile wasmer from source. But I am not really a go expert... |
@Hywan I know you have been working hard on the v1.0.0 release, but has there been any update on static builds? |
Closing in favor of #190 and #193. With those PR, it's now possible to build your own custom libs (dylib or static lib) and link against |
@Hywan Most go programs are statically linked i.e. do not depend on shared libraries. Would it really be to much to ask to use a static build |
No description provided.