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 Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 27221C433EF for ; Thu, 10 Feb 2022 13:42:36 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id C9B9D802D6; Thu, 10 Feb 2022 14:42:34 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=debian.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 3F77D810F3; Thu, 10 Feb 2022 14:21:07 +0100 (CET) Received: from smtp5-g21.free.fr (smtp5-g21.free.fr [212.27.42.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 3963880F94 for ; Thu, 10 Feb 2022 14:21:04 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=debian.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=nicolas.boulenguez@free.fr Received: from nicolasthinkpad.home (unknown [88.164.111.166]) by smtp5-g21.free.fr (Postfix) with ESMTPS id D57AF5FFA0 for ; Thu, 10 Feb 2022 14:21:03 +0100 (CET) Received: from nicolas by nicolasthinkpad.home with local (Exim 4.94.2) (envelope-from ) id 1nI768-0003gG-F0 for u-boot@lists.denx.de; Thu, 10 Feb 2022 11:54:48 +0100 Date: Thu, 10 Feb 2022 11:54:48 +0100 From: Nicolas Boulenguez To: u-boot@lists.denx.de Subject: [PATCH] build: allow a downstream suffix in the version shown during boot Message-ID: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="HSGpHC7C8WCJUTW9" Content-Disposition: inline X-Mailman-Approved-At: Thu, 10 Feb 2022 14:42:34 +0100 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.5 at phobos.denx.de X-Virus-Status: Clean --HSGpHC7C8WCJUTW9 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hello. The attached patch has been applied for a while by Debian, but would most probably be useful to other downstreams. It is trivial and does not change the default settings. Please consider merging it upstream. Thanks. --HSGpHC7C8WCJUTW9 Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="0001-build-allow-a-downstream-suffix-in-the-version-shown.patch" >From 5a08cdc84ade21b947f1de8aa95e3bbd273c4bcd Mon Sep 17 00:00:00 2001 From: Nicolas Boulenguez Date: Thu, 10 Feb 2022 11:15:38 +0100 Subject: [PATCH] build: allow a downstream suffix in the version shown during boot It is convenient for redistributors to add a build number to the U-boot source version, which is displayed at boot and useful to know if a device has been successfully updated, to triage bugs and so on. For example, Debian adds '+dfsg-N' where N changes with each release of a .deb package. Author: Vagrant Cascadian Author: Nicolas Boulenguez Signed-By: Nicolas Boulenguez --- Makefile | 2 +- doc/build/gcc.rst | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index a30098c66f..d6e9cdbf04 100644 --- a/Makefile +++ b/Makefile @@ -456,7 +456,7 @@ KBUILD_AFLAGS += $(call cc-option,-fno-PIE) # Read UBOOTRELEASE from include/config/uboot.release (if it exists) UBOOTRELEASE = $(shell cat include/config/uboot.release 2> /dev/null) -UBOOTVERSION = $(VERSION)$(if $(PATCHLEVEL),.$(PATCHLEVEL)$(if $(SUBLEVEL),.$(SUBLEVEL)))$(EXTRAVERSION) +UBOOTVERSION = $(VERSION)$(if $(PATCHLEVEL),.$(PATCHLEVEL)$(if $(SUBLEVEL),.$(SUBLEVEL)))$(EXTRAVERSION)$(BUILD_VERSION) export VERSION PATCHLEVEL SUBLEVEL UBOOTRELEASE UBOOTVERSION export ARCH CPU BOARD VENDOR SOC CPUDIR BOARDDIR diff --git a/doc/build/gcc.rst b/doc/build/gcc.rst index cdd7970032..d8666acaae 100644 --- a/doc/build/gcc.rst +++ b/doc/build/gcc.rst @@ -141,6 +141,11 @@ of dtc is new enough. It also makes sure that pylibfdt is present, if needed Note that the :doc:`tools` are always built with the included version of libfdt so it is not possible to build U-Boot tools with a system libfdt, at present. +If you are modifying the upstream sources, please make this visible +at boot time by defining the BUILD_VERSION version suffix. + +* BUILD_VERSION=+<...> + Other build targets ~~~~~~~~~~~~~~~~~~~ -- 2.30.2 --HSGpHC7C8WCJUTW9--