File mingw64-libsndfile.spec of Package mingw64-libsndfile

#
# spec file for package mingw64-libsndfile
#
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# 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 http://bugs.opensuse.org/
#

Name:           mingw64-libsndfile
Summary:        A Library to Handle Various Audio File Formats
Version:        1.2.2
Release:        0
Summary:        Development/Libraries/C and C++
License:        LGPL-2.1-or-later
Group:          System/Libraries
URL:            https://libsndfile.github.io/libsndfile/
Source0:        https://github.com/libsndfile/libsndfile/releases/download/%{version}/libsndfile-%{version}.tar.xz
Source1:        https://github.com/libsndfile/libsndfile/releases/download/%{version}/libsndfile-%{version}.tar.xz.asc
Patch1:         libsndfile-CVE-2022-33065.patch
Patch2:         libsndfile-CVE-2024-50612.patch
BuildRequires:  mingw64-cross-gcc-c++
BuildRequires:  mingw64-cross-cmake
BuildRequires:  mingw64-cross-pkg-config
BuildRequires:  mingw64-flac-devel
BuildRequires:  mingw64-libvorbis-devel
BuildRequires:  mingw64-opus-devel
BuildRequires:  mingw64-sqlite-devel
BuildRequires:  mingw64-libspeex-devel
BuildRequires:  mingw64-mpg123-devel
BuildRequires:  python3-base
%_mingw64_package_header_debug
BuildArch:      noarch

%description
Libsndfile is a C library for reading and writing sound files, such as
AIFF, AU, and WAV files, through one standard interface.  It can
currently read and write 8, 16, 24, and 32-bit PCM files as well as
32-bit floating point WAV files and a number of compressed formats.

%package -n mingw64-libsndfile1
Summary:        A Library to Handle Various Audio File Formats
Group:          System/Libraries

%description -n mingw64-libsndfile1
Libsndfile is a C library for reading and writing sound files, such as
AIFF, AU, and WAV files, through one standard interface.  It can
currently read and write 8, 16, 24, and 32-bit PCM files as well as
32-bit floating point WAV files and a number of compressed formats.

%package devel
Summary:        Development package for the libsndfile library
Group:          Development/Libraries/C and C++

%description devel
This package contains the files needed to compile programs that use libsndfile.

%package tools
Summary:        Example Programs for libsndfile
Group:          System/Libraries

%description tools
This package includes the example programs for libsndfile.

%_mingw64_debug_package

%prep
%autosetup -p1 -n libsndfile-%{version}

%build
%{_mingw64_cmake} \
  -DENABLE_EXPERIMENTAL=ON \
  -DBUILD_EXAMPLES=OFF \
  -DCMAKE_INSTALL_DOCDIR=%{_defaultdocdir}/libsndfile
%{_mingw64_cmake_build}

%install
%{_mingw64_cmake_install}

%files -n mingw64-libsndfile1
%{_mingw64_bindir}/libsndfile.dll

%files devel
%{_defaultdocdir}/libsndfile
%{_mingw64_libdir}/libsndfile*.dll.a
%{_mingw64_includedir}/*
%{_mingw64_libdir}/pkgconfig/*.pc
%{_mingw64_libdir}/cmake/SndFile/

%files tools
%{_mingw64_bindir}/*.exe
%{_mingw64_mandir}/man?/*

%changelog
openSUSE Build Service is sponsored by