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

Use @executable-path #4

Open
burningthumb opened this issue Mar 12, 2024 · 0 comments
Open

Use @executable-path #4

burningthumb opened this issue Mar 12, 2024 · 0 comments

Comments

@burningthumb
Copy link

I took a look and this is great work.

The single issue I see is that when you use install_name_tool to change the references to the dylibs you are using absolute paths.

This means, of course, your pre-built binaries do not work. Instead errors like this are printed:

dyld[37761]: Library not loaded: /Users/runner/work/FFmpeg-macOS/FFmpeg-macOS/ffmpeg/install_universal/lib/libavdevice.59.dylib

Using that dylib as an example and realizing this applies to all the dylibs.

You can fix this by using @executable-path/../bin/libavdevice.59.dylib, to make the dylib paths relative to the main executable rather than being absolute paths from your build. Where dylibs reference other dylibs I think its the same but you would need to verify that as I have never split the bin and lib when I do this.

When I do this I put the bin and lib in the same folder and then use @executable-path/libavdevice.59.dylib for all the references everywhere.

But otherwise, fantastic work.

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

1 participant