xgo交叉编译不适用于alsa-lib

时间:2019-04-12 16:40:22

标签: go cross-platform libalsa

注意:我也将此问题作为xgo here的问题创建,但我认为它可能更适合作为SO问题。

我正在尝试交叉编译go应用程序,而依赖项之一是alsa.lib。我无法使用xgo成功编译它。

最初我尝试使用以下命令:

xgo --targets=linux/*,windows/*,darwin/* -deps=ftp://ftp.alsa-project.org/pub/lib/alsa-lib-1.1.8.tar.bz2 github.com/Lynges/susimup

然后产生此错误:

/deps-build/alsa-lib-1.1.8/src/pcm/pcm_softvol.c:856: undefined reference to 'pow' 
collect2: error: ld returned 1 exit status 
2019/04/11 22:51:27 Failed to cross compile package: exit status 2

因此,我添加了depsargs以得到--with-softfloat,并将其移至新的错误中:

/deps-build/alsa-lib-1.1.8/src/pcm/pcm_meter.c:674: undefined reference to `dlsym'
collect2: error: ld returned 1 exit status

这就是我现在遇到的问题。 我曾尝试在this answer中添加更多注释中提到的参数,但这只是警告我:

configure: WARNING: unrecognized options: --disable-alsamixer, --disable-xmto, --disable-nls, --disable-bat

所以现在我真的不知道该怎么办。我只想为arm交叉编译非常简单的应用程序,以便可以在Raspberry pi上使用。

0 个答案:

没有答案
相关问题