Linking OpenMP libraries when compiling with setuptools (on macOS and linux) #4855
Unanswered
sodiumnitrate
asked this question in
Q&A
Replies: 1 comment
-
Did you figure this out? I get a similar error on Ubuntu, but same code is working on Windows. I also have this in setup.py
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
(Preface: this is extra complicated because I want this to work both on macOS and linux, and macOS+OpenMP is just pure pain. But, I think my question is valid for any platform, because I'm assuming I'd have to link to some omp library.)
I have the following C++ code:
And in
setup.py
I have:I install within the module directory that contains
setup.py
by doing:It compiles without errors or warnings. However, when I try to use it in python, it gives an import error:
How do I link
libomp
to my package? (Preferably in both macOS and linux)Beta Was this translation helpful? Give feedback.
All reactions