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