-
Notifications
You must be signed in to change notification settings - Fork 11
Add proper dynamic linking #19
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
Conversation
Disables bundling by default
fix clippy warning
????? In any case, this is normally not appropriate as by default most users wouldn't have library available (especially on windows) If there is necessity I will take a look at these options myself later on I guess |
|
Ok, looking at example of openssl-sys it seems people are fine with pkg-config/vcpkg being optional thingies, so I guess it should be fine |
I did manual formatting, in this PR specifically, changed comments to be a consistent style (a space between
This PR does not remove the functionality, and also keeps it as the default; this PR is aimed at not requiring to set the custom environment variable, if it is already in PATH, which the linker can resolve.
I dont know much about rust ffi binding creation, but from what i can tell, i implemented what i though was common functionality (bundled vs dynamic), doing it similarly as the only ffi i had looked at which was simple (soundtouch-ffi). I had looked at |
|
Yeah, it is fine, thank you |
|
I released 0.5.8 with additional change to customize link mode to static via env variable |
|
In case you use my wrapper, I released new version 1.5.4 to include |
|
Thanks for merging.
I think a update there is also good, though we use |
This PR adds a way to properly dynamic link without requiring a custom environment variable, let the linker find the correct library.
Also added a explicit feature for bundling
libopus, which in turn made it possible to havecmakebe optional.This new
bundledfeature is enabled by default, to preserve previous behavior.Though due to this new feature, i made it overwrite dynamic linking, as i dont know of a way to actually know if the library exists and then decide to build it or not. If wanted, i can re-add some kind of way to at least check
OPUS_LIB_DIRwith the default feature.Also fixes some slight formatting and fixes clippy warnings.