]>
Commit | Line | Data |
---|---|---|
79fb52b2 | 1 | # |
8eebf965 | 2 | # Conditional build: |
6b1bcd9b JK |
3 | %bcond_without python2 # python bindings |
4 | %bcond_without python3 # python bindings | |
8eebf965 | 5 | # |
691d98ed JB |
6 | Summary: aubio - library for audio labelling |
7 | Summary(pl.UTF-8): aubio - biblioteka do oznaczania dźwięku | |
79fb52b2 | 8 | Name: aubio |
6b1bcd9b | 9 | Version: 0.4.3 |
fd0e29a7 | 10 | Release: 3 |
6b1bcd9b | 11 | License: GPL v3+ |
79fb52b2 | 12 | Group: Libraries |
6b1bcd9b JK |
13 | Source0: http://aubio.piem.org/pub/%{name}-%{version}.tar.bz2 |
14 | # Source0-md5: 52a960cfc8a3e3125f3a258545d1c7e5 | |
fd0e29a7 | 15 | Patch0: ffmpeg4.patch |
79fb52b2 | 16 | URL: http://aubio.piem.org/ |
21b138b4 | 17 | BuildRequires: alsa-lib-devel >= 0.9.0 |
6b1bcd9b JK |
18 | BuildRequires: doxygen |
19 | BuildRequires: ffmpeg-devel | |
21b138b4 JB |
20 | BuildRequires: fftw3-single-devel >= 3.0.0 |
21 | BuildRequires: jack-audio-connection-kit-devel >= 0.15.0 | |
21b138b4 JB |
22 | BuildRequires: libsamplerate-devel >= 0.0.15 |
23 | BuildRequires: libsndfile-devel >= 1.0.4 | |
21b138b4 | 24 | BuildRequires: pkgconfig |
6b1bcd9b JK |
25 | BuildRequires: txt2man |
26 | %if %{with python2} || %{with python3} | |
21b138b4 | 27 | BuildRequires: rpm-pythonprov |
6b1bcd9b JK |
28 | BuildRequires: rpmbuild(macros) >= 1.714 |
29 | %endif | |
30 | %if %{with python2} | |
31 | BuildRequires: python-devel | |
32 | BuildRequires: python-numpy-devel | |
33 | BuildRequires: python-setuptools | |
34 | %endif | |
35 | %if %{with python3} | |
36 | BuildRequires: python3-devel | |
37 | BuildRequires: python3-numpy-devel | |
38 | BuildRequires: python3-setuptools | |
8eebf965 | 39 | %endif |
cefd6b85 | 40 | BuildRequires: sed >= 4.0 |
79fb52b2 SS |
41 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
42 | ||
43 | %description | |
691d98ed JB |
44 | aubio is a library for audio labelling. |
45 | ||
46 | %description -l pl.UTF-8 | |
47 | aubio to biblioteka do oznaczania dźwięku. | |
79fb52b2 SS |
48 | |
49 | %package devel | |
9d374366 SS |
50 | Summary: Header files for aubio library |
51 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki aubio | |
79fb52b2 SS |
52 | Group: Development/Libraries |
53 | Requires: %{name} = %{version}-%{release} | |
21b138b4 JB |
54 | Requires: fftw3-single-devel >= 3.0.0 |
55 | Requires: libsamplerate-devel >= 0.0.15 | |
56 | # for libaubioext: | |
57 | # alsa-lib-devel >= 0.9.0 | |
58 | # jack-audio-connection-kit-devel >= 0.15.0 | |
59 | # libsndfile-devel >= 1.0.4 | |
79fb52b2 SS |
60 | |
61 | %description devel | |
62 | Header files for aubio library. | |
63 | ||
64 | %description devel -l pl.UTF-8 | |
65 | Pliki nagłówkowe biblioteki aubio. | |
66 | ||
67 | %package static | |
68 | Summary: Static aubio library | |
69 | Summary(pl.UTF-8): Statyczna biblioteka aubio | |
70 | Group: Development/Libraries | |
71 | Requires: %{name}-devel = %{version}-%{release} | |
72 | ||
73 | %description static | |
74 | Static aubio library. | |
75 | ||
76 | %description static -l pl.UTF-8 | |
77 | Statyczna biblioteka aubio. | |
78 | ||
b9d3858a SS |
79 | %package progs |
80 | Summary: Example applications using aubio library | |
691d98ed JB |
81 | Summary(pl.UTF-8): Przykładowe programy korzystajace z biblioteki aubio |
82 | Group: Applications/Sound | |
b9d3858a SS |
83 | Requires: %{name} = %{version}-%{release} |
84 | ||
85 | %description progs | |
86 | A few examples of applications using aubio library: | |
691d98ed | 87 | - aubioonset: outputs the onset detected. |
b9d3858a | 88 | - aubionotes: uses both onset and pitch to extract symbolic music data |
6b1bcd9b | 89 | from an audio source and emit MIDI like data. |
691d98ed | 90 | - aubiocut: a Python script that takes an input sound and creates one |
6b1bcd9b JK |
91 | new sample at each detected onset or beat. The slices produced by |
92 | aubiocut are useful for use with a sequencer such as Hydrogen. | |
691d98ed JB |
93 | - aubiopitch: a Python script to extract pitch tracks from sound |
94 | files. | |
95 | ||
96 | %description progs -l pl.UTF-8 | |
97 | Kilka przykładowych aplikacji korzystających z biblioteki dubio: | |
98 | - aubioonset - wypisuje wykryty początek. | |
99 | - aubionotes - wykorzystuje początek i wysokość do wyciągnięcia | |
6b1bcd9b JK |
100 | symbolicznych danych muzycznych ze źródła dźwięku i stworzenia danych |
101 | typu MIDI. | |
691d98ed JB |
102 | - aubiocut - skrypt Pythona pobierający dźwięk wejściowy i tworzący |
103 | nową próbkę dla każdego wykrytego początku lub taktu. Fragmenty | |
6b1bcd9b JK |
104 | tworzone przez aubiocut są przydatne do wykorzystania przez sekwencer, |
105 | jak np. Hydrogen. | |
106 | - aubiopitch - skrypt Pythona do wyciągania ścieżek wysokości z plików | |
107 | dźwiękowych. | |
b9d3858a | 108 | |
8eebf965 | 109 | %package -n python-aubio |
691d98ed JB |
110 | Summary: aubio Python bindings |
111 | Summary(pl.UTF-8): Wiązania Pythona do biblioteki aubio | |
8eebf965 SS |
112 | Group: Libraries/Python |
113 | Requires: %{name} = %{version}-%{release} | |
114 | ||
115 | %description -n python-aubio | |
691d98ed JB |
116 | aubio Python bindings. |
117 | ||
118 | %description -n python-aubio -l pl.UTF-8 | |
119 | Wiązania Pythona do biblioteki aubio. | |
8eebf965 | 120 | |
6b1bcd9b JK |
121 | %package -n python3-aubio |
122 | Summary: aubio Python bindings | |
123 | Summary(pl.UTF-8): Wiązania Pythona do biblioteki aubio | |
124 | Group: Libraries/Python | |
125 | Requires: %{name} = %{version}-%{release} | |
126 | ||
127 | %description -n python3-aubio | |
128 | aubio Python bindings. | |
129 | ||
130 | %description -n python3-aubio -l pl.UTF-8 | |
131 | Wiązania Pythona do biblioteki aubio. | |
132 | ||
79fb52b2 SS |
133 | %prep |
134 | %setup -q | |
fd0e29a7 | 135 | %patch0 -p1 |
79fb52b2 SS |
136 | |
137 | %build | |
6b1bcd9b JK |
138 | export CC="%{__cc}" |
139 | export CXX="%{__cxx}" | |
140 | export CFLAGS="%{rpmcflags}" | |
141 | export CXXFLAGS="%{rpmcxxflags}" | |
142 | export LDFLAGS="%{rpmldflags}" | |
143 | ./waf configure \ | |
144 | --prefix=%{_prefix} \ | |
145 | --libdir=%{_libdir} \ | |
146 | --libexecdir=%{_libexecdir} \ | |
147 | --enable-fftw3f \ | |
148 | --enable-jack \ | |
149 | --enable-sndfile \ | |
150 | --enable-avcodec \ | |
151 | --enable-samplerate \ | |
152 | --disable-atlas \ | |
153 | --enable-docs | |
154 | ||
155 | ./waf build -v | |
156 | ||
157 | %if %{with python2} | |
158 | %py_build %{?with_tests:test} | |
159 | %endif | |
160 | ||
161 | %if %{with python3} | |
162 | %py3_build %{?with_tests:test} | |
163 | %endif | |
79fb52b2 SS |
164 | |
165 | %install | |
166 | rm -rf $RPM_BUILD_ROOT | |
167 | ||
6b1bcd9b JK |
168 | ./waf install -v \ |
169 | --destdir=$RPM_BUILD_ROOT \ | |
170 | --libdir=%{_libdir} \ | |
171 | --prefix=%{_prefix} \ | |
172 | --libexecdir=%{_libexecdir} | |
79fb52b2 | 173 | |
6b1bcd9b JK |
174 | %if %{with python2} |
175 | %py_install | |
176 | %endif | |
177 | ||
178 | %if %{with python3} | |
179 | %py3_install | |
180 | %endif | |
181 | ||
182 | rm -r $RPM_BUILD_ROOT%{_docdir}/libaubio-doc | |
21b138b4 | 183 | |
79fb52b2 SS |
184 | %clean |
185 | rm -rf $RPM_BUILD_ROOT | |
186 | ||
187 | %post -p /sbin/ldconfig | |
188 | %postun -p /sbin/ldconfig | |
189 | ||
190 | %files | |
191 | %defattr(644,root,root,755) | |
6b1bcd9b JK |
192 | %doc AUTHORS ChangeLog README.md |
193 | %attr(755,root,root) %{_libdir}/libaubio.so.5.*.* | |
194 | %attr(755,root,root) %ghost %{_libdir}/libaubio.so.5 | |
79fb52b2 SS |
195 | |
196 | %files devel | |
197 | %defattr(644,root,root,755) | |
6b1bcd9b | 198 | %doc doc/web/html/* |
21b138b4 | 199 | %attr(755,root,root) %{_libdir}/libaubio.so |
79fb52b2 | 200 | %{_includedir}/%{name} |
21b138b4 | 201 | %{_pkgconfigdir}/aubio.pc |
79fb52b2 | 202 | |
b9d3858a SS |
203 | %files progs |
204 | %defattr(644,root,root,755) | |
6b1bcd9b | 205 | %attr(755,root,root) %{_bindir}/aubiomfcc |
8eebf965 SS |
206 | %attr(755,root,root) %{_bindir}/aubionotes |
207 | %attr(755,root,root) %{_bindir}/aubioonset | |
6b1bcd9b JK |
208 | %attr(755,root,root) %{_bindir}/aubiopitch |
209 | %attr(755,root,root) %{_bindir}/aubioquiet | |
8eebf965 | 210 | %attr(755,root,root) %{_bindir}/aubiotrack |
6b1bcd9b | 211 | %{_mandir}/man1/aubiomfcc.1* |
21b138b4 JB |
212 | %{_mandir}/man1/aubionotes.1* |
213 | %{_mandir}/man1/aubioonset.1* | |
6b1bcd9b JK |
214 | %{_mandir}/man1/aubiopitch.1* |
215 | %{_mandir}/man1/aubioquiet.1* | |
21b138b4 | 216 | %{_mandir}/man1/aubiotrack.1* |
8eebf965 | 217 | |
6b1bcd9b | 218 | %if %{with python2} |
8eebf965 SS |
219 | %files -n python-aubio |
220 | %defattr(644,root,root,755) | |
21b138b4 | 221 | %dir %{py_sitedir}/aubio |
6b1bcd9b JK |
222 | %{py_sitedir}/aubio/*.py* |
223 | %attr(755,root,root) %{py_sitedir}/aubio/_aubio.so | |
224 | %{py_sitedir}/aubio*.egg-info | |
225 | %if %{without python3} | |
226 | %attr(755,root,root) %{_bindir}/aubiocut | |
227 | %{_mandir}/man1/aubiocut.1* | |
228 | %endif | |
229 | %endif | |
230 | ||
231 | %if %{with python3} | |
232 | %files -n python3-aubio | |
233 | %defattr(644,root,root,755) | |
234 | %dir %{py3_sitedir}/aubio | |
235 | %{py3_sitedir}/aubio/__pycache__ | |
236 | %{py3_sitedir}/aubio/*.py | |
237 | %attr(755,root,root) %{py3_sitedir}/aubio/_aubio.*.so | |
238 | %{py3_sitedir}/aubio*.egg-info | |
21b138b4 | 239 | %attr(755,root,root) %{_bindir}/aubiocut |
21b138b4 | 240 | %{_mandir}/man1/aubiocut.1* |
21b138b4 | 241 | %endif |