File faac.spec of Package faac
#
# spec file for package faac
#
# Copyright (c) 2025 SUSE LLC
#
# 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/
#
Name: faac
Version: 1.31.1
Release: 0
Summary: An MPEG2/4 AAC encoder
License: LGPL-2.1-or-later AND SUSE-Freeware
Group: Productivity/Multimedia/Video/Editors and Convertors
URL: http://www.audiocoding.com/
Source0: %{name}-%{version}.tar.xz
BuildRequires: automake
BuildRequires: gcc-c++
BuildRequires: libtool
%define soname 0
%define libname lib%{name}%{soname}
%define description_text FAAC is an Advanced Audio Coder (MPEG2-AAC, MPEG4-AAC). The goal of FAAC is to explore the possibilities of AAC and exceed the quality of the currently best MP3 encoders.
%description
%{description_text}
%package -n %{libname}
Summary: Shared library for %{name}
Group: System/Libraries
%description -n %{libname}
%{description_text}
This package provides shared libraries for %{name}.
%package -n lib%{name}-devel
Summary: Development files for lib%{name}
Group: Development/Libraries/C and C++
Requires: %{libname} = %{version}
%description -n lib%{name}-devel
%{description_text}
The %{libname}-devel package contains libraries and header files for developing applications that use %{libname}.
%package doc
Summary: Documentation for %{name}
Group: Documentation/Man
BuildArch: noarch
Requires: %{name} = %{version}
%description doc
%{description_text}
This package contains the documentation for %{name}.
%prep
%setup -q
%build
autoreconf -if
%configure --enable-silent-rules --enable-shared --disable-static
%make_build
%{__strip} -s frontend/.libs/%{name}
%{__strip} -s lib%{name}/.libs/lib%{name}*.so.0.0.0
%install
%make_install
%{__mkdir_p} %{buildroot}%{_defaultdocdir}/%{name}
%{__mkdir_p} %{buildroot}%{_defaultlicensedir}/%{name}
%{__install} -m 0644 -p -t %{buildroot}%{_defaultdocdir}/%{name} AUTHORS ChangeLog NEWS README TODO
%{__install} -m 0644 -p -t %{buildroot}%{_defaultlicensedir}/%{name} COPYING
%{__cp} -a docs %{buildroot}%{_defaultdocdir}/%{name}/
%{__rm} %{buildroot}%{_defaultdocdir}/%{name}/docs/%{name}.1
find %{buildroot} -name '*.la' -exec %{__rm} -f {} ';'
%check
%make_build check
%post -n %{libname}
/sbin/ldconfig
%postun -n %{libname}
/sbin/ldconfig
%files
%defattr(-,root,root,-)
%{_bindir}/%{name}
%{_mandir}/man1/%{name}.1%{ext_man}
%files -n %{libname}
%defattr(-,root,root)
%{_libdir}/*.so.*
%files -n lib%{name}-devel
%defattr(-,root,root,-)
%{_includedir}/*.h
%{_libdir}/*.so
%{_libdir}/pkgconfig/%{name}.pc
%files doc
%defattr(-,root,root,-)
%{_defaultdocdir}/%{name}/
%{_defaultlicensedir}/%{name}/
%changelog