openwrt/include
Josef Schlehofer f1e1daa6e8 u-boot.mk: add LOCALVERSION (explicitly specify OpenWrt build)
For debugging purposes, we need to know if users are using modified
U-boot versions or not. Currently, the U-boot version is somehow
stripped. This is a little bit problematic when there are
backported/wip/to-upstream patches.

To make it more confusing, there was (before this commit) two U-boot
versioning. U-boot compiled by OpenWrt build bots are missing ``Build:``
This is also the case when the U-boot is compiled locally.

Example:
```
U-Boot SPL 2022.01 (Jan 27 2022 - 00:24:34 +0000)
U-Boot 2022.01 (Jan 27 2022 - 00:24:34 +0000)
```

On the other hand, if you run full build, you can at least see, where it
was compiled. Notice added ``Build:``.

Example:
```
U-Boot 2022.01 (Jan 27 2022 - 00:24:34 +0000), Build: jenkins-turris-os-packages-burstlab-omnia-216
```

In both cases, it is not clear to U-boot developers if it is an unmodified
build. This is also caused that there is a missing ``.git`` file from
U-boot folder, and so there is no history. It leads to that it can not
contain suffix ``-dirty`` (uncommitted modifications) or even something
else like number of commits, etc. [1]

When U-boot is compiled as it should be, the version should look like
this: ``U-Boot 2022.04-rc1-01173-g278195ea1f (Feb 11 2022 - 14:46:50 +0100)``
The date is not changed daily when there are new OpenWrt builds.

This commit adds OpenWrt specific version, which could be verified by
using strings.

```
$ strings bin/targets/mvebu/cortexa9/u-boot-omnia/u-boot-spl.kwb | grep -E "OpenWrt*"
U-Boot SPL 2022.01-OpenWrt-r18942+54-cbfce92367 (Feb 21 2022 - 13:17:34 +0000)
arm-openwrt-linux-muslgnueabi-gcc (OpenWrt GCC 11.2.0 r18942+54-cbfce92367) 11.2.0
2022.01-OpenWrt-r18942+54-cbfce92367
U-Boot 2022.01-OpenWrt-r18942+54-cbfce92367 (Feb 21 2022 - 13:17:34 +0000)
```

[1] https://u-boot.readthedocs.io/en/latest/develop/version.html

Reported-by: Pali Rohár <pali@kernel.org>
Suggested-by: Karel Kočí <karel.koci@nic.cz>
[rebased for OpenWrt 21.02]
Signed-off-by: Josef Schlehofer <pepe.schlehofer@gmail.com>
(cherry picked from commit d6aa9d9e07)
2022-03-06 20:56:23 +01:00
..
site Revert faulty tree push 2019-08-12 12:27:06 +02:00
autotools.mk build: add support for patching libtool to include ABI version in soname 2021-02-15 18:47:19 +01:00
cmake.mk Revert "build: replace which with Bash command built-in" 2021-03-03 23:02:30 +01:00
debug.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
depends.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
device_table.txt image: ensure that /dev/console exist in rootfs images 2013-08-27 12:02:58 +00:00
download.mk treewide: unify OpenWrt hosted source via @OPENWRT 2021-02-05 12:00:24 -10:00
feeds.mk build: ensure that dash isn't prepended twice to abi version suffix 2021-07-11 16:09:30 +02:00
hardened-ld-pie.specs build: add hardened builds with PIE (ASLR) support 2018-01-27 16:46:45 +01:00
hardening.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
host-build.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
image-commands.mk build: kernel2minor: work around path length limit 2021-05-30 22:32:50 +02:00
image.mk build/json: fix IMAGE_PREFIX and DEVICE_PACKAGES 2021-06-02 22:55:52 +02:00
kernel-build.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
kernel-defaults.mk kernel-defaults: fix external kernel build when user_headers is missing 2021-05-23 16:10:59 +02:00
kernel-version.mk kernel: bump 5.4 to 5.4.182 2022-03-06 20:55:26 +01:00
kernel.mk build: use -nostdinc and -isystem in NOSTDINC_FLAGS for out-of-tree kernel modules 2021-04-04 11:39:51 +02:00
logo.png include: update logo with better kerning 2021-01-18 09:31:39 -10:00
logo.svg include: update logo with better kerning 2021-01-18 09:31:39 -10:00
netfilter.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
nls.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
package-bin.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
package-defaults.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
package-dumpinfo.mk build: drop ABI version from metadata 2021-02-14 19:41:52 +01:00
package-ipkg.mk build: prepend ABI suffixes with a dash if package name ends with digit 2021-07-11 16:09:30 +02:00
package-seccomp.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
package.mk build: filter out own packages on package version check 2021-02-15 21:10:48 +01:00
prereq-build.mk build: prereq detect Python 3.10 for `python3` binary 2021-10-12 19:19:30 -10:00
prereq.mk Revert "build: replace which with Bash command built-in" 2021-03-03 23:02:30 +01:00
quilt.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
rootfs.mk build: reduce cleanup binary calls in rootfs.mk 2020-12-05 22:07:00 -10:00
scan.awk build: propagate override information to .packageinfo 2015-02-09 12:09:31 +00:00
scan.mk build: have scripts/feeds honor all toplevel .mk-files of a feed 2019-10-27 14:32:13 +01:00
shell.sh build: use mkhash to replace various quirky md5sum/openssl calls 2017-01-05 11:09:12 +01:00
subdir.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
target.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
toolchain-build.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
toplevel.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
trusted-firmware-a.mk trusted-firmware-a: fix project name spelling 2021-02-13 20:11:57 +00:00
u-boot.mk u-boot.mk: add LOCALVERSION (explicitly specify OpenWrt build) 2022-03-06 20:56:23 +01:00
uclibc++.mk libcxx[abi]: remove 2020-12-07 10:46:43 -10:00
unpack.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
verbose.mk build: use SPDX license tags 2021-02-05 14:54:47 +01:00
version.mk OpenWrt v21.02.2: revert to branch defaults 2022-02-17 19:00:44 +01:00