[英]using sndfile library when compiling 32bit linux application on Fedora 20 x86_64
I'm currently using Fedora 20 x86_64. 我目前正在使用Fedora 20 x86_64。 I've built libsndfile with these commands:
我用以下命令构建了libsndfile:
sudo ./configure BASE_FLAGS=-32
sudo make
sudo make install
This all goes well and I can find the compiled library in /usr/local/lib. 一切顺利,我可以在/ usr / local / lib中找到编译的库。 I want to use this in an application that will be built in 32bit.
我想在将以32位构建的应用程序中使用它。 The problem occurs when I try to compile that application.
当我尝试编译该应用程序时,会出现问题。 I get the following error:
我收到以下错误:
/usr/bin/ld: skipping incompatible /builddir/Code/Platformer/../Dependencies/libsndfile/lib/Linux/libsndfile.so when searching for -lsndfile
/usr/bin/ld: skipping incompatible /builddir/Code/Platformer/../Dependencies/libsndfile/lib/Linux/libsndfile.a when searching for -lsndfile
/usr/bin/ld: cannot find -lsndfile
The "skipping incompatible" might suggest that I'm doing something wrong when compiling sndfile but since I'm kind of new to this I can't find what it is. “跳过不兼容”可能表明在编译sndfile时我做错了什么,但是由于我是新手,所以找不到它。 I tried different configurations but they all have the same result.
我尝试了不同的配置,但是它们都具有相同的结果。
If this needs more code or something, let me know what you need. 如果这需要更多代码或其他内容,请告诉我您需要什么。
For anyone with the same problem - try to look here: 对于有相同问题的任何人-尝试查看此处:
ld cannot find an existing library ld找不到现有的库
Generally there is probably a symlink missing, because the '-devel' library is not istalled. 通常,可能没有符号链接,因为没有安装'-devel'库。 That is why
这就是为什么
sudo yum install libsndfile-devel.*
fixed it for me. 为我修复它。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.