[tools, cmake] refactor: update/hash check scripts, use tags for some more deps, proper CPMUtil separation #2666

Merged
crueter merged 19 commits from update-fmt into master 2025-10-05 03:04:54 +02:00
Showing only changes of commit f436529499 - Show all commits

View file

@ -13,6 +13,9 @@
# shellcheck disable=SC1091
. tools/cpm/common.sh
filter() {
TAGS=$(echo "$TAGS" | jq "[.[] | select(.name | test(\"$1\"; \"i\") | not)]") # vulkan
}
for PACKAGE in "$@"
do
export PACKAGE
@ -36,16 +39,17 @@ do
# filter out some commonly known annoyances
# TODO add more
TAGS=$(echo "$TAGS" | jq '[.[] | select(.name | test("vulkan-sdk"; "i") | not)]') # vulkan
TAGS=$(echo "$TAGS" | jq '[.[] | select(.name | test("yotta"; "i") | not)]') # mbedtls
# ignore betas/alphas
TAGS=$(echo "$TAGS" | jq '[.[] | select(.name | test("alpha"; "i") | not)]')
TAGS=$(echo "$TAGS" | jq '[.[] | select(.name | test("beta"; "i") | not)]')
TAGS=$(echo "$TAGS" | jq '[.[] | select(.name | test("rc"; "i") | not)]')
filter vulkan-sdk # vulkan
filter yotta # mbedtls
# ignore betas/alphas (remove if needed)
filter alpha
filter beta
filter rc
# Add package-specific overrides here, e.g. here for fmt:
[ "$PACKAGE" = fmt ] && TAGS=$(echo "$TAGS" | jq '[.[] | select(.name | test("v0.11"; "i") | not)]')
[ "$PACKAGE" = fmt ] && filter v0.11
LATEST=$(echo "$TAGS" | jq -r '.[0].name')