pyindi-client icon indicating copy to clipboard operation
pyindi-client copied to clipboard

Custom path for libindiclient.a

Open jodier opened this issue 2 years ago • 2 comments

Dear pyindi-client deceloppers,

Would it be possible to implement something to make it possible to specify a custom libindiclient.a path when installing pyindi-client?

It's a very interesting feature to embed "libindiclient.a" and "pyindi-client" in an application and not only in "/usr/lib/" + march, "/usr/lib", "/usr/lib64", "/lib", "/lib64", "/usr/local/lib/" + march and "/usr/local/lib".

To do so (and be compatible with both a "python setup.py install" and "pip install pyindi-client"), the solution is to add an environment variable (for example INDICLIENT_PATH):

...

if "LIBINDICLIENT_PATH" in os.environs:
    libindisearchpaths.append(os.environs["LIBINDICLIENT_PATH"])

libindipath = ""

...

And regenerate setup.cfg:

[build_ext]

swig_opts = -v -Wall -c++ -threads -I<LIBINDICLIENT_PATH>/include/libindi

include_dirs = <LIBINDICLIENT_PATH>/include/libindi

library_dirs = <LIBINDICLIENT_PATH>/lib

libraries = cfitsio nova z

Best regards, Jérôme

jodier avatar Jul 13 '23 22:07 jodier

I second a request for this feature.

tbowers7 avatar Jun 04 '24 20:06 tbowers7

Can anyone submit a PR for this? It would be greatly appreciated.

knro avatar Jun 05 '24 04:06 knro