Skip to contentSkip to conversation

I can't compile with -lbluetooth

Bluez-users Wu Jason 4 participants 8 messages Sep 12, 2005 – Sep 13, 2005 Bluetooth drivers

lore
Share & tools
lore

Wu Jason

author
#0 lore raw

I use "gcc -o test test.c -lbluetooth" to compile my program, but it didn't work and has error message mean it can't find -lbluetooth, how can I do?
my platform is fedora core 3 included bluez.

#1 lore raw

Hello!
Try using libbluetooth.so instead.

Good luck

Quoted 6 lines · Wu Jason

I use "gcc -o test test.c -lbluetooth" to compile my program, but it didn't work and has error message mean it can't find -lbluetooth, how can I do?
my platform is fedora core 3 included bluez.

maintainer
#2 lore raw
In reply to Wu Jason

Hi,

Quoted 4 lines

I use "gcc -o test test.c -lbluetooth" to compile my program, but it didn't work and has error message mean it can't find -lbluetooth,
how can I do?

install the BlueZ devel package and show us the full error messages.

Regards

Marcel

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

author
#3 lore raw

Hi,

Sorry I don't know what do you mean bluez devel package,=20 the following are packages default installed:

[root@localhost ~]# rpm -qa | grep ^bluez
bluez-libs-2.10-2
bluez-hcidump-1.11-1
bluez-bluefw-1.0-6
bluez-utils-2.10-2

Did I miss something?=20

Quoted 6 lines · Marcel Holtmann

Hi,
=20

Quoted 4 lines

I use "gcc -o test test.c -lbluetooth" to compile my program, but it didn't work and has error message mean it can't find -lbluetooth,
how can I do?

Quoted 13 lines

=20
install the BlueZ devel package and show us the full error messages. =20
Regards
=20
Marcel
=20
=20
=20
=20
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practic=

es

Quoted 1 line

Agile & Plan-Driven Development * Managing Projects & Teams * Testing & Q=

A

Quoted 6 lines

Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

maintainer
#4 lore raw

Hi,

Quoted 10 lines

Sorry I don't know what do you mean bluez devel package, the following are packages default installed:

[root@localhost ~]# rpm -qa | grep ^bluez
bluez-libs-2.10-2
bluez-hcidump-1.11-1
bluez-bluefw-1.0-6
bluez-utils-2.10-2

Did I miss something?

I think the package is called bluez-libs-devel.

Regards

Marcel

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

author
#5 lore raw

Hi,

Thanks for your reply,=20
but all package I can find on official web site are:

bluez-libs-2.21.tar.gz=20
bluez-utils-2.21.tar.gz=20
bluez-pin-0.26.tar.gz=20
bluez-firmware-1.0.tar.gz=20
bluez-hcidump-1.25.tar.gz=20
bluez-hciemu-1.2.tar.gz=20

There was no package you said.

By the way, I attach the error message generated when I compile

[root@localhost c]# gcc -o rfcomm-server rfcomm-server.c -lbluetooth /usr/bin/ld: cannot find -lbluetooth
collect2: ld returned 1 exit status

[root@localhost c]# gcc -o rfcomm-server rfcomm-server.c -llibbluetooth /usr/bin/ld: cannot find -llibbluetooth
collect2: ld returned 1 exit status

Quoted 12 lines · Marcel Holtmann

Hi,
=20

Quoted 10 lines

Sorry I don't know what do you mean bluez devel package,=20 the following are packages default installed:
=20
[root@localhost ~]# rpm -qa | grep ^bluez bluez-libs-2.10-2
bluez-hcidump-1.11-1
bluez-bluefw-1.0-6
bluez-utils-2.10-2
=20
Did I miss something?=20

Quoted 13 lines

=20
I think the package is called bluez-libs-devel.
=20
Regards
=20
Marcel
=20
=20
=20
=20
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practic=

es

Quoted 1 line

Agile & Plan-Driven Development * Managing Projects & Teams * Testing & Q=

A

Quoted 6 lines

Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

#6 lore raw

Hi
I had quite the same problem in Fedora 4, and I solved it by installing the "bluez-libs-devel-xx". I had to install the same version I had for BlueZ-libs, and I solved it. I found the package using http://rpm.pbone.net/

Regards

Esther

