I use Ubuntu 16.04 64bit OS
when I run
$ sudo pip3 install gattlib
I got this error message
/usr/bin/ld: cannot find -lboost_python-py34
collect2: error: ld returned 1 exit status
error: command 'x86_64-linux-gnu-g++' failed with exit status 1
I tried googling how to solve this but nothing works for me
I want to use gatttool at python, so I need to install this
How can I solve this?
PS. I already downloaded libboost-dev
I was running in to the following error on RPI-3B:
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++
src/gattservices.cpp:6:33: fatal error: bluetooth/bluetooth.h: No such file or directory
#include
^
compilation terminated.
error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1
[1] Running the following command helped me to resolve:
sudo apt-get install libbluetooth-dev
[2] Also deleting the folder 'gattlib-0.20150805' and recreating it using 'tar xvzf ...' again, helped cleaning the previous compilation left over files.
pip3 download gattlib
tar xvzf ./gattlib-0.20150805.tar.gz
cd gattlib-0.20150805/
sed -ie 's/boost_python-py34/boost_python-py35/' setup.py
pip3 install .
And for python 3.7 you should do:
pip3 download gattlib
tar xvzf ./gattlib-0.20150805.tar.gz
cd gattlib-0.20150805/
sed -ie 's/boost_python-py34/boost_python37/' setup.py
pip3 install .
If Benjamin's solution does not work, try changing 35 to 36. i.e. try the code below.
pip3 download gattlib
tar xvzf ./gattlib-0.20150805.tar.gz
cd gattlib-0.20150805/
sed -ie 's/boost_python-py34/boost_python-py36/' setup.py
pip3 install .
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With