File cava.spec of Package cava
#
# spec file for package cava
#
# Copyright (c) 2025 SUSE LLC and contributors
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define sover 0
%define libcavacore libcavacore%{sover}
Name: cava
Version: 0.10.6+meson
Release: 0
Summary: Cross-platform Audio Visualizer
License: MIT
URL: https://github.com/karlstav/cava
Source: %{name}-%{version}.tar.zst
BuildRequires: c++_compiler
BuildRequires: meson
BuildRequires: pkgconfig
BuildRequires: pulseaudio-utils
BuildRequires: pkgconfig(alsa)
BuildRequires: pkgconfig(fftw3)
BuildRequires: pkgconfig(gl)
BuildRequires: pkgconfig(iniparser) >= 4.0
BuildRequires: pkgconfig(jack)
BuildRequires: pkgconfig(libpipewire-0.3)
BuildRequires: pkgconfig(libpulse-simple)
BuildRequires: pkgconfig(ncursesw)
BuildRequires: pkgconfig(sdl2)
BuildRequires: pkgconfig(sndio)
# Installing the psf in a directory that comes from kbd
Requires: kbd
BuildSystem: meson
# openSUSE builds with LTO.
# b_lto=true is necessary to enable workaround for INCBIN, which
# requires an include path to be passed to the assembler when
# compiling out-of-tree.
BuildOption: -Db_lto=true
BuildOption: -Dfont_dir="%{_datadir}/kbd/consolefonts"
BuildOption: -Doss=disabled
BuildOption: -Dportaudio=disabled
%description
CAVA is a cross-platform audio visualizer.
This version supports capturing audio from Pipewire, Pulseaudio,
ALSA and named pipes/FIFOs. It can render its visuals to a
terminal, Noritake VFDs, or as windowed SDL application.
%package devel
Summary: Development files for %{name}
Requires: %{libcavacore} = %{version}
Provides: cavacore-devel
%description devel
Development files and library for CAVA.
%package -n %{libcavacore}
Summary: CAVA audio visualizer library
%description -n %{libcavacore}
This package provides CAVA's core functionality as a library.
%prep -a
rm example_files/*.{gif,jpg}
%ldconfig_scriptlets -n %{libcavacore}
%files
%license LICENSE
%doc README.md SHADERS.md TERMINAL.md example_files
%{_bindir}/cava
%dir %{_datadir}/kbd/
%dir %{_datadir}/kbd/consolefonts/
%{_datadir}/kbd/consolefonts/cava.psf
%files devel
%doc CAVACORE.md cavacore_test.c
%{_includedir}/cava
%{_libdir}/libcavacore.so
%{_libdir}/pkgconfig/cava.pc
%files -n %{libcavacore}
%{_libdir}/libcavacore.so.*
%changelog