]> git.pld-linux.org Git - packages/OpenAL.git/blob - OpenAL.spec
BR: libmysofa-devel
[packages/OpenAL.git] / OpenAL.spec
1 #
2 # Conditional build:
3 %bcond_without  alsa            # ALSA backend
4 %bcond_without  jack            # JACK backend
5 %bcond_without  portaudio       # PortAudio backend
6 %bcond_without  pulseaudio      # PulseAudio backend
7 %bcond_with     sdl             # SDL2 backend
8 %bcond_with     sse             # force use of SSE instructions (x86)
9 %bcond_with     sse2            # force use of SSE2 instructions (x86)
10 %bcond_without  gui             # alsoft-config GUI
11 %bcond_with     qt4             # Qt 4 instead of Qt 5 for GUI
12 #
13 %ifarch pentium3 pentium4
14 %define with_sse        1
15 %endif
16 %ifarch pentium4
17 %define with_sse2       1
18 %endif
19 Summary:        Open Audio Library
20 Summary(pl.UTF-8):      Otwarta Biblioteka Dźwięku
21 Name:           OpenAL
22 Version:        1.20.0
23 Release:        1
24 License:        LGPL v2+
25 Group:          Libraries
26 Source0:        http://openal-soft.org/openal-releases/openal-soft-%{version}.tar.bz2
27 # Source0-md5:  f6349071db03e48994ea09daa031ef6e
28 Patch0:         %{name}-pc.patch
29 URL:            http://www.openal.org/
30 %{?with_sdl:BuildRequires:      SDL2-devel >= 2}
31 %{?with_alsa:BuildRequires:     alsa-lib-devel}
32 BuildRequires:  cmake >= 3.0.2
33 %{?with_jack:BuildRequires:     jack-audio-connection-kit-devel}
34 BuildRequires:  libmysofa-devel
35 BuildRequires:  libstdc++-devel >= 6:4.8.1
36 BuildRequires:  pkgconfig
37 %{?with_portaudio:BuildRequires:        portaudio-devel}
38 %{?with_pulseaudio:BuildRequires:       pulseaudio-devel}
39 BuildRequires:  rpmbuild(macros) >= 1.605
40 %if %{with gui}
41 %if %{with qt4}
42 BuildRequires:  QtCore-devel >= 4.8.0
43 BuildRequires:  QtGui-devel >= 4.8.0
44 BuildRequires:  qt4-build >= 4.8.0
45 %else
46 BuildRequires:  Qt5Core-devel >= 5
47 BuildRequires:  Qt5Gui-devel >= 5
48 BuildRequires:  Qt5Widgets-devel >= 5
49 BuildRequires:  qt5-build >= 5
50 %endif
51 %endif
52 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
53
54 %description
55 OpenAL, the Open Audio Library, is a joint effort to create an open,
56 vendor-neutral, cross-platform API for interactive, primarily
57 spatialized audio. OpenAL's primary audience are application
58 developers and desktop users that rely on portable standards like
59 OpenGL, for games and other multimedia applications. OpenAL is already
60 supported by a number of hardware vendors and developers.
61
62 %description -l pl.UTF-8
63 OpenAL, otwarta biblioteka dźwięku, to połączony wysiłek w celu
64 stworzenia otwartego, niezależnego od producentów, międzyplatformowego
65 interfejsu projektowania aplikacji w części obsługi dźwięku.
66 Biblioteka adresowana jest do twórców aplikacji i użytkowników,
67 którzy wybierają przenośne standardy, jak OpenGL, w grach i
68 aplikacjach multimedialnych. OpenAL posiada już wsparcie wielu
69 dostarczycieli sprzętu i programistów.
70
71 %package devel
72 Summary:        Headers for OpenAL
73 Summary(pl.UTF-8):      Pliki nagłówkowe do OpenAL
74 Group:          Development/Libraries
75 Requires:       %{name} = %{version}-%{release}
76
77 %description devel
78 Header files for OpenAL-based programs.
79
80 %description devel -l pl.UTF-8
81 Pliki nagłówkowe potrzebne przy budowaniu programów opartych na
82 OpenAL.
83
84 %package gui
85 Summary:        OpenAL configuration GUI
86 Summary(pl.UTF-8):      Graficzny interfejs do konfiguracji biblioteki OpenAL
87 Group:          X11/Applications/Sound
88 Requires:       %{name} = %{version}-%{release}
89 Requires:       QtCore >= 4.8.0
90 Requires:       QtGui >= 4.8.0
91
92 %description gui
93 OpenAL configuration GUI.
94
95 %description gui -l pl.UTF-8
96 Graficzny interfejs do konfiguracji biblioteki OpenAL.
97
98 %prep
99 %setup -q -n openal-soft-%{version}
100 %patch0 -p1
101
102 %build
103 cd build
104 %cmake .. \
105         %{!?with_alsa:-DALSOFT_BACKEND_ALSA=OFF} \
106         %{!?with_jack:-DALSOFT_BACKEND_JACK=OFF} \
107         %{!?with_portaudio:-DALSOFT_BACKEND_PORTAUDIO=OFF} \
108         %{!?with_pulseaudio:-DALSOFT_BACKEND_PULSEAUDIO=OFF} \
109         %{?with_sdl:-DALSOFT_BACKEND_SDL2=ON} \
110         %{!?with_sse:-DALSOFT_CPUEXT_SSE=OFF} \
111         %{!?with_sse2:-DALSOFT_CPUEXT_SSE2=OFF} \
112         -DALSOFT_EXAMPLES=OFF \
113         %{!?with_gui:-DALSOFT_NO_CONFIG_UTIL=ON} \
114         %{?with_qt4:-DALSOFT_NO_QT5=ON} \
115
116 %{__make}
117
118 %install
119 rm -rf $RPM_BUILD_ROOT
120 install -d $RPM_BUILD_ROOT%{_sysconfdir}/openal
121
122 %{__make} -C build install \
123         DESTDIR=$RPM_BUILD_ROOT
124
125 install -p alsoftrc.sample $RPM_BUILD_ROOT%{_sysconfdir}/openal/alsoft.conf
126
127 # these look not really useful
128 %{__rm} $RPM_BUILD_ROOT%{_bindir}/altonegen
129
130 %clean
131 rm -rf $RPM_BUILD_ROOT
132
133 %post   -p /sbin/ldconfig
134 %postun -p /sbin/ldconfig
135
136 %files
137 %defattr(644,root,root,755)
138 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/openal
139 %attr(755,root,root) %{_bindir}/makemhr
140 %attr(755,root,root) %{_bindir}/openal-info
141 %attr(755,root,root) %{_libdir}/libopenal.so.*.*.*
142 %attr(755,root,root) %ghost %{_libdir}/libopenal.so.1
143 %{_datadir}/openal
144
145 %files devel
146 %defattr(644,root,root,755)
147 %attr(755,root,root) %{_libdir}/libopenal.so
148 %{_includedir}/AL
149 %{_pkgconfigdir}/openal.pc
150 %{_libdir}/cmake/OpenAL
151
152 %if %{with gui}
153 %files gui
154 %defattr(644,root,root,755)
155 %attr(755,root,root) %{_bindir}/alsoft-config
156 %endif
This page took 0.079793 seconds and 3 git commands to generate.