File tree Expand file tree Collapse file tree 4 files changed +25
-7
lines changed Expand file tree Collapse file tree 4 files changed +25
-7
lines changed Original file line number Diff line number Diff line change 88env :
99 TMPDIR : /tmp
1010 CI_MAX_KERNEL_VERSION : ' 6.16'
11- CI_MAX_EFW_VERSION : ' 0.21.0 '
11+ CI_MAX_EFW_VERSION : ' 1.0.0-rc1 '
1212 CI_MIN_CLANG_VERSION : ' 13'
1313 go_version : ' ~1.25'
1414 prev_go_version : ' ~1.24'
Original file line number Diff line number Diff line change @@ -120,8 +120,6 @@ testdata/loader-%-eb.elf: testdata/loader.c
120120 $(STRIP ) -g $@
121121
122122.PHONY : update-external-deps
123- update-external-deps : export KERNEL_VERSION=6.16.0
124- update-external-deps : export EFW_VERSION=v1.0.0-rc1
125123update-external-deps :
126124 ./scripts/update-kernel-deps.sh
127125 ./scripts/update-efw-deps.sh
Original file line number Diff line number Diff line change 22
33set -euo pipefail
44
5+ # Extract EFW version from CI workflow file
6+ efw_version=$( awk -F' : ' ' /CI_MAX_EFW_VERSION:/ {gsub(/[' \' ' "]/, "", $2); print $2}' .github/workflows/ci.yml)
7+
8+ if [ -z " $efw_version " ]; then
9+ echo " Error: Could not extract CI_MAX_EFW_VERSION from .github/workflows/ci.yml" >&2
10+ exit 1
11+ fi
12+
13+ echo " Using EFW version: $efw_version "
14+
515tmp=$( mktemp -d)
616
717cleanup () {
@@ -11,5 +21,5 @@ cleanup() {
1121trap cleanup EXIT
1222
1323# Download and process ebpf_structs.h
14- curl -fL " https://github.com/microsoft/ebpf-for-windows/raw/refs/tags/${EFW_VERSION } /include/ebpf_structs.h" -o " $tmp /ebpf_structs.h"
24+ curl -fL " https://github.com/microsoft/ebpf-for-windows/raw/refs/tags/Release-v ${efw_version } /include/ebpf_structs.h" -o " $tmp /ebpf_structs.h"
1525" ./internal/cmd/genwinfunctions.awk" " $tmp /ebpf_structs.h" | gofmt > " ./asm/func_win.go"
Original file line number Diff line number Diff line change 22
33set -euo pipefail
44
5+ # Extract kernel version from CI workflow file
6+ kernel_version=$( awk -F' : ' ' /CI_MAX_KERNEL_VERSION:/ {gsub(/[' \' ' "]/, "", $2); print $2}' .github/workflows/ci.yml)
7+
8+ if [ -z " $kernel_version " ]; then
9+ echo " Error: Could not extract CI_MAX_KERNEL_VERSION from .github/workflows/ci.yml" >&2
10+ exit 1
11+ fi
12+
13+ echo " Using kernel version: $kernel_version "
14+
515tmp=$( mktemp -d)
616
717cleanup () {
@@ -12,15 +22,15 @@ trap cleanup EXIT
1222
1323# Download and process libbpf.c
1424# Truncate .0 patch versions (e.g., 6.16.0 -> 6.16, but leave 7.0 as 7.0)
15- kernel_version_for_url=" $KERNEL_VERSION "
16- if [[ $KERNEL_VERSION =~ ^([0-9]+\. [0-9]+)\. 0$ ]]; then
25+ kernel_version_for_url=" $kernel_version "
26+ if [[ $kernel_version =~ ^([0-9]+\. [0-9]+)\. 0$ ]]; then
1727 kernel_version_for_url=" ${BASH_REMATCH[1]} "
1828fi
1929curl -fL " https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/plain/tools/lib/bpf/libbpf.c?h=v$kernel_version_for_url " -o " $tmp /libbpf.c"
2030" ./internal/cmd/gensections.awk" " $tmp /libbpf.c" | gofmt > " ./elf_sections.go"
2131
2232# Download and process vmlinux and btf_testmod
23- go tool crane export " ghcr.io/cilium/ci-kernels:$KERNEL_VERSION " | tar -x -C " $tmp "
33+ go tool crane export " ghcr.io/cilium/ci-kernels:$kernel_version " | tar -x -C " $tmp "
2434
2535extract-vmlinux " $tmp /boot/vmlinuz" > " $tmp /vmlinux"
2636
You can’t perform that action at this time.
0 commit comments