From 99c05b60fff28849dff99be7c8d89cae9abcc996 Mon Sep 17 00:00:00 2001 From: Robin Jarry Date: Fri, 21 Mar 2025 17:08:03 +0100 Subject: [PATCH] rpm: fix errors on recent fedora Fix the following errors when building on fedora 41: > error: line 23: Dependency tokens must begin with alphanumeric, '_' > or '/': BuildRequires: %toolset > error: line 5: %package debuginfo: package grout-debuginfo already > exists Signed-off-by: Robin Jarry --- rpm/grout.spec | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/rpm/grout.spec b/rpm/grout.spec index 6f79d2c0..c11f0cd0 100644 --- a/rpm/grout.spec +++ b/rpm/grout.spec @@ -4,8 +4,8 @@ %global _lto_cflags %nil %global branch main %global __meson_wrap_mode default -%if "%toolset" != "" -%global __meson /usr/bin/scl run %toolset -- /usr/bin/meson +%if %{defined toolset} +%global __meson /usr/bin/scl run %{toolset} -- /usr/bin/meson %endif Name: grout @@ -17,11 +17,11 @@ Version: %{version} Release: %{release} Source0: https://github.com/DPDK/grout/archive/%{branch}.tar.gz#/%{name}-%{version}-%{release}.tar.gz -%if "%toolset" == "" -BuildRequires: gcc >= 13 -%else -BuildRequires: %toolset +%if %{defined toolset} +BuildRequires: %{toolset} BuildRequires: scl-utils +%else +BuildRequires: gcc >= 13 %endif BuildRequires: git BuildRequires: libarchive-devel @@ -54,7 +54,9 @@ It comes with a client library to configure it over a standard UNIX socket and a CLI that uses that library. The CLI can be used as an interactive shell, but also in scripts one command at a time, or by batches. +%if %{undefined _enable_debug_packages} %debug_package +%endif %package devel Summary: Development headers for building %{name} API clients