无法构建 GNU automake - help2man 无法从 automake-1.16 获取“--help”信息

Unable to build GNU automake - help2man can't get `--help' info from automake-1.16

我正在尝试编译和构建 automake 1.16,但它以下列方式失败:

help2man: can't get `--help' info from automake-1.16
Try `--no-discard-stderr' if option outputs to stderr
make: *** [doc/automake-1.16.1] Error 255

我在 Whosebug 和 Github 上搜索并发现了类似的问题,解决方案是 "yum install perl-Thread-Queue"

但是我没有root权限。如何在不安装 "perl-Thread-Queue" 的情况下成功编译 automake?我需要这个特定版本的 automake 来编译另一个包。

您可以从源代码构建 perl 线程队列并将其放在您的 perl 路径中。无需集中安装。

您需要安装 help2man 并获取 Thread::Queue as described here。本质上:

# help2man
myprefix=$HOME/.hpc/help2man/1.48.3
wget https://gnuftp.uib.no/help2man/help2man-1.48.3.tar.xz
tar xfv help2man-1.48.3.tar.xz
cd help2man-1.48.3
./configure --prefix=$myprefix   
make -j$(nproc)
make install

您还需要安装 perl 才能获得 Thread::Queue

curl -L https://raw.githubusercontent.com/ranguard/installing-perl/master/scripts/install_perl_on_nix.sh | bash
cpanm --local-lib=~/perl5 local::lib && eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib)
cpanm Thread::Queue # For automake

请注意,在继续安装之前,您需要确保已设置路径。

必须像 automake-1.16/bin/automake.in 那样更改源代码 +使用 List::Util 'reduce'; +sub none (&@) { 我的 $code=shift;减少 { $a && !$code->(local $_ = $b) } 1, @_; } https://github.com/Homebrew/linuxbrew-core/pull/6352/commits/dec6db52ad887a27210e0521a0bc5c271a7c9332