Ctypes and editable mode #653
Unanswered
peppedilillo
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Dears. Using
pip install -e . --no-build-isolation
, as suggested by the docs, I can correctly install the package and compile my C code, which is called through ctypes. However once I try to use the package it fails to find the shared libraries:The
_LIBCFOCUS
variable above is implemented here:If you want to take a look, here is the software I'm working on.
The problem is that, once in editable mode, the code looks for the shared libraries in the wrong place. While not in editable mode, the libraries are installed in my local environment directory (
site-packages/hbstools/triggers/.sharedlibs/lib-pfocus.so
). However, once in editable-mode, I do not know where they are actually installed, but they are expected to be in my source directory.I have asked this question under an issue (sorry @rgommers for reviving a dead issue) and got a kind reply from @eli-schwartz, which suggested to install the shared libraries in multiple places, so that I can try to import from these. However it is not fully clear to me how this should be carried out, and if there is any better solution not requiring multiple copies of the same file.
Is it possible to install my project in editable mode?
Thank you very much.
Beta Was this translation helpful? Give feedback.
All reactions