From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr1-x441.google.com (mail-wr1-x441.google.com [IPv6:2a00:1450:4864:20::441]) by sourceware.org (Postfix) with ESMTPS id D200B385E006 for ; Fri, 27 Mar 2020 10:59:54 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org D200B385E006 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=mittosystems.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=jozef.l@mittosystems.com Received: by mail-wr1-x441.google.com with SMTP id p10so10864501wrt.6 for ; Fri, 27 Mar 2020 03:59:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mittosystems.com; s=google; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=41NJ2O5IsoU/PY3ZKBIeYQdTgr/h8wwSSv6YP5wWoG8=; b=n7O2so7xbNHMWPptjlSNppfi/4jBBcDFzLNkQ5g/jE3DDB0jyylZasJKjq7w9MW143 R5nb6OqlTKhEkOS85OgWMhL14ZrzOwUGnEvA6UlIhP9bBOv08EqhHWsH640b+YmUNf2S oGiDSwBPikIf0wbHHEdww0cJ7dVzyrV5zU6J+ECuYDX3mEysll/TjZj9OM8ICsho+Sx3 30ehyUyGNymFiRIuuEf7EfHCx8+ZpPD/VDzsSPIo1IyObhlSSq/+nWGQy9an0aPB9czH kwm4L3Q+UbcbhgV5CZaJ3a0XWIdVEXDVGT6G5XifnEWW/yjX6G2/zrXO6uaT3aRVNUjq cdqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=41NJ2O5IsoU/PY3ZKBIeYQdTgr/h8wwSSv6YP5wWoG8=; b=luy7JmBgFbf4/bTcpjFslPImNvOyodL2/Ue0nBT0N/pxFv64/59lzDcMLxwIl8qGrV s5StaOqv15l3kfWmy9OOiLVRz+yBYvOB4xt1uMb4LFVVcknMQa8FaWSFRNjqRPCtZMKV 1sufrgiuif7dPZEmFWmtI6ja7bgDd7gn/so016E4WX/nSZ6EpRE3fVrW7rawT4Rv2XOa iAG7YYgd/rxO+HrVPO0FxqP32L4IULDW1/MZbbBzKWjGNcikUr1wZS9jsOWIJvAPYWY2 ann1XmED4GvlejPBzgIRz5EdURpwz+iM+YiDCNTUYYd0skdH4+5UsREYaqpI5vZV5iqC ImqQ== X-Gm-Message-State: ANhLgQ0zT8+YAfWiyck//6V6sYB2pEYxUivlWMmOESNs1NwW6NxQRJkb iz1VzyrHGTYlcQnV7lms8dBPPg== X-Google-Smtp-Source: ADFU+vvAnD6U3VzGMJl5aqeEfT715QX0LQYH9TwKE22wzaj2udtpthXR6XCSgRQmuNAr0xxIb0IZ+g== X-Received: by 2002:a05:6000:4d:: with SMTP id k13mr9391271wrx.356.1585306793926; Fri, 27 Mar 2020 03:59:53 -0700 (PDT) Received: from jozef-kubuntu ([2a01:4b00:87fd:900:457e:908:47dc:232]) by smtp.gmail.com with ESMTPSA id p10sm8077794wrm.6.2020.03.27.03.59.53 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 27 Mar 2020 03:59:53 -0700 (PDT) Date: Fri, 27 Mar 2020 10:59:49 +0000 From: Jozef Lawrynowicz To: Alan Modra Cc: "binutils@sourceware.org" Subject: Re: [PATCH] Add testcase for PR 25662 invalid sh_offset for section Message-ID: <20200327105949.47f1a85c@jozef-kubuntu> In-Reply-To: <20200326212512.GM4583@bubble.grove.modra.org> References: <20200326111036.4e8e59d6@jozef-kubuntu> <20200326212512.GM4583@bubble.grove.modra.org> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-9.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_1, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: binutils@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Mar 2020 10:59:56 -0000 On Fri, 27 Mar 2020 07:55:12 +1030 Alan Modra wrote: > On Thu, Mar 26, 2020 at 11:10:36AM +0000, Jozef Lawrynowicz wrote: > > The attached patch has a testcase for PR binutils/25662, "objcopy sets invalid > > sh_offset for the first section in a no_contents segment containing program > > headers". > > > > The patch also extends the objcopy_test procedure from objcopy.exp, allowing > > either object files or linked executables to be tested. > > > > I verified that the testcase does not error for msp430-elf, > > x86_64-pc-linux-gnu, arm-eabi, ia64-vms (has no linker so the test is > > untested) and i386-pe (is not an ELF target). > > > > Note that the test fails for i386-pe, objdump -x output shows that the > > "Time/Date" field has been reset to epoch 0. > > > > Ok to apply? > > OK, thanks. Yes, we are going to have some fails with this new test. > Hmm, objcopy -p doesn't help with the PE date stamp and it seems like > it should. > > You might like to simplify the LD test. > > > + set status [remote_exec host $LD -v] > > + if { [lindex $status 0] != 0 } { > > if {[which $LD] == 0} then { > > > + untested "objcopy $type ($testname)" > > + return > > + } > Thanks for the tip. Fixed that and pushed to master. Jozef