-----Mensaje original-----
De: [email protected] [mailto:[email protected]] En nombre de Wu Jason Enviado el: martes, 13 de septiembre de 2005 13:30
Para: [email protected]
Asunto: [Bluez-users] Re: I can't compile with -lbluetooth

Hi,

Thanks for your reply,
but all package I can find on official web site are:

bluez-libs-2.21.tar.gz
bluez-utils-2.21.tar.gz
bluez-pin-0.26.tar.gz
bluez-firmware-1.0.tar.gz
bluez-hcidump-1.25.tar.gz
bluez-hciemu-1.2.tar.gz

There was no package you said.

By the way, I attach the error message generated when I compile

[root@localhost c]# gcc -o rfcomm-server rfcomm-server.c -lbluetooth /usr/bin/ld: cannot find -lbluetooth
collect2: ld returned 1 exit status

[root@localhost c]# gcc -o rfcomm-server rfcomm-server.c -llibbluetooth /usr/bin/ld: cannot find -llibbluetooth
collect2: ld returned 1 exit status

Quoted 17 lines · Marcel Holtmann

Hi,

Quoted 10 lines

Sorry I don't know what do you mean bluez devel package, the following are packages default installed:

[root@localhost ~]# rpm -qa | grep ^bluez
bluez-libs-2.10-2
bluez-hcidump-1.11-1
bluez-bluefw-1.0-6
bluez-utils-2.10-2

Did I miss something?

I think the package is called bluez-libs-devel.

Regards

Quoted 8 lines

Marcel

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle

Practices

Quoted 7 lines

Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

author
#7 lore raw

Hi,

Thanks for your help,=20
After I installed the libarary, I can compile the code.

Quoted 2 lines · Esther Lopez

Hi
I had quite the same problem in Fedora 4, and I solved it by installing t=

he

Quoted 2 lines

"bluez-libs-devel-xx". I had to install the same version I had for BlueZ-libs, and I solved it. I found the package using http://rpm.pbone.n=

et/

Quoted 60 lines

=20
Regards
=20
Esther
=20
-----Mensaje original-----
De: [email protected] [mailto:[email protected]] En nombre de Wu Jason Enviado el: martes, 13 de septiembre de 2005 13:30
Para: [email protected]
Asunto: [Bluez-users] Re: I can't compile with -lbluetooth =20
Hi,
=20
Thanks for your reply,
but all package I can find on official web site are:
=20
bluez-libs-2.21.tar.gz
bluez-utils-2.21.tar.gz
bluez-pin-0.26.tar.gz
bluez-firmware-1.0.tar.gz
bluez-hcidump-1.25.tar.gz
bluez-hciemu-1.2.tar.gz
=20
There was no package you said.
=20
By the way, I attach the error message generated when I compile =20
[root@localhost c]# gcc -o rfcomm-server rfcomm-server.c -lbluetooth /usr/bin/ld: cannot find -lbluetooth
collect2: ld returned 1 exit status
=20
[root@localhost c]# gcc -o rfcomm-server rfcomm-server.c -llibbluetooth /usr/bin/ld: cannot find -llibbluetooth
collect2: ld returned 1 exit status
=20
=20

Quoted 22 lines · Marcel Holtmann

Hi,

Quoted 10 lines

Sorry I don't know what do you mean bluez devel package, the following are packages default installed:

[root@localhost ~]# rpm -qa | grep ^bluez
bluez-libs-2.10-2
bluez-hcidump-1.11-1
bluez-bluefw-1.0-6
bluez-utils-2.10-2

Did I miss something?

I think the package is called bluez-libs-devel.

Regards

Marcel

Quoted 5 lines
Quoted 3 lines

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle

Practices

Quoted 1 line

Agile & Plan-Driven Development * Managing Projects & Teams * Testing &=

QA

Quoted 1 line
Quoted 1 line

Security * Process Improvement & Measurement * http://www.sqe.com/bsce5=

sf

Quoted 10 lines
Quoted 5 lines

_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

=20
=20
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practic=

es

Quoted 1 line

Agile & Plan-Driven Development * Managing Projects & Teams * Testing & Q=

A

Quoted 11 lines

Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users
=20
=20
=20
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practic=

es

Quoted 1 line

Agile & Plan-Driven Development * Managing Projects & Teams * Testing & Q=

A

Quoted 6 lines

Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users