문제

I want to build a c file based on BlueZ but seems no bluetooth.h file in my system.

fatal error: bluetooth/bluetooth.h: No such file or directory

I am sure the bluetooth dongle is running correctly and I have built Bluez successfully.

Update

For my case, I find the bluetooth.h in /user/include/bluetooth folder

도움이 되었습니까?

해결책

You need to install libbluetooth-dev package for compiling your code

sudo apt-get install libbluetooth-dev

That should install the bluetooth header files.

다른 팁

For Fedora, you can use:

sudo dnf install bluez-libs-devel

On CentOS 7:

sudo yum install bluez-libs-devel
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top