source: projects/specs/trunk/lib/libs/libsndfile/libsndfile-vl.spec @ 9358

Revision 9358, 7.5 KB checked in by inagaki, 9 years ago (diff)

2015-02-18 Ryoichi INAGAKI <ryo1@…>

  • libidn: updated
  • libsndfile: rebuilt


Line 
1%define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
2
3Summary:        A library to handle various audio file formats.
4Summary(ja):    さまざまなフォーマットの音声ファイルを扱うライブラリ
5Name:           libsndfile
6Version:        1.0.25
7Release:        2%{?_dist_release}
8
9License:        LGPLv2+ and GPLv2+ and BSD
10Group:          System Environment/Libraries
11URL:            http://www.mega-nerd.com/libsndfile/
12
13Source0:        http://www.mega-nerd.com/libsndfile/%{name}-%{version}.tar.gz
14Patch0:         %{name}-1.0.25-system-gsm.patch
15Patch1:         libsndfile-1.0.25-zerodivfix.patch
16
17# security fix
18Patch100:       libsndfile-1.0.21_CVE-2011-2696.patch
19Patch101:       libsndfile-1.0.25-cve2014_9496.patch
20
21BuildRoot:      %{_tmppath}/%{name}-%{version}-root
22BuildRequires:  alsa-lib-devel
23BuildRequires:  flac-devel
24BuildRequires:  libogg-devel
25BuildRequires:  libvorbis-devel
26BuildRequires:  pkgconfig
27BuildRequires:  sqlite3-devel
28BuildRequires:  gsm-devel
29
30Vendor:         Project Vine
31Distribution:   Vine Linux
32
33%description
34libsndfile is a C library for reading and writing sound files such as
35AIFF, AU and WAV files through one standard interface. It can currently
36read/write 8, 16, 24 and 32-bit PCM files as well as 32-bit floating
37point WAV files and a number of compressed formats.
38
39
40%package devel
41Summary: Libraries, includes, etc to develop libsndfile applications
42Summary(ja): libsndfile アプリケーションを開発するためのファイル集
43Group: Development/Libraries
44Requires: %{name} = %{version}-%{release}
45Requires: pkgconfig
46
47%description devel
48Libraries, include files, etc you can use to develop libsndfile applications.
49
50
51# compat32
52%package -n compat32-%{name}
53Summary: A library to handle various audio file formats.
54Summary(ja): さまざまなフォーマットの音声ファイルを扱うライブラリ
55Group: System Environment/Libraries
56
57%description -n compat32-%{name}
58libsndfile is a C library for reading and writing sound files such as
59AIFF, AU and WAV files through one standard interface. It can currently
60read/write 8, 16, 24 and 32-bit PCM files as well as 32-bit floating
61point WAV files and a number of compressed formats.
62
63
64%package -n compat32-%{name}-devel
65Summary: Libraries, includes, etc to develop libsndfile applications
66Summary(ja): libsndfile アプリケーションを開発するためのファイル集
67Group: Development/Libraries
68Requires: compat32-%{name} = %{version}-%{release}
69Requires: compat32-pkgconfig
70Requires: %{name}-devel = %{version}-%{release}
71
72%description -n compat32-%{name}-devel
73Libraries, include files, etc you can use to develop libsndfile applications.
74
75
76%prep
77%setup -q
78%patch0 -p1
79%patch1 -p1 -b .zerodivfix
80
81# security fix
82%patch100 -p1 -b .CVE-2011-2696
83%patch101 -p1 -b .cve2014_9496
84
85rm -r src/GSM610 ; autoreconf -I M4 -fiv # for system-gsm patch
86
87%build
88%configure \
89        --disable-dependency-tracking \
90        --enable-sqlite \
91        --enable-alsa \
92        --enable-largefile \
93        --disable-static
94
95# Get rid of rpath
96sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
97sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
98
99make %{?_smp_mflags}
100
101%install
102rm -rf $RPM_BUILD_ROOT
103make install DESTDIR=$RPM_BUILD_ROOT
104
105rm -rf html
106cp -pr $RPM_BUILD_ROOT%{_datadir}/doc/libsndfile1-dev html
107rm -rf $RPM_BUILD_ROOT%{_datadir}/doc/libsndfile1-dev
108
109rm -f $RPM_BUILD_ROOT%{_libdir}/lib*.la
110
111
112# fix multilib issues
113%if %{__isa_bits} == 64
114%define wordsize 64
115%else
116%define wordsize 32
117%endif
118
119mv $RPM_BUILD_ROOT%{_includedir}/sndfile.h \
120   $RPM_BUILD_ROOT%{_includedir}/sndfile-%{wordsize}.h
121
122cat > $RPM_BUILD_ROOT%{_includedir}/sndfile.h <<EOF
123#include <bits/wordsize.h>
124
125#if __WORDSIZE == 32
126# include "sndfile-32.h"
127#elif __WORDSIZE == 64
128# include "sndfile-64.h"
129#else
130# error "unexpected value for __WORDSIZE macro"
131#endif
132EOF
133
134%check
135LD_LIBRARY_PATH=$PWD/src/.libs make check
136
137%clean
138rm -rf $RPM_BUILD_ROOT
139
140%post -p /sbin/ldconfig
141
142%postun -p /sbin/ldconfig
143
144# compat32
145%if %{build_compat32}
146%post -n compat32-%{name} -p /sbin/ldconfig
147
148%postun -n compat32-%{name} -p /sbin/ldconfig
149%endif
150
151%files
152%defattr(-,root,root)
153%doc AUTHORS COPYING ChangeLog NEWS README
154%{_libdir}/libsndfile.so.*
155%{_bindir}/*
156%{_mandir}/man1/*
157
158%files devel
159%defattr(-,root,root)
160%doc html/*
161%{_libdir}/libsndfile.so
162%{_includedir}/sndfile.h
163%{_includedir}/sndfile.hh
164%{_includedir}/sndfile-%{wordsize}.h
165%{_libdir}/pkgconfig/sndfile.pc
166
167# compat32
168%if %{build_compat32}
169%files -n compat32-%{name}
170%defattr(-,root,root)
171%{_libdir}/libsndfile.so.*
172
173%files -n compat32-%{name}-devel
174%defattr(-,root,root)
175%{_includedir}/sndfile-%{wordsize}.h
176%{_libdir}/libsndfile.so
177%{_libdir}/pkgconfig/sndfile.pc
178%endif
179
180
181%changelog
182* Wed Feb 18 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> - 1.0.25-2
183- added Patch0, 1 and 101 from Fedora
184  * Tue Jan 13 2015 Michal Hlavinka <mhlavink@redhat.com> - 1.0.25-14
185  - fix CVE-2014-9496: 2 buffer overruns in sd2_parse_rsrc_fork (#1178840)
186  - division by zero leading to denial of service in psf_fwrite (#1177254)
187  * Sat Nov 12 2011 Ville Skyttä <ville.skytta@iki.fi> - 1.0.25-2
188  - Patch to use system libgsm instead of a bundled copy.
189- added BR: flac-devel, libogg-devel, libvorbis-devel, pkgconfig,
190  sqlite3-devel and gsm-devel
191
192* Mon Apr 29 2013 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.0.25-1
193- new upstream release
194
195* Sun Jul 31 2011 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> - 1.0.21-3
196- change spec filename (-vl)
197
198* Sat Jul 30 2011 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> - 1.0.21-2
199- add patch100 for fix CVE-2011-2696 (IOF) from debian, thanks.
200
201* Wed Sep 22 2010 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.0.21-1
202- new upstream release
203- built with rpm-4.8.1-1
204
205* Mon Jun  1 2009 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.0.20-1vl5
206- new upstream release with security fix (CVE-2009-1788, 1791)
207- add patch110 to fix devide by 0 issues
208- drop patch100 (is included in new release)
209- change configure option to fix new release
210- revome "TODO" file from file list
211
212* Sun May 10 2009 NAKAMURA Kenta <kenta@vinelinux.org> 1.0.17-3
213- added compat32 package for x86_64 arch support
214
215* Tue Mar 31 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 1.0.17-2
216- spec in utf-8
217- remove static lib
218
219* Sat Jul 12 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.0.17-1vl5
220- applied new versioning policy
221- removed lib*.la file from devel package
222
223* Mon Oct 22 2007 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.0.17-0vl2
224- rebuild for VineSeed
225
226* Mon Oct 22 2007 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.0.17-0vl1
227- new upstream release
228
229* Mon Oct 22 2007 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.0.16-0vl3.1
230- add patch100 for fix CVE-2007-4974 (PCM Data Handling Buffer Overflow)
231- built for VinePlus 4.x
232
233* Fri Nov 17 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 1.0.16-0vl3
234- add BuildRequires: alsa-lib-devel
235- add '--disable-sqlite --disable-flac' options to %%configure
236
237* Mon May 01 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.0.16-0vl2
238- rebuilt for VineSeed Plus
239
240* Mon May 01 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.0.16-0vl1
241- new upstream release
242- fixed Japanese summary
243
244* Wed Feb 08 2006 Atsushi SHICHI <ats7@a.email.ne.jp> 1.0.13-1vl1
245- initial build for VinePlus/3.0
246- modified spec file
247
248* Sun May 15 2005 Erik de Castro Lopo <erikd@mega-nerd.com>
249- Add html files to the files section.
250
251* Tue Sep 16 2003 Erik de Castro Lopo <erikd@mega-nerd.com>
252- Apply corrections from Andrew Schultz.
253
254* Mon Oct 21 2002 Erik de Castro Lopo <erikd@mega-nerd.com>
255- Force installation of sndfile.pc file.
256
257* Thu Jul 6 2000 Josh Green <jgreen@users.sourceforge.net>
258- Created libsndfile.spec.in
259
260
261# end of file
Note: See TracBrowser for help on using the repository browser.