I am unable to run import naoqi as it gives error. It shows no such modules found. After troubleshooting I get path/to/python-sdk. But after that also it gives error and does not work. Please help with step by step solution. Thank you
1 Answers
[Dependencies]: Python 2.7, boost library 1.55
[Boost 1.55] [ATTENTION: has to be Built with gcc 4.8. So install it in case you do not have it.]
Download Boost 1.55 boost_1_55_0.tar.bz2 from here
Extract:
$ tar --bzip2 -xf boost_1_55.tar.gz2
As described here you have to modify "boost_1_55_0/tools/build/v2/user-config.jam":
$ echo "using gcc : 4.8 g++-4.8 ; " >> tools/build/src/user-config.jam
Choose where you want to install the library and run:
$ ./bootstrap.sh --prefix=/path/to/installation
Build and install:
$ ./b2 --toolset=gcc-4.8 install
Add installation directory to LD_LIBRARY_PATH:
$ export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/path/to/installation
[Naoqi Python SDK]
Choose a directory and extract pynaoqi-python-2.7-naoqi-x.x-linux64.tar.gz in it.
Set the corresponding environmental variables:
$ export PYTHONPATH=$PYTHONPATH:/path/to/naoqi/python/sdk
$ export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/path/to/naoqi/python/sdk
Check if everything went well. Open a python terminal (python, ipython, etc) and run:
import naoqi
If you get no error, then you are ready to go.
cheers!