Welcome, Guest
Username: Password: Remember me
27 Feb 2017
INDI development team is happy to announce the release of INDI Library v1.4.0. This new exciting release builds on the maturity of INDI Library and comes with many new supported devices and fixes for existing drivers. Several improvements and enhancements are included in this release including native support for Cygwin and MacOS platforms in addition to Linux, BSD, and Windows (Client only).
Read More...
  • Page:
  • 1
  • 2

TOPIC: Problems with installing Python wrappers for INDI

Problems with installing Python wrappers for INDI 1 month 1 week ago #15313

Hi

I am trying to install Python wrappers for INDI in Raspberry pi 3 with Raspian Lite, but keep getting the same error message after the command “make” .

I follow all the tutorial and this one year old post :

fehlfarbe wrote: So the updated instruction for Raspbian Jessie should be:

# download SVN repo
svn co svn://svn.code.sf.net/p/pyindi-client/code/trunk/swig-indi/swig-indi-python/
# update FindINDI.cmake
wget http://sourceforge.net/p/indi/code/HEAD/tree/trunk/cmake_modules/FindINDI.cmake?format=raw -O swig-indi-python/cmake_modules/FindINDI.cmake
# change to build directory
mkdir libindipython
cd libindipython
# execute cmake with python2.7 path
cmake -D PYTHON_LIBRARY=/usr/lib/arm-linux-gnueabihf/libpython2.7.so -D PYTHON_INCLUDE_DIR=/usr/include/python2.7/ ../swig-indi-python/
# build and install
make
sudo make install


I change the FindiINDI.cmake with the last one for version 1.4

But, no way to finish the make command without error.
[ 16%] Swig source
Language subdirectory: python
Search paths:
   ./
   /usr/include/python2.7/
   /usr/include/libindi/
   /usr/include/
   /home/pi/swig-indi-python/
   ./swig_lib/python/
   /usr/share/swig2.0/python/
   ./swig_lib/
   /usr/share/swig2.0/
