From patchwork Sat Aug 1 09:43:22 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Packham X-Patchwork-Id: 502808 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 08C401402D1 for ; Sat, 1 Aug 2015 23:08:25 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=DWFJV2em; dkim-atps=neutral Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E965D4BB95; Sat, 1 Aug 2015 15:08:22 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 1BAzCXjgNYWl; Sat, 1 Aug 2015 15:08:22 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id CF8B84BB79; Sat, 1 Aug 2015 15:08:21 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id A75894BB70 for ; Sat, 1 Aug 2015 11:43:45 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id cmtraYI_TWjF for ; Sat, 1 Aug 2015 11:43:45 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-pa0-f44.google.com (mail-pa0-f44.google.com [209.85.220.44]) by theia.denx.de (Postfix) with ESMTPS id 26A3A4BB6F for ; Sat, 1 Aug 2015 11:43:41 +0200 (CEST) Received: by pabkd10 with SMTP id kd10so54685407pab.2 for ; Sat, 01 Aug 2015 02:43:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=bHgV9lEqk78gi6VOjvAB9xxS4moRSyVwFvxobDJQnYI=; b=DWFJV2emP3eIUvpvPf5nxotlulXb/X/TFd/2zmTyJLMX8U58uoDm5pE42c+wL7BRpP F627dgzbXhwUuJIjlGH+RdR1WLie7T9gd0wkch7ySA2N2Ln3RCa09FGBWTq0bVjc4mlt hF+B7mJvZy06bT5GhpDS2l7SMqi9PyyceFIroL0cBpeEew4Eclv7MjJjhtx3Z8kO7/u4 rfOstCUgHP/XScqHSWs0y5ZT6YuxX7LNY83ry4hSmWa5PSztomunI8RztOs3zm70hh1d V+rLTpVQXJMlWLyjetN6P5xaxCSgvF8FCwfvLZ72DH/5bkz0C33D0P3f5ZYAXsMqYUj4 EmTg== X-Received: by 10.68.225.228 with SMTP id rn4mr4461571pbc.25.1438422219423; Sat, 01 Aug 2015 02:43:39 -0700 (PDT) Received: from chrisp-dl.ws.atlnz.lc (2-163-36-202-static.alliedtelesis.co.nz. [202.36.163.2]) by smtp.gmail.com with ESMTPSA id bg2sm1513675pbb.20.2015.08.01.02.43.32 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 01 Aug 2015 02:43:38 -0700 (PDT) From: Chris Packham To: u-boot@lists.denx.de Date: Sat, 1 Aug 2015 21:43:22 +1200 Message-Id: <1438422202-4198-1-git-send-email-judge.packham@gmail.com> X-Mailer: git-send-email 2.5.0.rc0 In-Reply-To: References: X-Mailman-Approved-At: Sat, 01 Aug 2015 15:08:19 +0200 Cc: Marek Vasut , Tom Rini , Stefan Roese , Vagrant Cascadian , Chris Packham , lunar@debian.org, Roger Meier , "Albert ARIBAUD \(3ADEV\)" , Holger Levsen , reproducible-builds@lists.alioth.debian.org Subject: [U-Boot] [PATCH v2] Makefile: Use correct timezone for U_BOOT_TZ X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.15 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" When building with SOURCE_DATE_EPOCH the timezone is in UTC. When building normally the timezone is taken from the build machine's locale setting. Signed-off-by: Chris Packham Tested-by: Bin Meng Tested-by: Paul Kocialkowski --- Changes in v2: - Collect some tested-by tags - Remove reference to f3f431a71272 in the commit message - Drop Ccs that were erroneously added when submitting v1, remaining Ccs are from the original mailing list thread Makefile | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 394ed09..f75c730 100644 --- a/Makefile +++ b/Makefile @@ -1230,10 +1230,16 @@ define filechk_version.h endef define filechk_timestamp.h - (SOURCE_DATE="$${SOURCE_DATE_EPOCH:+@$$SOURCE_DATE_EPOCH}"; \ - LC_ALL=C date -u -d "$${SOURCE_DATE:-now}" +'#define U_BOOT_DATE "%b %d %C%y"'; \ - LC_ALL=C date -u -d "$${SOURCE_DATE:-now}" +'#define U_BOOT_TIME "%T"'; \ - LC_ALL=C date -u -d "$${SOURCE_DATE:-now}" +'#define U_BOOT_TZ "%z"' ) + (if test -n "$${SOURCE_DATE_EPOCH}"; then \ + SOURCE_DATE="@$${SOURCE_DATE_EPOCH}"; \ + LC_ALL=C date -u -d "$${SOURCE_DATE}" +'#define U_BOOT_DATE "%b %d %C%y"'; \ + LC_ALL=C date -u -d "$${SOURCE_DATE}" +'#define U_BOOT_TIME "%T"'; \ + LC_ALL=C date -u -d "$${SOURCE_DATE}" +'#define U_BOOT_TZ "%z"'; \ + else \ + LC_ALL=C date +'#define U_BOOT_DATE "%b %d %C%y"'; \ + LC_ALL=C date +'#define U_BOOT_TIME "%T"'; \ + LC_ALL=C date +'#define U_BOOT_TZ "%z"'; \ + fi) endef $(version_h): include/config/uboot.release FORCE