From patchwork Mon Apr 17 02:39:19 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: ticat_fp X-Patchwork-Id: 83950 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1840915vqo; Sun, 16 Apr 2023 19:40:16 -0700 (PDT) X-Google-Smtp-Source: AKy350bnT2J66o2jT/DnM3OkIafsuG4pCqyOrEhChSQU1NIeQT/XOa0jHX2hUDTWHWJM9CIhwlvP X-Received: by 2002:a05:6402:1486:b0:4fd:29a1:6a58 with SMTP id e6-20020a056402148600b004fd29a16a58mr14556116edv.19.1681699216526; Sun, 16 Apr 2023 19:40:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681699216; cv=none; d=google.com; s=arc-20160816; b=DNEjoJfgDHD57iHLdAjcdk/EgWXPXVJNKnXuutE5bp9PMwyZPq2bMFwBUMkEUbaON4 4IvmQOh28cJFIrZ8CXrGATGwzTt6UdoEXglby08nm/MSHYsnOcjWsfcagF1HuY8IaJpf /wReyUdonswG9KApHn6vLBk2qtMK1lCnE52OCR1wjyAOE3/p6w85nNEm/WtjSV5TzyfW I6itIvWmlCP7Z8AxD7dSIG0zsRWqTwsGdviNpr5MWv+RgdHuYIMKhpIrCH9gfvfho/l9 wDWTQSN6sqTwRqXcRoymSmX/U5S4JlHPFDXIZJ+Sv5+3XZLdbGII1J7CtQEi/4lc5Euj slqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dmarc-filter :delivered-to; bh=IKyjRh/+AHsKD3mwRzUNwSq2vLQPcK4uFV/inCkcOgg=; b=d+JKLZu5NxfvQZzRiPSPsmMMHN5Nih7xiMdZRmShvBFeORkcn+P4x41fNvQhA0xdRT 2ZUSJgXYiz3yyc0u4w4mOeafPv+OuhULunsh3rdJ28Jc1oJ0oXQkO09tWyhGqMplYPjT YXCsDKSWPro6hguOGkjOIGugEpGiM6alV93Jd8Qc2f9bAKNRoYkZYNN3VOrFkiihBbDy 5q/MW6X8tGfyUDl4PZ4bZ/y66REjVLRqDd3yyX62cx0G009+7oyszEGrPANhOBa2iP20 8f8x/do9+D5tAt9EaG9de9pu6H6fPLYTpgtYRGE2tIRoPPUl4XDi2sgrqtZkulb4IFA+ lXBg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id b7-20020a056402138700b00504bba124ddsi8717615edv.243.2023.04.16.19.40.15 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 16 Apr 2023 19:40:16 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 1D5A33857726 for ; Mon, 17 Apr 2023 02:39:57 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from loongson.cn (mail.loongson.cn [114.242.206.163]) by sourceware.org (Postfix) with ESMTP id 1BABB3858D38 for ; Mon, 17 Apr 2023 02:39:30 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1BABB3858D38 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=loongson.cn Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=loongson.cn Received: from loongson.cn (unknown [111.9.175.10]) by gateway (Coremail) with SMTP id _____8Dxj81fsTxkq7sdAA--.46234S3; Mon, 17 Apr 2023 10:39:28 +0800 (CST) Received: from localhost.localdomain (unknown [111.9.175.10]) by localhost.localdomain (Coremail) with SMTP id AQAAf8Bx671ZsTxkikcqAA--.49029S2; Mon, 17 Apr 2023 10:39:26 +0800 (CST) From: Peng Fan To: gcc-patches@gcc.gnu.org Cc: chenglulu@loongson.cn Subject: [PATCH] LoongArch: fix MUSL_DYNAMIC_LINKER Date: Mon, 17 Apr 2023 10:39:19 +0800 Message-Id: <20230417023919.7015-1-fanpeng@loongson.cn> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-CM-TRANSID: AQAAf8Bx671ZsTxkikcqAA--.49029S2 X-CM-SenderInfo: xidq1vtqj6z05rqj20fqof0/1tbiAQABEmQ38PkZBABTsG X-Coremail-Antispam: 1Uk129KBjvdXoWrKFW5GFW7KFykWFWDKryDZFb_yoWDtwcEva sxJFWkWrWxC3s7K3yDXa4rK3WfuFs2q3Z3C3W3Kw1IkrZ7tr43ArWUGw13Cw1YkrW5XFnx Xr4v9r13CFy2yjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8wcxFpf9Il3svdxBIdaVrn0 xqx4xG64xvF2IEw4CE5I8CrVC2j2Jv73VFW2AGmfu7bjvjm3AaLaJ3UjIYCTnIWjp_UUUY 17kC6x804xWl14x267AKxVWUJVW8JwAFc2x0x2IEx4CE42xK8VAvwI8IcIk0rVWrJVCq3w AFIxvE14AKwVWUJVWUGwA2ocxC64kIII0Yj41l84x0c7CEw4AK67xGY2AK021l84ACjcxK 6xIIjxv20xvE14v26ryj6F1UM28EF7xvwVC0I7IYx2IY6xkF7I0E14v26r4j6F4UM28EF7 xvwVC2z280aVAFwI0_Gr1j6F4UJwA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_Gr1j6F4UJwAS 0I0E0xvYzxvE52x082IY62kv0487Mc804VCY07AIYIkI8VC2zVCFFI0UMc02F40EFcxC0V AKzVAqx4xG6I80ewAv7VC0I7IYx2IY67AKxVWUJVWUGwAv7VC2z280aVAFwI0_Jr0_Gr1l Ox8S6xCaFVCjc4AY6r1j6r4UM4x0Y48IcxkI7VAKI48JMxAIw28IcxkI7VAKI48JMxC20s 026xCaFVCjc4AY6r1j6r4UMI8I3I0E5I8CrVAFwI0_Jr0_Jr4lx2IqxVCjr7xvwVAFwI0_ JrI_JrWlx4CE17CEb7AF67AKxVWUXVWUAwCIc40Y0x0EwIxGrwCI42IY6xIIjxv20xvE14 v26r1j6r1xMIIF0xvE2Ix0cI8IcVCY1x0267AKxVWUJVW8JwCI42IY6xAIw20EY4v20xva j40_Jr0_JF4lIxAIcVC2z280aVAFwI0_Jr0_Gr1lIxAIcVC2z280aVCY1x0267AKxVWUJV W8JbIYCTnIWIevJa73UjIFyTuYvjxUzsqWUUUUU X-Spam-Status: No, score=-13.2 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_STATUS, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1763389437804139398?= X-GMAIL-MSGID: =?utf-8?q?1763389437804139398?= The system based on musl has no '/lib64', so change it. gcc/ * config/loongarch/gnu-user.h (MUSL_DYNAMIC_LINKER): Redefine. Signed-off-by: Peng Fan --- gcc/config/loongarch/gnu-user.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gcc/config/loongarch/gnu-user.h b/gcc/config/loongarch/gnu-user.h index aecaa02a199..fa1a5211419 100644 --- a/gcc/config/loongarch/gnu-user.h +++ b/gcc/config/loongarch/gnu-user.h @@ -33,9 +33,14 @@ along with GCC; see the file COPYING3. If not see #define GLIBC_DYNAMIC_LINKER \ "/lib" ABI_GRLEN_SPEC "/ld-linux-loongarch-" ABI_SPEC ".so.1" +#define MUSL_ABI_SPEC \ + "%{mabi=lp64d:-lp64d}" \ + "%{mabi=lp64f:-lp64f}" \ + "%{mabi=lp64s:-lp64s}" + #undef MUSL_DYNAMIC_LINKER #define MUSL_DYNAMIC_LINKER \ - "/lib" ABI_GRLEN_SPEC "/ld-musl-loongarch-" ABI_SPEC ".so.1" + "/lib/ld-musl-loongarch" ABI_GRLEN_SPEC MUSL_ABI_SPEC ".so.1" #undef GNU_USER_TARGET_LINK_SPEC #define GNU_USER_TARGET_LINK_SPEC \