如何调试在 Ubuntu 12.04 上构建 alsa-utils 1.1.2 的 autoconf 失败?

howto debug autoconf failure building alsa-utils 1.1.2 on Ubuntu 12.04?

我的一个客户仍然使用 Ubuntu 12.04 x86_64 作为软件开发环境,即使 Ubuntu 16.04 x86_64 在这篇文章中可用。

配置 alsa-utils 1.1.2 包时出现以下错误:

checking panel.h usability... yes
checking panel.h presence... yes
checking for panel.h... yes
checking menu.h usability... yes
checking menu.h presence... yes
checking for menu.h... yes
checking form.h usability... yes
checking form.h presence... yes
checking for form.h... yes
checking for new_panel in -lpanel... no
configure: error: panel library not found

相同的配置在 Ubuntu 16.04 x86_64 上成功完成。

调试此错误的最佳方法是什么?

配置命令为:

configure \
    --target=x86_64-buildroot-linux-gnu \
    --host=x86_64-buildroot-linux-gnu \
    --build=x86_64-pc-linux-gnu \
    --prefix=/usr \
    --exec-prefix=/usr \
    --sysconfdir=/etc \
    --localstatedir=/var \
    --program-prefix="" \
    --disable-dependency-tracking \
    --disable-xmlto \
    --with-curses=ncurses \
    --disable-alsaloop \
    --disable-bat

检查生成的 config.log 文件,它会显示尝试用 libpanel 创建测试程序 link 的构建命令是如何失败的。

配置 Alsautils 不输出完整的日志错误, 也许您在构建 ncurses 时缺少 libtinfo.so。使用选项 --with-libtic --with-libterm 重建 ncurses 并检查是否存在 /usr/lib/libtinfo.so 然后再次尝试使用选项 --disable-nls 构建 alsautils 以避免出现与 [=13] 相同的错误=](w_char 面板)或构建支持 wide-characters(--enable-widec) 的 ncurses。

另请参阅在 LFS 中构建 ncurses http://linuxfromscratch.org/lfs/view/stable/chapter06/ncurses.html