b26bdb
Summary:	Library for reading and writing sound files
b26bdb
Name:		libsndfile
b26bdb
Version:	1.0.25
b26bdb
Release:	10%{?dist}
b26bdb
License:	LGPLv2+ and GPLv2+ and BSD
b26bdb
Group:		System Environment/Libraries
b26bdb
URL:		http://www.mega-nerd.com/libsndfile/
b26bdb
Source0:	http://www.mega-nerd.com/libsndfile/files/libsndfile-%{version}.tar.gz
b26bdb
Patch0:		%{name}-1.0.25-system-gsm.patch
b26bdb
BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
b26bdb
b26bdb
BuildRequires:	alsa-lib-devel
b26bdb
BuildRequires:	flac-devel
b26bdb
BuildRequires:	libogg-devel
b26bdb
BuildRequires:	libvorbis-devel
b26bdb
BuildRequires:	pkgconfig
b26bdb
BuildRequires:	sqlite-devel
b26bdb
BuildRequires:	gsm-devel
b26bdb
BuildRequires:	libtool
b26bdb
b26bdb
b26bdb
%description
b26bdb
libsndfile is a C library for reading and writing sound files such as
b26bdb
AIFF, AU, WAV, and others through one standard interface. It can
b26bdb
currently read/write 8, 16, 24 and 32-bit PCM files as well as 32 and
b26bdb
64-bit floating point WAV files and a number of compressed formats. It
b26bdb
compiles and runs on *nix, MacOS, and Win32.
b26bdb
b26bdb
b26bdb
%package devel
b26bdb
Summary:	Development files for libsndfile
b26bdb
Group:		Development/Libraries
b26bdb
Requires:	%{name}%{?_isa} = %{version}-%{release} pkgconfig
b26bdb
b26bdb
b26bdb
%description devel
b26bdb
libsndfile is a C library for reading and writing sound files such as
b26bdb
AIFF, AU, WAV, and others through one standard interface.
b26bdb
This package contains files needed to develop with libsndfile.
b26bdb
b26bdb
b26bdb
%package utils
b26bdb
Summary:	Command Line Utilities for libsndfile
b26bdb
Group:		Applications/Multimedia
b26bdb
Requires:	%{name} = %{version}-%{release}
b26bdb
Obsoletes:	libsndfile < 1.0.20-4
b26bdb
b26bdb
b26bdb
%description utils
b26bdb
libsndfile is a C library for reading and writing sound files such as
b26bdb
AIFF, AU, WAV, and others through one standard interface.
b26bdb
This package contains command line utilities for libsndfile.
b26bdb
b26bdb
b26bdb
%prep
b26bdb
%setup -q
b26bdb
%patch0 -p1
b26bdb
rm -r src/GSM610 ; autoreconf -I M4 -fiv # for system-gsm patch
b26bdb
#also for aarch64 support which requires autotools 2.69+
b26bdb
b26bdb
b26bdb
%build
b26bdb
%configure \
b26bdb
	--disable-dependency-tracking \
b26bdb
	--enable-sqlite \
b26bdb
	--enable-alsa \
b26bdb
	--enable-largefile \
b26bdb
	--disable-static
b26bdb
b26bdb
# Get rid of rpath
b26bdb
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
b26bdb
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
b26bdb
b26bdb
make %{?_smp_mflags}
b26bdb
b26bdb
b26bdb
%install
b26bdb
rm -rf $RPM_BUILD_ROOT __docs
b26bdb
make install DESTDIR=$RPM_BUILD_ROOT
b26bdb
cp -pR $RPM_BUILD_ROOT%{_docdir}/libsndfile1-dev/html __docs
b26bdb
rm -rf $RPM_BUILD_ROOT%{_docdir}/libsndfile1-dev
b26bdb
b26bdb
# fix multilib issues
b26bdb
%if %{__isa_bits} == 64
b26bdb
%define wordsize 64
b26bdb
%else
b26bdb
%define wordsize 32
b26bdb
%endif
b26bdb
b26bdb
mv %{buildroot}%{_includedir}/sndfile.h \
b26bdb
   %{buildroot}%{_includedir}/sndfile-%{wordsize}.h
