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

Unable to use Python Wrapper: Library not found #42

Open
javierpastorfernandez opened this issue Dec 15, 2023 · 2 comments
Open

Unable to use Python Wrapper: Library not found #42

javierpastorfernandez opened this issue Dec 15, 2023 · 2 comments

Comments

@javierpastorfernandez
Copy link

javierpastorfernandez commented Dec 15, 2023

Good morning,
Due to the failed intents to use the C++ API together with other libraries, I have tried to use the Python Wrapper as I am also more profficient in this language. I have tried to compile using Pybind11 but upon importing the library, it is unable to find it.

cmake .. -G "MSYS Makefiles" -Dpybind11_DIR=[....]/anaconda3/pkgs/pybind11-global-2.10.4-py311h59b6b97_0/Library/share/cmake/pybind11 -DPYTHON_EXECUTABLE=[...]/python.exe
on the "build library".
Then in the src_py folder I perform "make install" (If I do it inside the build directory the following happens -> make: *** No rule to make target 'install'. Stop)

Built files are produces and one can find libraries in the [...]/Clothoids\lib\lib folder, and in the [...]\clothoids_py_wrapper\Clothoids\src_py folder (.dll, .dll.a, _static.a)

In the Python file I tried inserting my things to my path, but they havent worked out:

import ctypes.util
import sys,os

sys.path.insert(
0, ""[....]\clothoids_py_wrapper\Clothoids\lib\lib")

sys.path.insert(
0, ""[....]\clothoids_py_wrapper\Clothoids\src_py")

if sys.platform != 'win32':
sys.path.insert(0, os.path.normpath(os.path.join(file, "../../build")))
else:
sys.path.insert(0, os.path.normpath(
os.path.join(file, "../../build/Release")))

@javierpastorfernandez javierpastorfernandez changed the title Library Usage in Python - Dec 15, 2023
@javierpastorfernandez javierpastorfernandez changed the title - Unable to use Python Wrapper: Library not found Dec 15, 2023
@ebertolazzi
Copy link
Owner

ebertolazzi commented Dec 15, 2023

I do not understand If the problem was solved or not.
I am not an expert of Python. The interface was developed by Matteo Ragni. Now I asked a friend to help me to build a new more user fiendly interface. Be patient.

@javierpastorfernandez
Copy link
Author

The problem was not solved as I described above. Any help would be appreciated

Thank you very much for the library and the input ;)

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

2 participants