From patchwork Mon Feb 3 17:43:59 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Richard Earnshaw (lists)" X-Patchwork-Id: 1232936 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-518788-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.a=rsa-sha1 header.s=default header.b=F5V4rPiF; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 48BFZB4k1jz9s29 for ; Tue, 4 Feb 2020 04:44:16 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:to :from:subject:message-id:date:mime-version:content-type; q=dns; s=default; b=pflSNBRrcA4FgoUlppvOfFW2TzPr+W5ci8r1XBSopRsR6IKMWL OWnCX58CPqizEUprva9F8lwShsc5g/RDNiBAlIpH3DW/VWojMKTHD/GnzRJXJAKy LDGOrwDaYG7D+NfT9G61LUWcW03bgNJiNyLajCouFYPu7Hx5RzvXM+iLw= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:to :from:subject:message-id:date:mime-version:content-type; s= default; bh=IlhprZXZJ4UWP54g8hUxAgjc21M=; b=F5V4rPiFbIJ5Vfp6q2kn /qUpEnUSOrfXBojRnv5NUQNr73I0Hlsgp11sc1qFyuq726hzqqqjRjREO7Eq9lm7 Ovq+8cKPRf4JkJAl0FtlqttbaQlEzMcJM+KDOFoOC4TCiFqBy2H8XyRg204fW2hx wC3GADa6gXqk6a5hr6bLFQo= Received: (qmail 108120 invoked by alias); 3 Feb 2020 17:44:03 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 108112 invoked by uid 89); 3 Feb 2020 17:44:03 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-18.8 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.1 spammy=AWK X-HELO: foss.arm.com Received: from foss.arm.com (HELO foss.arm.com) (217.140.110.172) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 03 Feb 2020 17:44:02 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 829F730E; Mon, 3 Feb 2020 09:44:00 -0800 (PST) Received: from e120077-lin.cambridge.arm.com (e120077-lin.cambridge.arm.com [10.2.78.81]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 2D8663F52E; Mon, 3 Feb 2020 09:44:00 -0800 (PST) To: "gcc-patches@gcc.gnu.org" From: "Richard Earnshaw (lists)" Subject: [committed] arm: Use move-if-change for updating regenerated files [PR93548] Message-ID: Date: Mon, 3 Feb 2020 17:43:59 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 MIME-Version: 1.0 The t-arm make fragment currently uses 'mv' to update some files that are automatically regenerated, but this causes problems on read-only filesystems if the date stamps are incorrect and the files have not really changed. So use move-if-change instead. PR target/93548 * config/arm/t-arm: ($(srcdir)/config/arm/arm-tune.md, $(srcdir)/config/arm/arm-tables.opt): Use move-if-change. diff --git a/gcc/config/arm/t-arm b/gcc/config/arm/t-arm index e8483d45688..b883f796956 100644 --- a/gcc/config/arm/t-arm +++ b/gcc/config/arm/t-arm @@ -70,13 +70,15 @@ $(srcdir)/config/arm/arm-tune.md: $(srcdir)/config/arm/parsecpu.awk \ $(srcdir)/config/arm/arm-cpus.in $(AWK) -f $(srcdir)/config/arm/parsecpu.awk -v cmd=md \ $(srcdir)/config/arm/arm-cpus.in > arm-tune.new - mv arm-tune.new $(srcdir)/config/arm/arm-tune.md + $(srcdir)/../move-if-change arm-tune.new \ + $(srcdir)/config/arm/arm-tune.md $(srcdir)/config/arm/arm-tables.opt: $(srcdir)/config/arm/parsecpu.awk \ $(srcdir)/config/arm/arm-cpus.in $(AWK) -f $(srcdir)/config/arm/parsecpu.awk -v cmd=opt \ $(srcdir)/config/arm/arm-cpus.in > arm-tables.new - mv arm-tables.new $(srcdir)/config/arm/arm-tables.opt + $(srcdir)/../move-if-change arm-tables.new \ + $(srcdir)/config/arm/arm-tables.opt arm-cpu.h: s-arm-cpu ; @true s-arm-cpu: $(srcdir)/config/arm/parsecpu.awk \