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

Build/Install Defaults & Binaries -- Static vs Shared #1587

Open
gdevenyi opened this issue Aug 15, 2023 · 3 comments
Open

Build/Install Defaults & Binaries -- Static vs Shared #1587

gdevenyi opened this issue Aug 15, 2023 · 3 comments
Labels
feature request Ideas for new or improved ANTs features

Comments

@gdevenyi
Copy link
Contributor

The current default build process is BUILD_SHARED_LIBS=OFF which means ANTs binaries are statically built. Despite this, make install will still install all the libraries, which makes the install huge.

For docker containers, binaries, etc, we should either use the shared build (library paths should be handled by RPATH) or not install the libraries during static install.

@cookpa cookpa added the feature request Ideas for new or improved ANTs features label Aug 28, 2023
@cookpa
Copy link
Member

cookpa commented Aug 28, 2023

The Dockerfile does use the shared builds, but I don't think it uses RPATH, I have to set LD_LIBRARY_PATH. This breaks shared Mac OS builds, because the OS does not respect LD_LIBRARY_PATH for security reasons.

I don't know if not installing the libraries could affect other ANTsX software, but would need to verify that before making any changes. Perhaps it could be an option, I believe we have a "libs only" option already, I could add "binaries only".

@cookpa
Copy link
Member

cookpa commented May 24, 2024

I was looking at this randomly and noticed that it's mostly not the libs making the distribution large

1.9G	./bin
273M	./lib

Might be worth trying to trim executable size by removing unneeded imports

@gdevenyi
Copy link
Contributor Author

Related, ANTsX/ANTsPy#346

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Ideas for new or improved ANTs features
Projects
None yet
Development

No branches or pull requests

2 participants