From 4ff6a0587fa733ef6ebf131c095226a606c09420 Mon Sep 17 00:00:00 2001 From: James Hilliard Date: Fri, 1 Apr 2022 21:49:33 -0600 Subject: [PATCH] package/linux-headers: error if headers version is not set Validate that BR2_DEFAULT_KERNEL_VERSION is set when required. Fixes: http://autobuild.buildroot.net/results/2b9/2b91cb82a290348843a2422c01b10e49f45be9ca Signed-off-by: James Hilliard [Arnout: add BR_BUILDING condition] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) --- package/linux-headers/linux-headers.mk | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/package/linux-headers/linux-headers.mk b/package/linux-headers/linux-headers.mk index 1102e76f0f..e2a0b7a7c9 100644 --- a/package/linux-headers/linux-headers.mk +++ b/package/linux-headers/linux-headers.mk @@ -33,6 +33,12 @@ LINUX_HEADERS_REPO_URL = $(call qstrip,$(BR2_KERNEL_HEADERS_CUSTOM_REPO_URL)) LINUX_HEADERS_CIP = endif # BR2_KERNEL_HEADERS_AS_KERNEL +ifeq ($(BR2_KERNEL_HEADERS_VERSION)$(BR_BUILDING),yy) +ifeq ($(LINUX_HEADERS_VERSION),) +$(error No kernel headers version set, check your BR2_DEFAULT_KERNEL_VERSION setting) +endif +endif + # Compute LINUX_HEADERS_SOURCE and LINUX_HEADERS_SITE from the configuration ifeq ($(LINUX_HEADERS_CUSTOM_TARBALL),y) ifeq ($(BR_BUILDING),y)