![Checkinstall 安装 gnu gcc 6.2.0 失败](https://linux22.com/image/97651/Checkinstall%20%E5%AE%89%E8%A3%85%20gnu%20gcc%206.2.0%20%E5%A4%B1%E8%B4%A5.png)
我尝试使用 checkinstall 从源 GCC 6.2.0 安装,但失败了。
我运行configure并make,一切看起来都很好,但是当我尝试checkinstall时,出现以下错误:
ranlib: could not create temporary file whilst writing archive: No more archived files
发生时记录:
make[4]: Leaving directory '/home/alexandre/Documents/objdir/libcc1'
make[3]: Leaving directory '/home/alexandre/Documents/objdir/libcc1'
make[2]: Leaving directory '/home/alexandre/Documents/objdir/libcc1'
make[2]: Entering directory '/home/alexandre/Documents/objdir/x86_64-pc-linux-gnu/libgcc'
/bin/bash /home/alexandre/Documents/objdir/../gcc-6.2.0/libgcc/../mkinstalldirs /home/alexandre/gcc-6.2.0/lib/gcc/x86_64-pc-linux-gnu/6.2.0
/usr/bin/install -c -m 644 libgcc_eh.a /home/alexandre/gcc-6.2.0/lib/gcc/x86_64-pc-linux-gnu/6.2.0/
chmod 644 /home/alexandre/gcc-6.2.0/lib/gcc/x86_64-pc-linux-gnu/6.2.0/libgcc_eh.a
ranlib /home/alexandre/gcc-6.2.0/lib/gcc/x86_64-pc-linux-gnu/6.2.0/libgcc_eh.a
ranlib: could not create temporary file whilst writing archive: No more archived files
Makefile:1112: recipe for target 'install-shared' failed
make[2]: *** [install-shared] Error 1
make[2]: Leaving directory '/home/alexandre/Documents/objdir/x86_64-pc-linux-gnu/libgcc'
Makefile:17621: recipe for target 'install-target-libgcc' failed
make[1]: *** [install-target-libgcc] Error 2
make[1]: Leaving directory '/home/alexandre/Documents/objdir'
Makefile:2323: recipe for target 'install' failed
make: *** [install] Error 2
**** Installation failed. Aborting package creation.
提前致谢。
答案1
这是一个已知的问题。有时 checkinstall 会因为缺少文件夹而中断安装。它也(对于某些错误)拒绝创建新文件夹,尽管它具有创建该文件夹所需的权限。在这种情况下,您所需要做的就是手动创建文件夹。在本例中创建文件夹/home/alexandre/gcc-6.2.0/lib/gcc/x86_64-pc-linux-gnu/6.2.0
并手动设置权限。
sudo mkdir /home/alexandre/gcc-6.2.0/lib/gcc/x86_64-pc-linux-gnu/6.2.0
须藤 chmod 644 /home/alexandre/gcc-6.2.0/lib/gcc/x86_64-pc-linux-gnu/6.2.0
另一种可能性是您可能错过了安装之前的配置步骤。请尝试配置
./configure--禁用静态
,重新编译并使用 checkinstall 安装它。