Skip to content
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

Compile to .so file and install headers #457

Open
kpu opened this issue Aug 9, 2023 · 4 comments
Open

Compile to .so file and install headers #457

kpu opened this issue Aug 9, 2023 · 4 comments

Comments

@kpu
Copy link
Member

kpu commented Aug 9, 2023

KDE is asking us to be a proper library not just a submodule.

@XapaJIaMnu
Copy link
Collaborator

I did a quick hack that compiles a shared library, a few problems.

  1. problem is that, marian is hardcoded to link to static MKL, so we have a rather large shared library, same with CUDA. (Although we could argue here that we do not want CUDA).
% strip libbergamot-translator.so 
% du -hcs libbergamot-translator.so 
31M     libbergamot-translator.so
31M     total
% ldd libbergamot-translator.so 
        linux-vdso.so.1 (0x00007ffc77d3b000)
        libtcmalloc_minimal.so.4 => /usr/lib/libtcmalloc_minimal.so.4 (0x00007f2868226000)
        libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007f2867e00000)
        libm.so.6 => /usr/lib/libm.so.6 (0x00007f286a338000)
        libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x00007f286a313000)
        libc.so.6 => /usr/lib/libc.so.6 (0x00007f2867a00000)
        /usr/lib64/ld-linux-x86-64.so.2 (0x00007f286a469000)
  1. We really need to clean our headers if we want to be a proper library with headers to install.

@Montel
Copy link

Montel commented Oct 2, 2023

Hello,
There is a progress about this issue ? :)

Thanks a lot.
Regards

@XapaJIaMnu
Copy link
Collaborator

Hi @Montel ,
We've looked and identified the necessary steps and it requires quite a big rewrite of the underlying build logic for marian and of our headers ;/ It's on the menu, but noone is working on it actively in the moment. PRs are welcome.

@kpu
Copy link
Member Author

kpu commented Oct 2, 2023

To be clear, we only need to install public headers. And part of the point of bergamot-translator is that it the public headers are relatively limited.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants