From patchwork Tue Jun 11 10:32:31 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nylon Chen X-Patchwork-Id: 1113648 X-Patchwork-Delegate: blogic@openwrt.org Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=andestech.com Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="iF4dqTds"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 45NRBn4LXHz9sDB for ; Tue, 11 Jun 2019 20:32:01 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Subject:MIME-Version:Message-ID:Date:To :From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=m4F+8ipdBIs0Ttw4ucZYaZuBwO7yJb6MR7KQJQ2QCrM=; b=iF4dqTdso2HLaj ZNv4bme2P6ExsTmItjFTkdtaJ8yS8VkbT1QAlReMH2RgGn+FtIpX2qW04yHaxx0a0i0YSagzHjO/U /VIRmccMp38pBrPwx84hFOpa5Pwec8FTCgtNdvmk5QACEWLgDcB0zSXgbU6zyjaRJGUwpbNCai0fF i3eRaAaruUkpNpx5fowKVLC2K/NPiNv3JaoBatxsMBn7IxpOLRvPV1O/x9yJxgxoBGtJioE6FvvBy DpQtii725ZLtQigKTcTV7BjV1R65afCdhgBpKwTl49E6G7Bh41hVkSsBezzACZ5enQoE22N/hODV8 vG6z3fl84QIv5So2U6kg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hae4B-0008UU-DT; Tue, 11 Jun 2019 10:31:47 +0000 Received: from 59-120-53-16.hinet-ip.hinet.net ([59.120.53.16] helo=ATCSQR.andestech.com) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hae48-0008U1-2o for openwrt-devel@lists.openwrt.org; Tue, 11 Jun 2019 10:31:45 +0000 Received: from mail.andestech.com (atcpcs16.andestech.com [10.0.1.222]) by ATCSQR.andestech.com with ESMTP id x5BAP5PF076457; Tue, 11 Jun 2019 18:25:05 +0800 (GMT-8) (envelope-from nylon7@andestech.com) Received: from atcfdc88.andestech.com (10.0.15.132) by ATCPCS16.andestech.com (10.0.1.222) with Microsoft SMTP Server id 14.3.123.3; Tue, 11 Jun 2019 18:31:35 +0800 From: Nylon Chen To: Date: Tue, 11 Jun 2019 18:32:31 +0800 Message-ID: <20190611103231.31851-1-nylon7@andestech.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-Originating-IP: [10.0.15.132] X-DNSRBL: X-MAIL: ATCSQR.andestech.com x5BAP5PF076457 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190611_033144_375161_75A9842E X-CRM114-Status: UNSURE ( 4.48 ) X-CRM114-Notice: Please train this message. X-Spam-Score: 0.4 (/) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (0.4 points) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 TVD_RCVD_IP Message was received from an IP address 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.4 RDNS_DYNAMIC Delivered to internal network by host with dynamic-looking rDNS Subject: [OpenWrt-Devel] [PATCH 3/4] ext-toolchain.sh: don't pass CFLAGS to gcc-* utilities X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Nylon Chen , Nylon Chen , Che-Wei Chuang , Greentime Hu Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org The current script passes CFLAGS parameters to gcc-* utilities, but they can not identify CFLAGS parameters, so following this script will fail package build Signed-off-by: Che-Wei Chuang Signed-off-by: Nylon Chen --- scripts/ext-toolchain.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/ext-toolchain.sh b/scripts/ext-toolchain.sh index ee7d9532f5..2720a509db 100755 --- a/scripts/ext-toolchain.sh +++ b/scripts/ext-toolchain.sh @@ -256,6 +256,15 @@ wrap_bins() { fi case "${cmd##*/}" in + *gcc-ar) + wrap_bin_other "$out" "$bin" + ;; + *gcc-nm) + wrap_bin_other "$out" "$bin" + ;; + *gcc-ranlib) + wrap_bin_other "$out" "$bin" + ;; *-*cc|*-*cc-*|*-*++|*-*++-*|*-cpp) wrap_bin_cc "$out" "$bin" ;; From patchwork Tue Jun 11 10:32:48 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nylon Chen X-Patchwork-Id: 1113649 X-Patchwork-Delegate: blogic@openwrt.org Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=andestech.com Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Vyd4NBHu"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 45NRC01NSyz9s5c for ; Tue, 11 Jun 2019 20:32:12 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Subject:MIME-Version:Message-ID:Date:To :From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=hsVtd2qAEkn/WPkAKnO/9/LmeLIPnwEU/rJKgqIIXzs=; b=Vyd4NBHuRJRjKV p3SGam3T3aDE2Lg7TuHjU6G8DVwHiONPp4u9EvYujyCQNbkKK25B1IIJR7ND9eGm+HkL7zKPBTRbY UI5adl/eTNld4TXDxB1wAptriuUEzojMJHahzw6yrgGRc75CnYQEm0v0goG7iO3AYXgacs2VSW0V9 tF6KRvj13KlhRsu+uuJa1DbjG7FC0SfAaGSDcsljkYW+imygaWF03BgrOJIcXPcg96rXND2+yRfin dOpGfQT3Mp8AnI/NHXxGRHa4VapmXlYAnJJ/pB6S6fhL/C7njObmzItmZ3FtTKm/qj/znTWQp0iD+ weLKOmLMcApRlQOqasdw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hae4P-0000Ih-R7; Tue, 11 Jun 2019 10:32:01 +0000 Received: from 59-120-53-16.hinet-ip.hinet.net ([59.120.53.16] helo=ATCSQR.andestech.com) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hae4M-0000Eb-Ma for openwrt-devel@lists.openwrt.org; Tue, 11 Jun 2019 10:32:00 +0000 Received: from mail.andestech.com (atcpcs16.andestech.com [10.0.1.222]) by ATCSQR.andestech.com with ESMTP id x5BAPKXM076493; Tue, 11 Jun 2019 18:25:20 +0800 (GMT-8) (envelope-from nylon7@andestech.com) Received: from atcfdc88.andestech.com (10.0.15.132) by ATCPCS16.andestech.com (10.0.1.222) with Microsoft SMTP Server id 14.3.123.3; Tue, 11 Jun 2019 18:31:51 +0800 From: Nylon Chen To: Date: Tue, 11 Jun 2019 18:32:48 +0800 Message-ID: <20190611103248.31917-1-nylon7@andestech.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-Originating-IP: [10.0.15.132] X-DNSRBL: X-MAIL: ATCSQR.andestech.com x5BAPKXM076493 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190611_033159_046403_BA90B6C6 X-CRM114-Status: UNSURE ( 5.86 ) X-CRM114-Notice: Please train this message. X-Spam-Score: 0.4 (/) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (0.4 points) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 TVD_RCVD_IP Message was received from an IP address 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.4 RDNS_DYNAMIC Delivered to internal network by host with dynamic-looking rDNS Subject: [OpenWrt-Devel] [PATCH 4/4] package: fix "LTO" option resulted in building error X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Nylon Chen , Nylon Chen , Che-Wei Chuang , Greentime Hu Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org When a building package has -flto option leads to building error We must use the gcc-ar wrapper instead of ar to invoke ar with the right plugin arguments for handling the LTO objects when -flto is specified. Signed-off-by: Che-Wei Chuang Signed-off-by: Nylon Chen --- rules.mk | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/rules.mk b/rules.mk index 80cb3d63f4..8d1c2b7cd2 100644 --- a/rules.mk +++ b/rules.mk @@ -256,9 +256,15 @@ ifeq ($(CONFIG_EXTERNAL_TOOLCHAIN),) TARGET_RANLIB:=$(TARGET_CROSS)gcc-ranlib TARGET_NM:=$(TARGET_CROSS)gcc-nm else - TARGET_AR:=$(TARGET_CROSS)ar - TARGET_RANLIB:=$(TARGET_CROSS)ranlib - TARGET_NM:=$(TARGET_CROSS)nm + ifeq ($(ARCH),nds32) + TARGET_AR:=$(TARGET_CROSS)gcc-ar + TARGET_RANLIB:=$(TARGET_CROSS)gcc-ranlib + TARGET_NM:=$(TARGET_CROSS)gcc-nm + else + TARGET_AR:=$(TARGET_CROSS)ar + TARGET_RANLIB:=$(TARGET_CROSS)ranlib + TARGET_NM:=$(TARGET_CROSS)nm + endif endif BUILD_KEY=$(TOPDIR)/key-build