Preprocessing...
/home/pi/swig-indi-python/indiserverpython.i:52: Error: Unable to find 'libindiserver.h'
CMakeFiles/_PyIndiServer.dir/build.make:61: recipe for target 'indiserverpythonPYTHON_wrap.c' failed
make[2]: *** [indiserverpythonPYTHON_wrap.c] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/_PyIndiServer.dir/all' failed
make[1]: *** [CMakeFiles/_PyIndiServer.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

and after moving the libindiserver.h file
[ 16%] Swig source
Language subdirectory: python
Search paths:
   ./
   /usr/include/python2.7/
   /usr/include/libindi/
   /usr/include/
   /home/pi/swig-indi-python/
   ./swig_lib/python/
   /usr/share/swig2.0/python/
   ./swig_lib/
   /usr/share/swig2.0/
Preprocessing...
Starting language-specific parse...
Processing types...
C++ analysis...
Generating wrappers...
/home/pi/swig-indi-python/libindiserver.h:47: Warning 451: Setting a const char * variable may leak memory.
/home/pi/swig-indi-python/libindiserver.h:64: Warning 454: Setting a pointer/reference variable may leak memory.
Scanning dependencies of target _PyIndiServer
[ 33%] Building C object CMakeFiles/_PyIndiServer.dir/indiserverpythonPYTHON_wrap.c.o
In file included from /home/pi/libindipython/indiserverpythonPYTHON_wrap.c:2958:0:
/home/pi/swig-indi-python/libindiserver.h:4:16: fatal error: fq.h: Aucun fichier ou dossier de ce type
 #include "fq.h"
                ^
compilation terminated.
CMakeFiles/_PyIndiServer.dir/build.make:70: recipe for target 'CMakeFiles/_PyIndiServer.dir/indiserverpythonPYTHON_wrap.c.o' failed
make[2]: *** [CMakeFiles/_PyIndiServer.dir/indiserverpythonPYTHON_wrap.c.o] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/_PyIndiServer.dir/all' failed
make[1]: *** [CMakeFiles/_PyIndiServer.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

Please tell me what I'm doing wrong.

Sébastien.

Please Log in or Create an account to join the conversation.

Kubuntu 16.04 with KDE Plasma 5.5.5 using PPA for latest KStars-bleeding and INDI
Raspberry Pi 2 with Ubuntu Mate
Atik 314E - QHY5 - CG5

Problems with installing Python wrappers for INDI 1 month 1 week ago #15319

Successful setup.

You have to install dependency :
sudo apt-get install python-setuptools python-dev libindi-dev swig subversion

to download the last code from svn repository
svn checkout https://svn.code.sf.net/p/pyindi-client/code/trunk ~/pyindi-client-code

change directory
~/pyindi-client-code/pip/pyindi-client

modifiy setup.cfg with this part
libraries = indidriver

run setup.py with root access
sudo python setup.py install

The setup finish with this
Finished processing dependencies for pyindi-client==0.1.0a1

launch indiserver
indiserver -vvv indi_simulator_ccd indi_simulator_telescope

then this python command
python test-indiclient.py

But when I'm trying the first example code,
Traceback (most recent call last):
  File "/home/pi/pyindi-client-code/swig-indi/swig-indi-python/test-indiclient.py", line 13, in <module>
    import PyIndi
  File "/usr/local/lib/python2.7/dist-packages/pyindi_client-0.1.0a1-py2.7-linux-armv7l.egg/PyIndi.py", line 28, in <module>
    _PyIndi = swig_import_helper()
  File "/usr/local/lib/python2.7/dist-packages/pyindi_client-0.1.0a1-py2.7-linux-armv7l.egg/PyIndi.py", line 24, in swig_import_helper
    _mod = imp.load_module('_PyIndi', fp, pathname, description)
ImportError: /usr/lib/arm-linux-gnueabihf/libindidriver.so.1: undefined symbol: ISSnoopDevice

Any idea ?

Please Log in or Create an account to join the conversation.

Kubuntu 16.04 with KDE Plasma 5.5.5 using PPA for latest KStars-bleeding and INDI
Raspberry Pi 2 with Ubuntu Mate
Atik 314E - QHY5 - CG5

Problems with installing Python wrappers for INDI 1 month 1 week ago #15354

Hi,
I've just tested on a Fedora with the pip method and this is still working.
You do not have to change the libraries config item with indidriver, pyindi-client is a client, not an indi driver.
Now the libindi.so seems to have disappeared in version 1.4.1, but it seems the pkg-config libindi.pc still reports it as a link flag to use.
Maybe you could try with
libraries = 

Jean-Luc.

Please Log in or Create an account to join the conversation.

Problems with installing Python wrappers for INDI 1 month 1 week ago #15356

I just updated libindi.pc, do not use the "Libs" if you're a client, since you just need to link to the static INDI client library. I read about libs.private, is this used for static linking?

Please Log in or Create an account to join the conversation.

Problems with installing Python wrappers for INDI 1 month 1 week ago #15358

On my raspbian when I'm using pip command, I get this return :
Downloading/unpacking pyindi-client
  Could not find a version that satisfies the requirement pyindi-client (from versions: 0.1.0a1)
Cleaning up...
No distributions matching the version for pyindi-client
Storing debug log for failure in /home/pi/.pip/pip.log

This is why I'm using the second way to install it, but if I'm using a
python setup.py install
with the default setup.cfg file, I get :
running install
running build_ext
building '_PyIndi' extension
swigging indiclientpython.i to indiclientpython_wrap.cpp
swig -python -v -Wall -c++ -threads -I/usr/include -I/usr/include/libindi -o indiclientpython_wrap.cpp indiclientpython.i
Language subdirectory: python
Search paths:
   ./
   /usr/include/
   /usr/include/libindi/
   ./swig_lib/python/
   /usr/share/swig2.0/python/
   ./swig_lib/
   /usr/share/swig2.0/
Preprocessing...
Starting language-specific parse...
/usr/include/libindi/baseclient.h:32: Warning 322: Redundant redeclaration of 'MAXRBUF',
/usr/include/libindi/indibase.h:10: Warning 322: previous declaration of 'MAXRBUF'.
/usr/include/libindi/basedevice.h:32: Warning 322: Redundant redeclaration of 'MAXRBUF',
/usr/include/libindi/indibase.h:10: Warning 322: previous declaration of 'MAXRBUF'.
Processing types...
C++ analysis...
/usr/include/libindi/baseclient.h:56: Warning 403: Class 'INDI::BaseClient' might be abstract, no constructors generated,
/usr/include/libindi/indibase.h:81: Warning 403: Method INDI::BaseMediator::newDevice(INDI::BaseDevice *) might not be implemented.
Generating wrappers...
creating build
creating build/temp.linux-armv7l-2.7
arm-linux-gnueabihf-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -I/usr/include -I/usr/include/libindi -I/usr/include/python2.7 -c indiclientpython_wrap.cpp -o build/temp.linux-armv7l-2.7/indiclientpython_wrap.o
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++
creating build/lib.linux-armv7l-2.7
c++ -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions -Wl,-z,relro -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wl,-z,relro -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security build/temp.linux-armv7l-2.7/indiclientpython_wrap.o /usr/lib/arm-linux-gnueabihf/libindiclient.a -lindi -o build/lib.linux-armv7l-2.7/_PyIndi.so
/usr/bin/ld: ne peut trouver -lindi
collect2: error: ld returned 1 exit status
error: command 'c++' failed with exit status 1

Please Log in or Create an account to join the conversation.

Kubuntu 16.04 with KDE Plasma 5.5.5 using PPA for latest KStars-bleeding and INDI
Raspberry Pi 2 with Ubuntu Mate
Atik 314E - QHY5 - CG5

Problems with installing Python wrappers for INDI 1 month 1 week ago #15360

After log checking, the python install procedure fail because this is a pre-release.
version 0.1.0a1 is a pre-release (use --pre to allow)

This resolve the pip error but after using
pip install --pre pyindi-client

I have this error again about library localization :
/usr/bin/ld: ne peut trouver -lindi

Please Log in or Create an account to join the conversation.

Kubuntu 16.04 with KDE Plasma 5.5.5 using PPA for latest KStars-bleeding and INDI
Raspberry Pi 2 with Ubuntu Mate
Atik 314E - QHY5 - CG5
Last Edit: by broadcastyourseb.

Problems with installing Python wrappers for INDI 1 month 1 week ago #15361

Concerning the pip issue, is the pyindi-client already installed ? It seems it found the 0.1.0a1 version but does not care. Maybe there has been some changes in pip itself. Which version of pip do you use ? Anyway just to be sure everything is rebuilt when upgrading libindi, you should run:
pip install --upgrade --user --force-reinstall pyindi-client # for python 2.7 if this is the default
python3 -m pip install --upgrade --user --force-reinstall pyindi-client # for python3 as my pip3 disappeared when I jump to pip 9.0.1
When you run setup manually, you should now change the libraries line in the setup.cfg file as stated above:
libraries =
This is why the compilation aborts. I will have to change that on pypi. But I wonder if this was not required in preceding releases of libindi due to some dependencies.

@Jasem: yes, you're right, Libs.private and Required.private may be useful as libz, libnova and libcfistio are required for libindiclient.a. And I may also use the --static flag when using pkg-config. I would have to rebuild a proper installation for testing all that, my current installs are full of existng thing.

Please Log in or Create an account to join the conversation.

Problems with installing Python wrappers for INDI 1 month 1 week ago #15368

From bug to bug :(

So, I keep trying with your advice. I compile it again with
libraries=

It works but when I try an import in python

import PyIndi


I get this error
>>> import PyIndi
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python2.7/dist-packages/pyindi_client-0.1.0a1-py2.7-linux-armv7l.egg/PyIndi.py", line 28, in <module>
    _PyIndi = swig_import_helper()
  File "/usr/local/lib/python2.7/dist-packages/pyindi_client-0.1.0a1-py2.7-linux-armv7l.egg/PyIndi.py", line 24, in swig_import_helper
    _mod = imp.load_module('_PyIndi', fp, pathname, description)
ImportError: /usr/local/lib/python2.7/dist-packages/pyindi_client-0.1.0a1-py2.7-linux-armv7l.egg/_PyIndi.so: undefined symbol: ln_get_julian_from_sys

Please Log in or Create an account to join the conversation.

Kubuntu 16.04 with KDE Plasma 5.5.5 using PPA for latest KStars-bleeding and INDI
Raspberry Pi 2 with Ubuntu Mate
Atik 314E - QHY5 - CG5

Problems with installing Python wrappers for INDI 1 month 1 week ago #15372

I've tried on a old indi version, when I suppress lindi from libraries, the Python import lacks the crackDN function, which was lying in libindi.so.
So I think that for version prior to 1.4.1 of libindi, we should leave libraries = lindi.
Starting at version 1.4.1, we should use the dependencies of libindiclient.a, which should be libz, libnnova and libcfitsio. So I suggest to use
libraries= z nova cfitsio
in the setup.cfg file. I don't have time to test yet but I 'll try to confirm that point this evening.

Please Log in or Create an account to join the conversation.

Problems with installing Python wrappers for INDI 1 month 1 week ago #15377

Nope, it's not working. Same python error.

Thank for testing this. I'm building an allsky camera and everything needs to be ok because the camera will take picture from Chili.

So if I setup a 1.3 indi version, you think it will work ?

Please Log in or Create an account to join the conversation.

Kubuntu 16.04 with KDE Plasma 5.5.5 using PPA for latest KStars-bleeding and INDI
Raspberry Pi 2 with Ubuntu Mate
Atik 314E - QHY5 - CG5

Problems with installing Python wrappers for INDI 1 month 1 week ago #15378

It seems that it worked for me. Did you force rebuild and reinstall ?
python setup.py build --force
python setup.py install --user
It should recompile all the swig/c++ stuff. Anyway the libindi dependency is no more there in libindi 1.4.1, which is a good thing.
If you use libindi 1.3 the libindi dependency is still there, so the initial libraries=indi should be used (it loads libz, libnova and libcfitsio by the way of this dependency).

Please Log in or Create an account to join the conversation.

Problems with installing Python wrappers for INDI 1 month 1 week ago #15380

This is really weird. I'm completly lost.
Whatever I'm trying like you wrote, setup is ending well but in python, I can't import PyIndi library without error :

Can you write the full procedure to build it from start (ie pyindi-client download) with indi1.4.1 and Raspbian Jessie ?

I will start with a fresh raspbian and a fresh indi 1.4.1.

Maybe it's a good idea to refresh this webpage http://indilib.org/support/tutorials/166-installing-and-using-the-python-pyndi-client-on-raspberry-pi.html to work with raspbian and latest version of indi

Please Log in or Create an account to join the conversation.

Kubuntu 16.04 with KDE Plasma 5.5.5 using PPA for latest KStars-bleeding and INDI
Raspberry Pi 2 with Ubuntu Mate
Atik 314E - QHY5 - CG5
  • Page:
  • 1
  • 2
Time to create page: 0.876 seconds

Login

3rd Party

Choose from the numerous 3rd party INDI drivers to suit your needs!

Got Problem?

Check out the FAQ, the forum, and the bug tracking system to resolve any issues you might have!
You can also subscribe to INDI newsletter and development mailing lists to get the latest updates on INDI!

Gallery

Replica

Why INDI

Replica