INHERIT += "check-version-mismatch"
# we need ps command to clean stale processes
HOSTTOOLS += "ps"

# Special cases that need to be handled.
# % has the same meaning as in bbappend files, that is, match any chars.

# oe-core
CHECK_VERSION_PV:pn-rust-llvm = "${LLVM_RELEASE}"
CHECK_VERSION_PV:pn-igt-gpu-tools = "${PV}-${PV}"
CHECK_VERSION_PV:pn-vim = "${@'.'.join(d.getVar('PV').split('.')[:-1])}"
CHECK_VERSION_PV:pn-vim-tiny = "${@'.'.join(d.getVar('PV').split('.')[:-1])}"
CHECK_VERSION_PV:pn-ncurses = "${PV}.%"
CHECK_VERSION_PV:pn-alsa-tools = "%"
CHECK_VERSION_PV:pn-gst-examples = "%"
CHECK_VERSION_PV:pn-piglit = "%"
CHECK_VERSION_PV:pn-kernel-devsrc = "%"
CHECK_VERSION_PV:pn-qemuwrapper-cross = "%"
CHECK_VERSION_PV:pn-gnu-config = "%"
CHECK_VERSION_PV:pn-sysvinit-inittab = "%"
CHECK_VERSION_PV:pn-opkg-utils = "%"
CHECK_VERSION_PV:pn-libedit = "${@d.getVar('PV').split('-')[1]}"
CHECK_VERSION_PV:pn-glslang = "%"

# meta-oe
CHECK_VERSION_PV:pn-iozone3 = "3.${PV}"
CHECK_VERSION_PV:pn-can-utils = "%"
CHECK_VERSION_PV:pn-luajit = "${PV}.%"
CHECK_VERSION_PV:pn-sg3-utils = "%"
CHECK_VERSION_PV:pn-netperf = "2.7.%"
CHECK_VERSION_PV:pn-bridge-utils = "1.7%"
CHECK_VERSION_PV:pn-turbostat = "2024.07.26"
CHECK_VERSION_PV:pn-bpftool = "%"
CHECK_VERSION_PV:pn-libhugetlbfs = "%"
CHECK_VERSION_PV:pn-pps-tools = '%'
CHECK_VERSION_PV:pn-libusb-compat = "0.1.12"
CHECK_VERSION_PV:pn-jemalloc = "${@d.getVar('PV').split('+')[0]}%"
CHECK_VERSION_PV:pn-dialog = "${@d.getVar('PV').split('-')[0]}%"
CHECK_VERSION_PV:pn-flite = '%'
CHECK_VERSION_PV:pn-bpftrace = '${PV}%'
