# We do build some executables, but we don't package them, so no debuginfo %global debug_package %{nil} Name: rang License: Unlicense Summary: Minimal, header-only, Modern C++ library for terminal goodies Version: 3.2 Release: 2%{?dist} URL: https://agauniyal.github.io/rang/ Source0: https://github.com/agauniyal/rang/archive/v%{version}/rang-v%{version}.tar.gz # Fix tests failing to build Patch0: 0000-rang-fix-tests.patch %global with_tests 1 BuildRequires: cmake BuildRequires: gcc-c++ BuildRequires: make %if 0%{?with_tests} BuildRequires: cmake(doctest) %endif %global desc %{expand:rang is a minimal, single-header library for colors in your terminal. rang only depends on C++ standard library, "unistd.h" system header on Unix and "windows.h" & "io.h" system headers on Windows-based systems. In other words, you don't need any 3rd party dependencies. } %description %{desc} %package devel Summary: %{summary} %description devel This package contains development files for programs using the "rang" library. %{desc} %prep %autosetup -p1 %build %cmake %if 0%{?with_tests} pushd test %cmake %cmake_build %endif %install %cmake_install %if 0%{?with_tests} %check pushd test/%{__cmake_builddir} ./all_rang_tests %endif %files devel %license LICENSE %doc README.md %{_includedir}/%{name}.hpp %{_libdir}/cmake/%{name}/ %{_libdir}/pkgconfig/%{name}.pc %changelog * Tue May 09 2023 Artur Frenszek-Iwicki - 3.2-2 - Fix BuildRequires * Thu May 04 2023 Artur Frenszek-Iwicki - 3.2-1 - Initial packaging