Raspbian上的Libspotify - 编译示例

时间:2016-04-03 22:50:01

标签: linux raspberry-pi raspbian alsa libspotify

我正在尝试在我的Raspberry Pi B上编译Libspotify提供的示例。有一些关于alsa的错误开始,但设法通过安装libasound2-dev来修复它们。

现在我在尝试编译时遇到以下错误 - 有人有任何建议吗?

问题似乎源于

  

/ usr / bin / ld:alsa-audio.o:未定义的符号引用   'pthread_create @@ GLIBC_2.4'//lib/arm-linux-gnueabihf/libpthread.so.0:   添加符号时出错:命令行中缺少DSO

终端输出:

for a in jukebox spshell localfiles; do make -C $a  all; done
make[1]: Entering directory '/home/username/Downloads/libspotify-12.1.103-Linux-armv6-bcm2708hardfp-release/share/doc/libspotify/examples/jukebox'
cc -I/usr/include/alsa  -I/usr/local/include  -Wall  -L/usr/local/lib  jukebox.o appkey.o alsa-audio.o audio.o -o jukebox -lasound  -lspotify 
/usr/bin/ld: alsa-audio.o: undefined reference to symbol 'pthread_create@@GLIBC_2.4'
//lib/arm-linux-gnueabihf/libpthread.so.0: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
Makefile:21: recipe for target 'jukebox' failed
make[1]: *** [jukebox] Error 1
make[1]: Leaving directory '/home/username/Downloads/libspotify-12.1.103-Linux-armv6-bcm2708hardfp-release/share/doc/libspotify/examples/jukebox'
make[1]: Entering directory '/home/username/Downloads/libspotify-12.1.103-Linux-armv6-bcm2708hardfp-release/share/doc/libspotify/examples/spshell'
cc -I/usr/local/include  -Wall -L/usr/local/lib  spshell.o spshell_posix.o appkey.o cmd.o browse.o search.o toplist.o inbox.o star.o playlist.o test.o -lreadline -lspotify  -o spshell
/usr/bin/ld: spshell_posix.o: undefined reference to symbol 'pthread_create@@GLIBC_2.4'
//lib/arm-linux-gnueabihf/libpthread.so.0: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
Makefile:18: recipe for target 'spshell' failed
make[1]: *** [spshell] Error 1
make[1]: Leaving directory '/home/username/Downloads/libspotify-12.1.103-Linux-armv6-bcm2708hardfp-release/share/doc/libspotify/examples/spshell'
make[1]: Entering directory '/home/username/Downloads/libspotify-12.1.103-Linux-armv6-bcm2708hardfp-release/share/doc/libspotify/examples/localfiles'
make[1]: Leaving directory '/home/username/Downloads/libspotify-12.1.103-Linux-armv6-bcm2708hardfp-release/share/doc/libspotify/examples/localfiles'

0 个答案:

没有答案