From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pl1-x630.google.com (mail-pl1-x630.google.com [IPv6:2607:f8b0:4864:20::630]) by sourceware.org (Postfix) with ESMTPS id 541EB3856948 for ; Tue, 30 May 2023 17:13:17 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 541EB3856948 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pl1-x630.google.com with SMTP id d9443c01a7336-1b01bd7093aso26794485ad.1 for ; Tue, 30 May 2023 10:13:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1685466796; x=1688058796; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=+w/XFqp1AH7F/ZPtN1MljK1VhBFQbFfGgkzyrv5Cwhs=; b=azh6gAsV6gzOW9JtNlBlyul3pvdDvtvpyG3zBtCC+ORt4LuZUtnQ6QV4X1cZySZYZS zpygylq4g9x9qSFQLtywrm59iCKsU57T3xwNQTqzZdL6zKWPrtQnKNbBEsRmVNl5NbZg gxAsqfgWJYRa6lE50YDEPAQPWwJDHsEp2Thc4uHa/tU4jh8RySbibmBoKPWpEPVeb8xr hFCXCFUrR4cBIIu72vkEEe6bpjobiEuyzoGqswFlytJVvbjG11oPWihD56kRFdM53v2k bmgz4AYT9uatzJezEHU3AO2XIr/fKZF6MHfnDtsjBR7RC3zaqjHTexkQFWQXy8nWFF/O qNsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685466796; x=1688058796; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=+w/XFqp1AH7F/ZPtN1MljK1VhBFQbFfGgkzyrv5Cwhs=; b=YumuPxWgT/Z9VXZp8eQy2KuLvW7OtWA2DfeESadAjVNmB50huphl+PWnWjHegtbWz2 BDDFg7Qya2nGKWHEjf0TB1UgPM0XU6i99sQ55HUdeZmtVzLzT/AiNqah74EUW42fLdE+ X5+pHIMFux89WfE4VjulKZ34ZJMLnxCWEU2N70UfTNKB59VvJJ9G8+YzsKG4aCGaKbSc E1fOBXvcPKesACvXhJX7R+qsOHrtH8oOSoXl8nT8Hy867tbLWx5NlQBrW2XY0oUNsfmr LnVr6zGXVzJA/m3UYXBqB3evoZ2J4CUlzUIxu382W4uopzpdbV8/p33HBSyZIxC7q7YC /vhw== X-Gm-Message-State: AC+VfDyzQxT3J2DP6sWGzVey+SGJhSLCcJUJ/QKHDpGwxKAXyoQqn+Pm BVq5IXoCsdJJPzuGr/g9ztDPZyamtM8= X-Google-Smtp-Source: ACHHUZ5AkedUKiHHEIdm3Q2jpfTov2NucgXsBS0BlsaPi/mwXvTYUdzcXlQPjZGIQR+hT+Dkeof3Mw== X-Received: by 2002:a17:902:ecc2:b0:1b0:fe9:e57e with SMTP id a2-20020a170902ecc200b001b00fe9e57emr3544052plh.0.1685466796307; Tue, 30 May 2023 10:13:16 -0700 (PDT) Received: from gnu-cfl-3.localdomain ([172.59.160.123]) by smtp.gmail.com with ESMTPSA id a4-20020a1709027d8400b0019a5aa7eab0sm10509359plm.54.2023.05.30.10.13.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 May 2023 10:13:15 -0700 (PDT) Received: from gnu-cfl-3.. (localhost [IPv6:::1]) by gnu-cfl-3.localdomain (Postfix) with ESMTP id D18287402EA; Tue, 30 May 2023 10:13:14 -0700 (PDT) From: "H.J. Lu" To: binutils@sourceware.org Cc: Kaylee Blake Subject: [PATCH 6/6] ld: Add -z nosectionheader test to bootstrap.exp Date: Tue, 30 May 2023 10:12:52 -0700 Message-Id: <20230530171252.269552-7-hjl.tools@gmail.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230530171252.269552-1-hjl.tools@gmail.com> References: <20230530171252.269552-1-hjl.tools@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3024.9 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,GIT_PATCH_0,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,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 List-Id: PR ld/25617 * testsuite/ld-bootstrap/bootstrap.exp: Add -z nosectionheader test. --- ld/testsuite/ld-bootstrap/bootstrap.exp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/ld/testsuite/ld-bootstrap/bootstrap.exp b/ld/testsuite/ld-bootstrap/bootstrap.exp index b189a0c7098..7b70b9582c0 100644 --- a/ld/testsuite/ld-bootstrap/bootstrap.exp +++ b/ld/testsuite/ld-bootstrap/bootstrap.exp @@ -66,6 +66,9 @@ set test_flags {"" "strip" "--static" "-Wl,--traditional-format" if { [istarget "powerpc-*-*"] } { lappend test_flags "-Wl,--ppc476-workaround" } +if { [is_elf_format] && ![is_bad_symtab] } { + lappend test_flags "-Wl,-z,nosectionheader" +} set gcc_B_opt_save $gcc_B_opt @@ -94,9 +97,12 @@ foreach flags $test_flags { set testname "bootstrap" }} - # --static is meaningless and --relax is incompatible with -r. + # --static is meaningless. --relax and -z nosectionheader are + # incompatible with -r. regsub -- "-Wl," $flags "" partial_flags - if { "$partial_flags" == "--static" || "$partial_flags" == "--relax" } { + if { "$partial_flags" == "--static" \ + || "$partial_flags" == "--relax" \ + || [string match "*nosectionheader*" "$partial_flags"] } { set partial_flags "" } -- 2.40.1