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

can I use LD_LIBRARY_PATH to fix cannot find libpython on macOS #306

Open
lewisl opened this issue Sep 7, 2024 · 1 comment
Open

can I use LD_LIBRARY_PATH to fix cannot find libpython on macOS #306

lewisl opened this issue Sep 7, 2024 · 1 comment

Comments

@lewisl
Copy link

lewisl commented Sep 7, 2024

I've tried your recommended solution, but that command doesn't run. So, this seems like a more permanent solution by putting:

export LD_LIBRARY_PATH=/opt/homebrew/Cellar/[email protected]/3.11.9_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/config-3.11-darwin/libpython3.11.dylib

in my .zhrc

@lewisl
Copy link
Author

lewisl commented Sep 8, 2024

I figured it out:

import nimpy/py_lib as lib
pyInitLibPath("/Library/Frameworks/Python.framework/Versions/3.12/Python")

Sadly, this is neither general nor portable.
Any way to create solution that doesn't require the import and call every time?

My python install is from Python.org, so as standard as can be.

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