]> git.pld-linux.org Git - packages/alsa-lib.git/blob - alsa-lib.spec
- updated to 1.2.1.1
[packages/alsa-lib.git] / alsa-lib.spec
1 #
2 # Conditional build:
3 %bcond_without  static_libs     # don't build static library
4 %bcond_without  apidocs         # do not build and package API docs
5 %bcond_without  python          # smixer-python binding
6 %bcond_with     python2         # python 2.x instead of python 3.x for smixer pymodules
7 %bcond_with     resmgr          # Resource Manager support
8
9 Summary:        Advanced Linux Sound Architecture (ALSA) - Library
10 Summary(es.UTF-8):      Advanced Linux Sound Architecture (ALSA) - Biblioteca
11 Summary(pl.UTF-8):      Advanced Linux Sound Architecture (ALSA) - Biblioteka
12 Summary(pt_BR.UTF-8):   Biblioteca para o ALSA (Advanced Linux Sound Architecture)
13 Summary(ru.UTF-8):      Библиотека API для работы с драйвером ALSA
14 Summary(uk.UTF-8):      Бібліотека API для роботи з драйвером ALSA
15 Name:           alsa-lib
16 Version:        1.2.1.1
17 Release:        1
18 License:        LGPL v2.1+
19 Group:          Libraries
20 Source0:        ftp://ftp.alsa-project.org/pub/lib/%{name}-%{version}.tar.bz2
21 # Source0-md5:  1d428f46d6160f5e4bbdd64a2ff34f45
22 Source1:        %{name}-modprobe.conf
23 Source2:        %{name}-asound.conf
24 Source3:        smixer.conf
25 Source4:        ftp://ftp.alsa-project.org/pub/lib/alsa-topology-conf-1.2.1.tar.bz2
26 # Source4-md5:  7fdf5fff3f1e0603456e719f6033e922
27 Source5:        ftp://ftp.alsa-project.org/pub/lib/alsa-ucm-conf-1.2.1.tar.bz2
28 # Source5-md5:  73697aaba4e9701bd2d3ae17ccd1a005
29 Patch0:         python-3.8.patch
30 URL:            https://www.alsa-project.org/
31 BuildRequires:  autoconf >= 2.59
32 BuildRequires:  automake
33 BuildRequires:  doxygen
34 BuildRequires:  libtool >= 1.4
35 %if %{with python}
36 %if %{with python2}
37 BuildRequires:  python-devel >= 1:2.4
38 BuildRequires:  python-modules >= 1:2.4
39 %else
40 BuildRequires:  python3-devel >= 1:3.2
41 BuildRequires:  python3-modules >= 1:3.2
42 %endif
43 %endif
44 %{?with_resmgr:BuildRequires:   resmgr-devel}
45 BuildConflicts: alsa-lib <= 0.4.0
46 Obsoletes:      alsa-libs
47 Conflicts:      alsa-utils < 1.0.20-3
48 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
49
50 %description
51 Advanced Linux Sound Architecture (ALSA) - Library
52
53 Features:
54 - general
55         - modularized architecture
56         - support for versioned and exported symbols
57         - full proc filesystem support - /proc/sound
58 - ISA soundcards
59         - support for 128k ISA DMA buffer
60 - mixer
61         - new enhanced API for applications
62         - support for unlimited number of channels
63         - volume can be set in three ways (percentual (0-100), exact and
64           decibel)
65         - support for mute (and hardware mute if hardware supports it)
66         - support for mixer events
67                 - this allows two or more applications to be synchronized
68 - digital audio (PCM)
69         - new enhanced API for applications
70         - full real duplex support
71         - full duplex support for SoundBlaster 16/AWE soundcards
72         - digital audio data for playback and record should be read back using
73           proc filesystem
74 - OSS/Lite compatibility
75         - full mixer compatibity
76         - full PCM (/dev/dsp) compatibility
77
78 %description -l pl.UTF-8
79 Advanced Linux Sound Architecture (ALSA) - Biblioteka
80
81 Możliwości:
82 - generalne
83         - zmodularyzowana architektura
84         - pełne wsparcie dla systemu plików proc - /proc/sound
85 - karty dźwiękowe ISA
86         - obsługa bufora 128k ISA DMA
87 - mikser
88         - nowe rozszerzone API dla aplikacji
89         - obsługa nielimitowanej liczby kanałów
90         - głośność może być ustawiana na trzy różne sposoby (procentowo
91           (0-100), liniowo oraz w skali decybelowej)
92         - obsługa wyciszania (oraz sprzętowego wyciszania)
93         - obsługa zdarzeń miksera
94                 - to pozwala dwum lub większej liczbie aplikacji się synchronizować
95 - cyfrowe audio (PCM)
96         - nowe rozszerzone API dla aplikacji
97         - pełna, prawdziwa obsługa trybu duplex
98         - pełna obsługa trybu duplex dla kart SoundBlaster 16/AWE
99         - dane cyfrowego dźwięku dla odtwarzania i nagrywania powinny być
100           odczytywane poprzez system plików /proc
101 - kompatybilność z OSS/Lite
102         - pełna kompatybilność miksera
103         - pełna kompatybilność PCM (/dev/dsp)
104
105 %description -l pt_BR.UTF-8
106 Bibliotecas para o ALSA. Esse pacote é necessário para rodar programas
107 Linux queusam o driver de som ALSA.
108
109 %description -l ru.UTF-8
110 Библиотека API для работы с драйвером ALSA.
111
112 %description -l uk.UTF-8
113 Бібліотека API для роботи з драйвером ALSA.
114
115 %package devel
116 Summary:        Advanced Linux Sound Architecture (ALSA) - header files
117 Summary(es.UTF-8):      Archivos de desarrollo de ALSA
118 Summary(pl.UTF-8):      Advanced Linux Sound Architecture (ALSA) - pliki nagłówkowe
119 Summary(pt_BR.UTF-8):   Arquivos de desenvolvimento do ALSA (Advanced Linux Sound Architecture)
120 Summary(ru.UTF-8):      Библиотека API для работы с драйвером ALSA - файлы программиста
121 Summary(uk.UTF-8):      Бібліотека API для роботи з драйвером ALSA - файли програміста
122 Group:          Development/Libraries
123 Requires:       %{name} = %{version}-%{release}
124 Obsoletes:      alsa-devel
125 Obsoletes:      alsa-lib-devel-doc
126
127 %description devel
128 Advanced Linux Sound Architecture (ALSA) - header files.
129
130 %description devel -l es.UTF-8
131 Este paquete contiene los archivos necesarios para compilar programas
132 que usan la biblioteca del sistema ALSA. No es necesario instalarlo si
133 lo que se desea es solamente ejecutar programas.
134
135 %description devel -l pl.UTF-8
136 Advanced Linux Sound Architecture (ALSA) - pliki nagłówkowe.
137
138 %description devel -l pt_BR.UTF-8
139 Esse pacote contém os arquivos necessários para compilar programas que
140 usam a biblioteca do ALSA. Não é necessário instalar esse pacote para
141 apenas rodar programas.
142
143 %description devel -l ru.UTF-8
144 Библиотеки разработчика и хедера для библиотеки API для работы с
145 драйвером ALSA.
146
147 %description devel -l uk.UTF-8
148 Бібліотеки програміста та хедери для бібліотеки API для роботи з
149 драйвером ALSA.
150
151 %package static
152 Summary:        Advanced Linux Sound Architecture (ALSA) - static library
153 Summary(pl.UTF-8):      Advanced Linux Sound Architecture (ALSA) - biblioteka statyczna
154 Summary(pt_BR.UTF-8):   Bibliotecas estáticas para desenvolvimento com a alsa-lib
155 Summary(ru.UTF-8):      Статическая библиотека API для работы с драйвером ALSA
156 Summary(uk.UTF-8):      Статична бібліотека API для роботи з драйвером ALSA
157 Group:          Development/Libraries
158 Requires:       %{name}-devel = %{version}-%{release}
159
160 %description static
161 Advanced Linux Sound Architecture (ALSA) - static library.
162
163 %description static -l pl.UTF-8
164 Advanced Linux Sound Architecture (ALSA) - biblioteka statyczna.
165
166 %description static -l pt_BR.UTF-8
167 Bibliotecas estáticas para desenvolvimento com a alsa-lib
168
169 %description static -l ru.UTF-8
170 Статическая библиотека API для работы с драйвером ALSA.
171
172 %description static -l uk.UTF-8
173 Статична бібліотека API для роботи з драйвером ALSA.
174
175 %package apidocs
176 Summary:        ALSA Library API documentation
177 Summary(pl.UTF-8):      Dokumentacja API biblioteki ALSA
178 Group:          Documentation
179 %if "%{_rpmversion}" >= "5"
180 BuildArch:      noarch
181 %endif
182
183 %description apidocs
184 API and internal documentation for ALSA Library.
185
186 %description apidocs -l pl.UTF-8
187 Dokumentacja API biblioteki ALSA.
188
189 %package smixer-python
190 Summary:        Python binding module for ALSA Mixer Interface
191 Summary(pl.UTF-8):      Moduł wiązania Pythona dla interfejsu miksera architektury ALSA
192 Group:          Libraries
193 Requires:       %{name} = %{version}-%{release}
194
195 %description smixer-python
196 Python binding module for ALSA Mixer Interface.
197
198 %description smixer-python -l pl.UTF-8
199 Moduł wiązania Pythona dla interfejsu miksera architektury ALSA.
200
201 %prep
202 %setup -q
203 %if %{without python2} && "%{py3_ver}" >= "3.8"
204 %patch0 -p1
205 %endif
206 cp -p %{SOURCE3} src/conf
207
208 %build
209 %{__libtoolize}
210 %{__aclocal} -I m4
211 %{__autoconf}
212 %{__autoheader}
213 %{__automake}
214 configure_opts="\
215         --disable-silent-rules \
216         %{!?with_python:--disable-python} \
217         %{?with_python2:--enable-python2} \
218         %{?with_resmgr:--enable-resmgr} \
219         --enable-mixer-modules \
220         --enable-mixer-pymods
221 "
222
223 %if %{with static_libs}
224 install -d build-static
225 cd build-static
226 ../%configure $configure_opts \
227         --disable-shared \
228         --enable-static
229 %{__make}
230 cd ..
231 %endif
232
233 install -d build-shared
234 cd build-shared
235 ../%configure $configure_opts \
236         --enable-shared \
237         --disable-static
238
239 %{__make}
240 %{?with_apidocs:%{__make} doc}
241 cd ..
242
243 %install
244 rm -rf $RPM_BUILD_ROOT
245 install -d $RPM_BUILD_ROOT{/%{_lib},%{_sysconfdir}/alsa/conf.d,%{_datadir}/alsa/alsa.conf.d,/etc/modprobe.d}
246
247 %if %{with static_libs}
248 %{__make} -C build-static/src install-libLTLIBRARIES \
249         DESTDIR=$RPM_BUILD_ROOT
250 %endif
251
252 %{__make} -C build-shared install \
253         DESTDIR=$RPM_BUILD_ROOT
254
255 %{__mv} $RPM_BUILD_ROOT%{_libdir}/libasound.so.* $RPM_BUILD_ROOT/%{_lib}
256 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libasound.so
257 ln -sf /%{_lib}/$(cd $RPM_BUILD_ROOT/%{_lib}; echo libasound.so.*.*) \
258         $RPM_BUILD_ROOT%{_libdir}/libasound.so
259
260 tar xf %{SOURCE4} -C $RPM_BUILD_ROOT%{_datadir}/alsa topology
261 tar xf %{SOURCE5} -C $RPM_BUILD_ROOT%{_datadir}/alsa ucm ucm2
262
263 install -D utils/alsa.m4 $RPM_BUILD_ROOT%{_aclocaldir}/alsa.m4
264 install %{SOURCE1} $RPM_BUILD_ROOT/etc/modprobe.d/alsa-base.conf
265 install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/asound.conf
266
267 %{__rm} $RPM_BUILD_ROOT%{_libdir}/alsa-lib/smixer/*.la
268
269 %clean
270 rm -rf $RPM_BUILD_ROOT
271
272 %post   -p /sbin/ldconfig
273 %postun -p /sbin/ldconfig
274
275 %files
276 %defattr(644,root,root,755)
277 %doc doc/asoundrc.txt
278 %attr(755,root,root) %{_bindir}/aserver
279 %attr(755,root,root) /%{_lib}/libasound.so.*.*.*
280 %attr(755,root,root) %ghost /%{_lib}/libasound.so.2
281 %attr(755,root,root) /%{_libdir}/libatopology.so.*.*.*
282 %attr(755,root,root) %ghost /%{_libdir}/libatopology.so.2
283 %dir %{_libdir}/alsa-lib
284 %dir %{_libdir}/alsa-lib/smixer
285 %attr(755,root,root) %{_libdir}/alsa-lib/smixer/smixer-ac97.so
286 %attr(755,root,root) %{_libdir}/alsa-lib/smixer/smixer-hda.so
287 %attr(755,root,root) %{_libdir}/alsa-lib/smixer/smixer-sbase.so
288 %dir %{_datadir}/alsa
289 %{_datadir}/alsa/cards
290 %{_datadir}/alsa/pcm
291 %{_datadir}/alsa/topology
292 %{_datadir}/alsa/ucm
293 %{_datadir}/alsa/ucm2
294 %{_datadir}/alsa/alsa.conf
295 # directory for "global" config files (not accessed directly, but through symlinks in %{_sysconfdir}/alsa/conf.d)
296 %dir %{_datadir}/alsa/alsa.conf.d
297 %{_datadir}/alsa/smixer.conf
298 %dir %{_sysconfdir}/alsa
299 # directory for "local" config files (loaded from %{_datadir}/alsa/alsa.conf)
300 %dir %{_sysconfdir}/alsa/conf.d
301 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/asound.conf
302 %config(noreplace) %verify(not md5 mtime size) /etc/modprobe.d/alsa-base.conf
303
304 %files devel
305 %defattr(644,root,root,755)
306 %attr(755,root,root) %{_libdir}/libasound.so
307 %attr(755,root,root) %{_libdir}/libatopology.so
308 %{_libdir}/libasound.la
309 %{_libdir}/libatopology.la
310 %{_includedir}/sys/asoundlib.h
311 %{_includedir}/alsa
312 %{_includedir}/asoundlib.h
313 %{_aclocaldir}/alsa.m4
314 %{_pkgconfigdir}/alsa.pc
315 %{_pkgconfigdir}/alsa-topology.pc
316
317 %if %{with static_libs}
318 %files static
319 %defattr(644,root,root,755)
320 %{_libdir}/libasound.a
321 %endif
322
323 %if %{with apidocs}
324 %files apidocs
325 %defattr(644,root,root,755)
326 %doc build-shared/doc/doxygen/html/*
327 %endif
328
329 %if %{with python}
330 %files smixer-python
331 %defattr(644,root,root,755)
332 %attr(755,root,root) %{_libdir}/alsa-lib/smixer/smixer-python.so
333 %endif
This page took 0.085416 seconds and 4 git commands to generate.