flac/flac.spec
Ismail Dönmez 4a7d37be96 Accepting request 83524 from home:jengelh:bl-f
- Apply packaging guidelines (remove redundant/obsolete
  tags/sections from specfile, etc.)
- Add flac-devel to baselibs

OBS-URL: https://build.opensuse.org/request/show/83524
OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/flac?expand=0&rev=11
2011-09-19 16:07:42 +00:00

143 lines
3.5 KiB
RPMSpec

#
# spec file for package flac
#
# Copyright (c) 2011 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: flac
BuildRequires: gcc-c++ libogg-devel pkg-config
%ifarch %{ix86}
BuildRequires: nasm
%endif
# bug437293
%ifarch ppc64
Obsoletes: flac-64bit
%endif
#
Summary: Free Lossless Audio Codec
Version: 1.2.1
Release: 83
License: BSD3c(or similar)
Group: Productivity/Multimedia/Sound/Utilities
Source: %{name}-%{version}.tar.bz2
Source2: baselibs.conf
Patch: flac-no-xmms.diff
Patch1: flac-printf-format-fix.diff
Patch2: flac-gcc43-fixes.diff
Patch3: flac-1.2.1-asm.patch
Patch4: flac-1.2.1-bitreader.patch
Url: http://flac.sourceforge.net/
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
FLAC is an open source lossless audio codec developed by Josh Coalson.
%package -n libFLAC8
Summary: Free Lossless Audio Codec Library
License: BSD3c(or similar)
Group: System/Libraries
Obsoletes: libflac <= %{version}
Provides: libflac = %{version}
%description -n libFLAC8
This package contains the library for FLAC (Free Lossless Audio Codec)
developed by Josh Coalson.
%package -n libFLAC++6
Summary: Free Lossless Audio Codec Library
License: BSD3c(or similar)
Group: System/Libraries
%description -n libFLAC++6
This package contains the C++ library for FLAC (Free Lossless Audio
Codec) developed by Josh Coalson.
%package devel
Summary: FLAC Library Development Package
License: BSD3c(or similar)
Group: Development/Libraries/C and C++
Requires: libFLAC8 = %{version} libFLAC++6 = %{version} glibc-devel libstdc++-devel
%description devel
This package contains the files needed to compile programs that use the
FLAC library.
%prep
%setup -q
%patch
%patch1
%patch2
%patch3 -p1
%patch4
%build
autoreconf --force --install
%define warn_flags -W -Wall -Wstrict-prototypes -Wformat-security
export CFLAGS="$RPM_OPT_FLAGS %{warn_flags}"
export CXXFLAGS="$CFLAGS"
%configure --disable-thorough-tests \
--disable-xmms-plugin \
--disable-static \
--disable-rpath \
--with-pic
make %{?_smp_mflags}
%install
%makeinstall
# documents
mkdir -p $RPM_BUILD_ROOT%{_docdir}
mv $RPM_BUILD_ROOT%{_datadir}/doc/%{name}-%{version} $RPM_BUILD_ROOT%{_docdir}/%{name}
cp -a AUTHORS README COPYING.* $RPM_BUILD_ROOT%{_docdir}/%{name}
%check
make check
%post -n libFLAC8
%run_ldconfig
%postun -n libFLAC8
%run_ldconfig
%post -n libFLAC++6
%run_ldconfig
%postun -n libFLAC++6
%run_ldconfig
%files
%defattr(-, root, root)
%doc %{_docdir}/%{name}
%{_bindir}/*
%{_mandir}/man*/*
%files -n libFLAC8
%defattr(-, root, root)
%{_libdir}/libFLAC.so.8*
%files -n libFLAC++6
%defattr(-, root, root)
%{_libdir}/libFLAC++.so.6*
%files devel
%defattr(-, root, root)
%{_libdir}/lib*.so
%{_includedir}/*
%{_libdir}/pkgconfig/*.pc
%{_datadir}/aclocal/*.m4
%exclude %{_libdir}/lib*.la
%changelog