From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.5 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 705DAC433DB for ; Fri, 22 Jan 2021 11:27:55 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0AD8422DCC for ; Fri, 22 Jan 2021 11:27:54 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0AD8422DCC Authentication-Results: mail.kernel.org; dmarc=fail (p=quarantine dis=none) header.from=suse.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Received: from list by lists.xenproject.org with outflank-mailman.72695.130929 (Exim 4.92) (envelope-from ) id 1l2ubF-0008Ba-2W; Fri, 22 Jan 2021 11:27:33 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 72695.130929; Fri, 22 Jan 2021 11:27:33 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1l2ubE-0008BT-V9; Fri, 22 Jan 2021 11:27:32 +0000 Received: by outflank-mailman (input) for mailman id 72695; Fri, 22 Jan 2021 11:27:31 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1l2ubD-0008BO-Ks for xen-devel@lists.xenproject.org; Fri, 22 Jan 2021 11:27:31 +0000 Received: from mx2.suse.de (unknown [195.135.220.15]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id cbadab7c-fd2e-487f-a4b6-2b4b8c9123ef; Fri, 22 Jan 2021 11:27:30 +0000 (UTC) Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 7E8F9AB9F; Fri, 22 Jan 2021 11:27:29 +0000 (UTC) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: cbadab7c-fd2e-487f-a4b6-2b4b8c9123ef X-Virus-Scanned: by amavisd-new at test-mx.suse.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1611314849; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=acRTWlwsRO3tCobqEArtH/sD9iTUEWe8VYcJ4NrOAWs=; b=C71jDvR1knPOI6WT4GWyjNVa8CBIhLVeLMEbnLxBU8TKI37W7KGtnImeK45nJ8U54WZqmk 2engRo1KqJ5hulLoxLQDD2uO3ImTTNGtZHycO5jpobE5O5Nnz+55ODJuayodMpq3HfP1RA qTu03BPGh0eOOQGqQr7UMmEid7QbhLI= Subject: Re: [PATCH v3 1/5] xen: add XEN_BUILD_POSIX_TIME To: Bobby Eshleman , Daniel Kiper Cc: Andrew Cooper , George Dunlap , Ian Jackson , Julien Grall , Stefano Stabellini , Wei Liu , Xen-devel References: From: Jan Beulich Message-ID: <52e85ee7-b980-ece1-50d4-7deac182bca0@suse.com> Date: Fri, 22 Jan 2021 12:27:29 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.6.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit On 22.01.2021 01:51, Bobby Eshleman wrote: > From: Daniel Kiper > > POSIX time is required to fill the TimeDateStamp field > in the PE header. > > Use SOURCE_DATE_EPOCH if available, otherwise use > `date +%s` (available on both Linux and FreeBSD). > > Signed-off-by: Daniel Kiper > Signed-off-by: Bobby Eshleman Especially with there not being any user of the new item, you will want to at least briefly explain ... > --- a/xen/Makefile > +++ b/xen/Makefile > @@ -11,6 +11,7 @@ export XEN_DOMAIN ?= $(shell ([ -x /bin/dnsdomainname ] && /bin/dnsdomainname) | > export XEN_BUILD_DATE ?= $(shell LC_ALL=C date) > export XEN_BUILD_TIME ?= $(shell LC_ALL=C date +%T) > export XEN_BUILD_HOST ?= $(shell hostname) > +export XEN_BUILD_POSIX_TIME ?= $(shell echo $${SOURCE_DATE_EPOCH:-$(shell date +%s)}) ... the use of SOURCE_DATE_EPOCH here when it's not used for XEN_BUILD_TIME (the two could also do with living side by side) and ... > --- a/xen/include/xen/compile.h.in > +++ b/xen/include/xen/compile.h.in > @@ -1,5 +1,6 @@ > #define XEN_COMPILE_DATE "@@date@@" > #define XEN_COMPILE_TIME "@@time@@" > +#define XEN_COMPILE_POSIX_TIME @@posix_time@@ > #define XEN_COMPILE_BY "@@whoami@@" > #define XEN_COMPILE_DOMAIN "@@domain@@" > #define XEN_COMPILE_HOST "@@hostname@@" ... the lack of quotes here when all neighboring items have them. Jan