Commit Graph

12 Commits

Author SHA1 Message Date
Changqing Li 5baf4b2341 version-check.conf: mute version mismatch warning for dialog
Refer [1], dialog's tarballs released with date, for convenient, PV also
end with date. Change to check without date suffix.

[1] https://invisible-mirror.net/archives/dialog/

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-05-29 21:07:31 -07:00
Changqing Li f0d23b87f7 version-check.conf: mute version mismatch warning for jemalloc
jemalloc set the version by pass --with-version=${PV_LONG}, PV_LONG :=
"${PV}-171-g${SRCREV}", set match pattern for jemalloc to mute the
version mismatch warning

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-05-29 21:07:31 -07:00
Changqing Li 0282e63a84 version-check.conf: mute version mismatch warning for libusb-compat
Refer [1],  upstream set this version specially, so mute by skipp
checking

[1] https://github.com/libusb/libusb-compat-0.1/commit/49057f6ce5cd4d51e31594f290b2dd3c9f1dbaf8

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-05-29 21:07:31 -07:00
Changqing Li 5028e52c4e version-check.conf: mute version mismatch warning for pps-tools
The version get by the version check tool is wrong, the output
include version of grep. Skip checking to mute the warning

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-05-29 21:07:31 -07:00
Changqing Li 3ce3d3bdb5 version-check.conf: mute version mismatch warning for libhugetlbfs
ld.libhugetlbfs --version return the ld version on the host, and cause
version mismatch warning, mute the warning by skip checking for this
package

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-05-29 21:07:31 -07:00
Changqing Li 96ef6227b8 version-check.conf: mute version mismatch warning for bpftool
bpftool is compiled from kernel source, we hope it has version
aligned with kernel version, but the sources will printout some
other versions,  skip this checking.

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-05-29 21:07:31 -07:00
Chen Qi a232d95455 conf/version-check.conf: skip version check for a few recipes
Now check-version-mismatch.bbclass can check scripts' output
beside elf binaries output. We need to skip a few recipe.
These recipes' scripts give some version information, but they
are version information of scripts themselves instead of the package.
There's no executable in these packages that can give out useful
version information.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-04-19 14:36:05 -07:00
Chen Qi 301a5fd516 conf/version-check.conf: skip piglit
piglit is an open-source test suite for OpenGL implementations. It
contains a whole lot of programs which all do not give out any version
information. Running version check for piglit is a waste of time (~1h),
so setting a '%' to skip it.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-04-19 14:36:04 -07:00
Changqing Li d6c334c526 turbostat: make turbostat's version align with kernel version
* Current PV 3.4 is the kernel version when the recipe is newly added,
set PKGV to KERNEL_VERSION to make it always align with kernel version
* turbostat has its runtime version, set CHECK_VERSION_PV to this version to mute
the version mismatch warning
[snip of turbostat.c]
void print_version()
{
    fprintf(outf, "turbostat version 2024.07.26 - Len Brown <lenb@kernel.org>\n");
}
[snip]

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-04-15 12:52:20 -07:00
Changqing Li a9cf464662 version-check.conf: mute bridge-utils version mismatch warning
Runtime version of brctl is 1.7.1, but the configure.ac set version as
1.7 (AC_INIT([bridge-utils],[1.7])). And refer [1], this utility is
DEPRECATED, only critical bug fixes only, so it is nearly not possible
to correct from upstream, so mute this warning since it has no critical
influence.

[1] https://git.kernel.org/pub/scm/network/bridge/bridge-utils.git/commit/?h=main&id=ab8a2cc330253321be7bc69dea88bfaa3d48415e

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-04-15 12:52:19 -07:00
Changqing Li e3b7463fc1 version-check.conf: add CHECK_VERSION_PV for pn-netperf
For netperf, current PV is 2.7.0+git, and the SRCREV is newer than 2.7.0,
and there is no tag 2.7.1, the latest tag is in 2015, refer [1], so it
is not possile for us to make PV align with the runtime version below
by update SRCREV now, add CHECK_VERSION_PV for pn-netperf to mute the
version mismatch waring

$netserver -V
Netperf version 2.7.1

[1] https://github.com/HewlettPackard/netperf

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-04-15 12:52:19 -07:00
Chen Qi 14ff80c9dc version-check.conf: add mechanism for checking version mismatch
Add a mechanism to check mismatch between runtime version and build time version.

To use, add the following line to local.conf:

  include conf/version-check.conf

Ideally, layers will have their own conf/version-check.conf to establish
some baseline, so that any future warning indicates some error. In such
case, users can use include_all:

  include_all conf/version-check.conf

The basic idea is to use qemu to run executables at build time, extract
possible versions, and check if there's a mismatch found.

Python meta data and .pc files are also checked for quick match. This
is because such info are also easy to be checked by users.

check-version-mismatch.bbclass is the class that does the actual work.
A new variable, CHECK_VERSION_PV, is introduced. It defaults to ${PKGV},
but also allows override. This allows us to handle special cases in each
layer.

version-check.conf is the configuration file that makes this functionality
easier to use and draws some baseline. It contains some override settings
for some recipes. With these overrides, all recipes in oe-core are handled
well. All warnings are valid warnings.

Note that 'ps' is added to HOSTTOOLS in version-check.conf. This is because
we need 'ps' to find stale processes and then clean them.

The warnings are like below:

  WARNING: time-1.9-r0 do_package_check_version_mismatch: Possible runtime versions ['UNKNOWN'] do not match recipe version 1.9
  WARNING: python3-unittest-automake-output-0.2-r0 do_package_check_version_mismatch: Possible runtime versions ['0.1'] do not match recipe version 0.2
  WARNING: pinentry-1.3.1-r0 do_package_check_version_mismatch: Possible runtime versions ['1.3.1-unknown'] do not match recipe version 1.3.1
  ...

There will be a data directory containing all details: tmp/check-version-mismatch.
This directory contains detailed data for each recipe that is built.
If users don't want it, they can set DEBUG_VERSION_MISMATCH_CHECK to 0.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-04-04 19:18:46 -07:00