1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
|
Summary: C++ library for easy access to ALSA PCM devices
Name: zita-alsa-pcmi
Version: 0.2.0
Release: 1
License: GPL v3+
Group: Libraries
Source0: http://kokkinizita.linuxaudio.org/linuxaudio/downloads/%{name}-%{version}.tar.bz2
# Source0-md5: 0ba4d59abce231056e2628d081124114
Patch0: makefile.patch
URL: http://kokkinizita.linuxaudio.org/linuxaudio/
BuildRequires: alsa-lib-devel
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
Zita-alsa-pcmi is the successor of clalsadrv. It provides easy access
to ALSA PCM devices, taking care of the many functions required to
open, initialise and use a hw: device in mmap mode, and providing
floating point audio data.
%package devel
Summary: Header files for %{name} library
Summary(pl.UTF-8): Pliki nagłówkowe biblioteki %{name}
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
%description devel
Header files for %{name} library.
%description devel -l pl.UTF-8
Pliki nagłówkowe biblioteki %{name}.
%package apps
Summary: Sample applications files for %{name} library
Summary(pl.UTF-8): Przykładowe aplikacje biblioteki %{name}
Group: Applications/Sound
Requires: %{name} = %{version}-%{release}
%description apps
Sample applications files for %{name} library.
%description devel -l pl.UTF-8
Przykładowe aplikacje biblioteki %{name}.
%prep
%setup -q
%patch0 -p1
%build
cd libs
CXX="%{__cxx}" \
CXXFLAGS="%{rpmcxxflags}" \
CPPFLAGS="%{rpmcppflags}" \
LDFLAGS="%{rpmldflags}" \
%{__make}
ln -sf libzita-alsa-pcmi.so.* libzita-alsa-pcmi.so
cd ..
cd apps
CXX="%{__cxx}" \
CXXFLAGS="%{rpmcxxflags}" \
CPPFLAGS="%{rpmcppflags} -I../libs" \
LDFLAGS="%{rpmldflags} -L../libs" \
%{__make}
cd ..
%install
rm -rf $RPM_BUILD_ROOT
%{__make} -C libs install \
DESTDIR=$RPM_BUILD_ROOT \
PREFIX=%{_prefix} \
LIBDIR=%{_lib}
%{__make} -C apps install \
DESTDIR=$RPM_BUILD_ROOT \
PREFIX=%{_prefix}
%clean
rm -rf $RPM_BUILD_ROOT
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(644,root,root,755)
%doc AUTHORS README
%attr(755,root,root) %{_libdir}/lib%{name}.so.*.*.*
%attr(755,root,root) %ghost %{_libdir}/lib%{name}.so.0
%files devel
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/lib%{name}.so
%{_includedir}/%{name}.h
%files apps
%defattr(644,root,root,755)
%attr(755,root,root) %{_bindir}/alsa_delay
%attr(755,root,root) %{_bindir}/alsa_loopback
|