문제

I'm learning linux knowledges, when I compile binutils or gcc and install them, they always appear in two locations.

I think it must be a reason and I don't know why?

Actually I'm learning lfs. When I compile the pass I of binutils, the book's instructions is:

../binutils-2.22/configure     \
    --prefix=/tools            \
    --with-sysroot=$LFS        \
    --with-lib-path=/tools/lib \
    --target=$LFS_TGT          \
    --disable-nls              \
    --disable-werror

After I make && make install, it is installed in two locations: /tools/bin and /tools/$LFS_TGT/bin.

I want to why and the purpose of doing that.

도움이 되었습니까?

해결책

Essentially, the binary that is in /tools/$LFS_TGT/bin is the version of the tool that is specifically built for that particular $LFS_TGT. A second copy is placed in /tools/$LFS_TGT, because the tool is intended to replace the one that is already present there because you told it to do that using the --with-sysroot option

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top