From b6d0e2b7e1c8611578e915af4ef8d8066d6f3bee Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Wed, 2 Mar 2022 17:50:41 +0800 Subject: [PATCH] gcc pass2: use --target=$LFS_TGT instead of many {C,CXX}_FOR_TARGET There is also a "GCC_FOR_TARGET" which was not set correctly. The --target=$LFS_TGT parameter can set up all of these variables as we expected. --- chapter06/gcc-pass2.xml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/chapter06/gcc-pass2.xml b/chapter06/gcc-pass2.xml index f422a9a64..d313feff2 100644 --- a/chapter06/gcc-pass2.xml +++ b/chapter06/gcc-pass2.xml @@ -92,10 +92,9 @@ cd build ../configure \ --build=$(../config.guess) \ --host=$LFS_TGT \ - --prefix=/usr \ - CC_FOR_TARGET=$LFS_TGT-gcc \ - CXX_FOR_TARGET=$LFS_TGT-g++ \ + --target=$LFS_TGT \ LDFLAGS_FOR_TARGET=-L$PWD/$LFS_TGT/libgcc \ + --prefix=/usr \ --with-build-sysroot=$LFS \ --enable-initfini-array \ --disable-nls \