linux - Binutil 权限错误 while "make install"

标签 linux compiler-errors makefile binutils linux-from-scratch

我正在研究 LFS7.2。我在“安装”binutil 包时遇到权限错误,但我可以使用用户 lfs 在所有 3 个目录(source、tools、usr)中成功创建文件夹。我回滚并重新执行了第 4.1 章到第 4.4 章,但我仍然面临这个问题。

**

lfs@logun-HP-Pavilion-dv6-Notebook-PC:/mnt/lfs/sources/binutils-build$ make install
make[1]: Entering directory `/mnt/lfs/sources/binutils-build'
/bin/sh ../binutils-2.22/mkinstalldirs /tools--with-sysroot=/mnt/lfs--with-lib-path=/tools/lib--target=i686-lfs-linux-gnu /tools--with-sysroot=/mnt/lfs--with-lib-path=/tools/lib--target=i686-lfs-linux-gnu
mkdir -p -- /tools--with-sysroot=/mnt/lfs--with-lib-path=/tools/lib--target=i686-lfs-linux-gnu /tools--with-sysroot=/mnt/lfs--with-lib-path=/tools/lib--target=i686-lfs-linux-gnu
mkdir: cannot create directory `/tools--with-sysroot=': Permission denied
mkdir: cannot create directory `/tools--with-sysroot=': Permission denied
make[1]: *** [installdirs] Error 1
make[1]: Leaving directory `/mnt/lfs/sources/binutils-build'
make: *** [install] Error 2
lfs@logun-HP-Pavilion-dv6-Notebook-PC:/mnt/lfs/sources/binutils-build$

**

最佳答案

我尝试使用 live CD 构建 LFS v6.3,但遇到了完全相同的问题。我认为问题在于,在第 5 章中,手册假定您的工具目录将是/tools 但在上一章中,您被告知配置构建环境以使用 $LFS/tools(映射到/mnt/lfs/tools 并且是当然和/tools 不一样)。这还不清楚,因为直到该章之前的所有内容都是一个演练,告诉您确切地键入哪些命令,然后从第 5 章开始缺少一些关键步骤,并且似乎已经对构建环境做出了不同的假设,或者可能是谁编写了该章5 这样做时没有引用前面的章节。

关于linux - Binutil 权限错误 while "make install",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13781746/

相关文章:

java - VScode 扩展错误,java 运行时无法定位在 linux 的窗口子系统上

c++ - gcc -O4 优化标志

Makefile 隐式规则匹配 - 前缀长度不影响匹配

c++ - 您可以在命令行上使用 visual-c++ 静态链接特定库吗?

gcc - 我可以让 CMake 使用 gcc 增量链接生成 Makefile 吗?

linux - 构建多架构 Debian 软件包的正确方法是什么?

c - 即使我向它发送 SIGABRT,子进程也会正常退出

c++ - 我正在使用 Dev-C++ 并收到一个编译器错误,提示 "collect2.exe"正在接收状态 1

java - 测试设置向导出错

c - 注册变量存储类错误