b26bdb
b26bdb
cat > %{buildroot}%{_includedir}/sndfile.h <
b26bdb
#include <bits/wordsize.h>
b26bdb
b26bdb
#if __WORDSIZE == 32
b26bdb
# include "sndfile-32.h"
b26bdb
#elif __WORDSIZE == 64
b26bdb
# include "sndfile-64.h"
b26bdb
#else
b26bdb
# error "unexpected value for __WORDSIZE macro"
b26bdb
#endif
b26bdb
EOF
b26bdb
b26bdb
%if 0%{?rhel} != 0
b26bdb
rm -f %{buildroot}%{_bindir}/sndfile-jackplay
b26bdb
%endif
b26bdb
b26bdb
b26bdb
%check
b26bdb
LD_LIBRARY_PATH=$PWD/src/.libs make check
b26bdb
b26bdb
b26bdb
%clean
b26bdb
rm -rf $RPM_BUILD_ROOT
b26bdb
b26bdb
b26bdb
%post -p /sbin/ldconfig
b26bdb
b26bdb
%postun -p /sbin/ldconfig
b26bdb
b26bdb
b26bdb
%files
b26bdb
%defattr(-,root,root,-)
b26bdb
%doc COPYING AUTHORS README NEWS
b26bdb
%{_libdir}/%{name}.so.*
b26bdb
b26bdb
%files utils
b26bdb
%defattr(-,root,root,-)
b26bdb
%{_bindir}/sndfile-cmp
b26bdb
%{_bindir}/sndfile-concat
b26bdb
%{_bindir}/sndfile-convert
b26bdb
%{_bindir}/sndfile-deinterleave
b26bdb
%{_bindir}/sndfile-info
b26bdb
%{_bindir}/sndfile-interleave
b26bdb
%{_bindir}/sndfile-metadata-get
b26bdb
%{_bindir}/sndfile-metadata-set
b26bdb
%{_bindir}/sndfile-play
b26bdb
%{_bindir}/sndfile-regtest
b26bdb
%{_bindir}/sndfile-salvage
b26bdb
%{_mandir}/man1/sndfile-cmp.1*
b26bdb
%{_mandir}/man1/sndfile-concat.1*
b26bdb
%{_mandir}/man1/sndfile-convert.1*
b26bdb
%{_mandir}/man1/sndfile-deinterleave.1*
b26bdb
%{_mandir}/man1/sndfile-info.1*
b26bdb
%{_mandir}/man1/sndfile-interleave.1*
b26bdb
%{_mandir}/man1/sndfile-metadata-get.1*
b26bdb
%{_mandir}/man1/sndfile-metadata-set.1*
b26bdb
%{_mandir}/man1/sndfile-play.1*
b26bdb
b26bdb
%files devel
b26bdb
%defattr(-,root,root,-)
b26bdb
%doc __docs/*
b26bdb
%doc ChangeLog
b26bdb
%exclude %{_libdir}/%{name}.la
b26bdb
%{_includedir}/sndfile.h
b26bdb
%{_includedir}/sndfile.hh
b26bdb
%{_includedir}/sndfile-%{wordsize}.h
b26bdb
%{_libdir}/%{name}.so
b26bdb
%{_libdir}/pkgconfig/sndfile.pc
b26bdb
b26bdb
b26bdb
%changelog
b26bdb
* Sat Aug  2 2014 Peter Robinson <pbrobinson@redhat.com> 1.0.25-10
b26bdb
- Generic 32/64 bit platform detection - fix ppc64le build (#1126140)
b26bdb
b26bdb
* Fri Jan 24 2014 Daniel Mach <dmach@redhat.com> - 1.0.25-9
b26bdb
- Mass rebuild 2014-01-24
b26bdb
b26bdb
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 1.0.25-8
b26bdb
- Mass rebuild 2013-12-27
b26bdb
b26bdb
* Mon Jun 03 2013 Michal Hlavinka <mhlavink@redhat.com> - 1.0.25-7
b26bdb
- fix support for aarch64, another part (#969831)
b26bdb
b26bdb
* Wed Mar 27 2013 Michal Hlavinka <mhlavink@redhat.com> - 1.0.25-6
b26bdb
- fix support for aarch64 (#925887)
b26bdb
b26bdb
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.25-5
b26bdb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
b26bdb
b26bdb
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.25-4
b26bdb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
b26bdb
b26bdb
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.25-3
b26bdb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
b26bdb
b26bdb
* Sat Nov 12 2011 Ville Skyttä <ville.skytta@iki.fi> - 1.0.25-2
b26bdb
- Patch to use system libgsm instead of a bundled copy.
b26bdb
- Make main package dep in -devel ISA qualified.
b26bdb
- Drop -octave Provides (not actually built with octave > 3.0).
b26bdb
- Don't build throwaway static lib.
b26bdb
- Run test suite during build.
b26bdb
b26bdb
* Thu Jul 14 2011 Michal Hlavinka <mhlavink@redhat.com> - 1.0.25-1
b26bdb
- Update to 1.0.25
b26bdb
- fixes integer overflow by processing certain PAF audio files (#721240)
b26bdb
b26bdb
* Sun Mar 27 2011 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> - 1.0.24-1
b26bdb
- Update to 1.0.24
b26bdb
b26bdb
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.23-2
b26bdb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
b26bdb
b26bdb
* Sat Oct 16 2010 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> - 1.0.23-1
b26bdb
- Update to 10.0.23
b26bdb
b26bdb
* Tue Oct 05 2010 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> - 1.0.22-1
b26bdb
- Update to 10.0.22
b26bdb
b26bdb
* Tue May 11 2010 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> - 1.0.21-1
b26bdb
- Update to 10.0.21
b26bdb
- Do not include the static library in the package (RHBZ#556074)
b26bdb
- Remove BR on jack since sndfile-jackplay is not provided anymore
b26bdb
b26bdb
* Mon Feb  1 2010 Stepan Kasal <skasal@redhat.com> - 1.0.20-5
b26bdb
- Do not build against Jack on RHEL
b26bdb
- Fix the Source0: URL
b26bdb
- Fix the licence tag
b26bdb
b26bdb
* Sat Nov 14 2009 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> - 1.0.20-4
b26bdb
- Split utils into a subpackage
b26bdb
b26bdb
* Sat Nov 14 2009 Orcan Ogetbil <oget[dot]fedora[at]gmail[dot]com> - 1.0.20-3
b26bdb
- Add FLAC/Ogg/Vorbis support (BR: libvorbis-devel)
b26bdb
- Make build verbose
b26bdb
- Remove rpath
b26bdb
- Fix ChangeLog encoding
b26bdb
- Move the big Changelog to the devel package
b26bdb
b26bdb
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.20-2
b26bdb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
b26bdb
b26bdb
* Sat Jun 06 2009 Lennart Poettering <lpoetter@redhat.com> - 1.0.20-1
b26bdb
- Updated to 1.0.20
b26bdb
b26bdb
* Tue Mar 03 2009 Robert Scheck <robert@fedoraproject.org> - 1.0.17-8
b26bdb
- Rebuilt against libtool 2.2
b26bdb
b26bdb
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.17-7
b26bdb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
b26bdb
b26bdb
* Thu Oct 25 2008 Andreas Thienemann <andreas@bawue.net> - 1.0.17-6
b26bdb
- Removed spurious #endif in the libsndfile.h wrapper. Thx to Edward
b26bdb
  Sheldrake for finding it. Fixes #468508.
b26bdb
- Fix build for autoconf-2.63
b26bdb
b26bdb
* Thu Oct 23 2008 Andreas Thienemann <andreas@bawue.net> - 1.0.17-5
b26bdb
- Fixed multilib conflict. #342401
b26bdb
- Made flac support actually work correctly.
b26bdb
b26bdb
* Thu Aug  7 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 1.0.17-4
b26bdb
- fix license tag
b26bdb
b26bdb
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.0.17-3
b26bdb
- Autorebuild for GCC 4.3
b26bdb
b26bdb
* Thu Sep 20 2007 Andreas Thienemann <andreas@bawue.net> - 1.0.17-2
b26bdb
- Adding FLAC support to libsndfile courtesy of gentoo, #237575
b26bdb
- Fixing CVE-2007-4974. Thanks to the gentoo people for the patch, #296221
b26bdb
b26bdb
* Fri Sep 08 2006 Andreas Thienemann <andreas@bawue.net> - 1.0.17-1
b26bdb
- Updated to 1.0.17
b26bdb
b26bdb
* Sun Apr 30 2006 Andreas Thienemann <andreas@bawue.net> - 1.0.16-1
b26bdb
- Updated to 1.0.16
b26bdb
b26bdb
* Thu Mar 30 2006 Andreas Thienemann <andreas@bawue.net> - 1.0.15-1
b26bdb
- Updated to 1.0.15
b26bdb
b26bdb
* Thu Mar 16 2006 Dams <anvil[AT]livna.org> - 1.0.14-1.fc5
b26bdb
- Updated to 1.0.14
b26bdb
- Dropped patch0
b26bdb
b26bdb
* Thu May 12 2005 Michael Schwendt <mschwendt[AT]users.sf.net> - 1.0.11-3
b26bdb
- rebuilt
b26bdb
b26bdb
* Sat Mar  5 2005 Michael Schwendt <mschwendt[AT]users.sf.net> - 1.0.11-2
b26bdb
- Fix format string bug (#149863).
b26bdb
- Drop explicit Epoch 0.
b26bdb
b26bdb
* Sat Dec  4 2004 Ville Skyttä <ville.skytta@iki.fi> - 0:1.0.11-0.fdr.1
b26bdb
- Update to 1.0.11.
b26bdb
b26bdb
* Wed Oct 13 2004 Ville Skyttä <ville.skytta@iki.fi> - 0:1.0.10-0.fdr.1
b26bdb
- Update to 1.0.10, update URLs, include ALSA support.
b26bdb
- Disable dependency tracking to speed up the build.
b26bdb
- Add missing ldconfig invocations.
b26bdb
- Make -devel require pkgconfig.
b26bdb
- Include developer docs in -devel.
b26bdb
- Provide -octave in main package, own more related dirs.
b26bdb
- Bring specfile up to date with current spec templates.
b26bdb
b26bdb
* Sat Apr 12 2003 Dams <anvil[AT]livna.org>
b26bdb
- Initial build.