From patchwork Fri Feb 4 16:47:25 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Tremer X-Patchwork-Id: 5056 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4Jr1gW0R9gz3xff for ; Fri, 4 Feb 2022 16:48:07 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4Jr1gM2bMpz5MG; Fri, 4 Feb 2022 16:47:59 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4Jr1gM265dz32KM; Fri, 4 Feb 2022 16:47:59 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4Jr1gJ1RzPz2ynw for ; Fri, 4 Feb 2022 16:47:56 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4Jr1gJ0g2Kz1qH; Fri, 4 Feb 2022 16:47:56 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1643993276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=8ibtCLNpoePYpjO3jLHdfzqFVOujR5hNJBE+6tPlKCY=; b=IpLehdBDbq0GC/Bj+qR+DwetYtTUZBLdMLa9/D1qTDfCRtlwi+94i/2P5PnpovDnqGyLPn CHWhyd5d7nQ1mtAQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1643993276; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=8ibtCLNpoePYpjO3jLHdfzqFVOujR5hNJBE+6tPlKCY=; b=DzRCUfMF2CTqlKkwcz0gbCn9uiDs+0sQu0fw2VXyKdLqcffRLpdtegMWcPuK+pPfe0S0tb FS+5+Ssk5hBmZ50hctEB1eLp+CejX06F8uEyMakQEKXUO6I7wVsSx3FeroOHTzwxibC6x3 5yhSJ/qPCkf1Y6iBEJ/yz/Ge6ViYZGJiZQfuIvr1PJBfDod8MLFaMtjY6yMNj8ZInGVTjG cbeBahoSipVBwPgHR7F5PYAruCeNaUCvLjskykz2gyBwV3YYJoCxO6iE1ihr2ABMgV6aGy NkNwp2ZxoKmbwI93OxmoLWRimIQksdmurCJ1XFPtK+5kdWZfmdcVbCGXXe2LoQ== From: Michael Tremer To: development@lists.ipfire.org Subject: [PATCH 05/28] binutils+gcc: Fix that the toolchain compiler is trying to link against host libraries Date: Fri, 4 Feb 2022 16:47:25 +0000 Message-Id: <20220204164748.315559-5-michael.tremer@ipfire.org> In-Reply-To: <20220204164748.315559-1-michael.tremer@ipfire.org> References: <20220204164748.315559-1-michael.tremer@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Michael Tremer Errors-To: development-bounces@lists.ipfire.org Sender: "Development" Binutils and GCC were misconfigured and used host libraries to build toolchain programs. That resulted in that those programs were correctly linked, but could not be executed, because the runtime linker did not search in the host system. Signed-off-by: Michael Tremer --- lfs/binutils | 9 +++++---- lfs/gcc | 5 +++-- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/lfs/binutils b/lfs/binutils index d94be9a06..94e295cf9 100644 --- a/lfs/binutils +++ b/lfs/binutils @@ -59,7 +59,8 @@ ifeq "$(PASS)" "1" --target=$(CROSSTARGET) \ --prefix=$(TOOLS_DIR) \ --with-sysroot=$(ROOT) \ - --with-lib-path=$(TOOLS_DIR)/lib + --with-lib-path=$(TOOLS_DIR)/lib \ + --disable-nls EXTRA_MAKE = EXTRA_INSTALL = else @@ -69,10 +70,10 @@ else AR="$(CROSSTARGET)-ar" \ RANLIB="$(CROSSTARGET)-ranlib" EXTRA_CONFIG = \ - --host=$(BUILDTARGET) \ - --build=$(BUILDTARGET) \ --prefix=$(TOOLS_DIR) \ - --with-lib-path=$(TOOLS_DIR)/lib + --with-lib-path=$(TOOLS_DIR)/lib \ + --with-sysroot \ + --disable-nls EXTRA_MAKE = EXTRA_INSTALL = endif diff --git a/lfs/gcc b/lfs/gcc index 96e58ddae..6bb1d170a 100644 --- a/lfs/gcc +++ b/lfs/gcc @@ -83,8 +83,10 @@ ifeq "$(PASS)" "1" --with-sysroot=$(ROOT) \ --with-local-prefix=$(TOOLS_DIR) \ --with-native-system-header-dir=$(TOOLS_DIR)/include \ + --with-glibc-version=2.11 \ --disable-nls \ --disable-shared \ + --disable-multilib \ --disable-decimal-float \ --disable-threads \ --disable-libatomic \ @@ -114,13 +116,12 @@ ifeq "$(PASS)" "2" AR="$(CROSSTARGET)-ar" \ RANLIB="$(CROSSTARGET)-ranlib" EXTRA_CONFIG = \ - --build=$(BUILDTARGET) \ --prefix=$(TOOLS_DIR) \ - --with-sysroot=$(ROOT) \ --with-local-prefix=$(TOOLS_DIR) \ --with-native-system-header-dir=$(TOOLS_DIR)/include \ --enable-languages=c,c++ \ --disable-libstdcxx-pch \ + --disable-multilib \ --disable-libgomp EXTRA_MAKE = EXTRA_INSTALL =