From 037840fb6b86d6083d55f3da5ad70d19d34cc5a5 Mon Sep 17 00:00:00 2001 From: Qian Yingjin Date: Wed, 23 Oct 2019 09:43:24 +0800 Subject: [PATCH] LU-12899 build: rhel8 not install kernel-rpm-macros On RHEL8 kmodtool and kernel_module_package_buildreqs are not installed with kernel-devel. kernel_module_package_buildreqs is defined in kernel-rpm-marcos. If kernel-rpm-macros is not installed, the Lustre RPM build will report: "Dependency tokens must begin with alpha-numeric, '_' or '/': BuildRequires: %kernel_module_package_buildreqs" This patch helps the developer understanding the detailed information for the required packages when kernel-rpm-macros is not installed. Signed-off-by: Qian Yingjin Change-Id: Id9b855eeac97d780d9c572d306da3c3a1fa95ea6 Reviewed-on: https://review.whamcloud.com/36557 Tested-by: jenkins Reviewed-by: Shaun Tancheff Reviewed-by: Jian Yu Tested-by: Maloo Reviewed-by: Oleg Drokin --- lustre.spec.in | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/lustre.spec.in b/lustre.spec.in index 380fe87..f23dca2 100644 --- a/lustre.spec.in +++ b/lustre.spec.in @@ -165,13 +165,11 @@ Requires: libselinux %endif %if %{with lustre_modules} -%if 0%{?rhel} >= 8 -%if %{undefined kernel_module_package_buildreqs} +%if 0%{?rhel} >= 8 && %{undefined kernel_module_package_buildreqs} BuildRequires: redhat-rpm-config kernel-rpm-macros elfutils-libelf-devel kmod -%endif -%endif - +%else BuildRequires: %kernel_module_package_buildreqs +%endif %if %{_vendor}=="redhat" BuildRequires: redhat-rpm-config %endif -- 1.8.3.1