Blob Blame History Raw
Support building with pahole >= 1.24, see
Stefan Roesch's post here https://devkernel.io/posts/pahole-error/
--- a/scripts/link-vmlinux.sh
+++ b/scripts/link-vmlinux.sh
@@ -240,6 +240,11 @@ gen_btf()
 	if [ "${pahole_ver}" -ge "121" ]; then
 		extra_paholeopt="${extra_paholeopt} --btf_gen_floats"
 	fi
+	if [ "${pahole_ver}" -ge "124" ]; then
+		# pahole 1.24 and above generate BTF_KIND_ENUM64 which is
+		# not supported by this kernel
+		extra_paholeopt="${extra_paholeopt} --skip_encoding_btf_enum64"
+	fi
 
 	info "BTF" ${2}
 	LLVM_OBJCOPY="${OBJCOPY}" ${PAHOLE} -J ${extra_paholeopt} ${1}