]> git.pld-linux.org Git - packages/SDL2.git/blame - SDL2.spec
- new, based on SDL
[packages/SDL2.git] / SDL2.spec
CommitLineData
916aeb96
JB
1#
2# Conditional build:
3%bcond_with directfb # DirectFB graphics support
4%bcond_with nas # NAS audio support
5%bcond_without alsa # ALSA audio support
6%bcond_with arts # aRts audio support
7%bcond_with esd # EsounD audio support
8%bcond_without gl # OpenGL (GLX) support
9%bcond_without gles # OpenGL ES (EGL) support
10%bcond_without static_libs # don't build static libraries
11%bcond_with mmx # MMX instructions
12%bcond_with sse # SSE instructions
13%bcond_with sse2 # SSE2 instructions
14%bcond_with 3dnow # 3Dnow! instructions
15%bcond_with altivec # Altivec instructions
16#
17# NOTE: the following libraries are dlopened by soname detected at build time:
18# libartsc.so.? [if with arts]
19# libasound.so.2 [if with alsa]
20# libaudio.so.2 [if with nas]
21# libdirectfb-*.so --needs patch (-release not supported by configure)
22# libesd.so.0 [if with esd]
23# libfusionsound-*.so --needs patch (-release not supported by configure)
24# libpulse-simple.so.0
25# libX11.so.6
26# libXcursor.so.1
27# libXext.so.6
28# libXi.so.6
29# libXinerama.so.1
30# libXrandr.so.2
31# libXrender.so.1
32# libXss.so.1
33# libXxf86vm.so.1
34%ifarch k6 athlon
35%define with_3dnow 1
36%endif
37%ifarch %{x8664} pentium2 pentium3 pentium4 athlon
38%define with_mmx 1
39%endif
40%ifarch %{x8664} pentium3 pentium4
41%define with_sse 1
42%endif
43%ifarch %{x8664} pentium4
44%define with_sse2 1
45%endif
46Summary: SDL (Simple DirectMedia Layer) - Game/Multimedia Library
47Summary(pl.UTF-8): SDL (Simple DirectMedia Layer) - Biblioteka do gier/multimediów
48Summary(zh_CN.UTF-8): SDL (Simple DirectMedia Layer) Generic APIs - 游戏/多媒体库
49Name: SDL2
50Version: 2.0.0
51Release: 1
52License: Zlib (BSD-like)
53Group: Libraries
54Source0: http://www.libsdl.org/release/%{name}-%{version}.tar.gz
55# Source0-md5: beec89afb6edcc6f0abc4114f2e6bcf7
56Patch0: %{name}-config.patch
57URL: http://www.libsdl.org/
58%{?with_directfb:BuildRequires: DirectFB-devel >= 1.0.0}
59%{?with_directfb:BuildRequires: FusionSound-devel >= 1.1.1}
60%{?with_gl:BuildRequires: OpenGL-GLX-devel}
61%{?with_gles:BuildRequires: OpenGLES-devel}
62%{?with_alsa:BuildRequires: alsa-lib-devel >= 0.9.0}
63%{?with_arts:BuildRequires: artsc-devel >= 1.1}
64BuildRequires: autoconf >= 2.59-9
65BuildRequires: automake
66BuildRequires: dbus-devel
67%{?with_esd:BuildRequires: esound-devel >= 0.2.8}
68BuildRequires: gcc >= 5:4.0
69BuildRequires: libtool >= 2:2.0
70%{?with_nas:BuildRequires: nas-devel}
71BuildRequires: perl-modules
72BuildRequires: pkgconfig >= 1:0.7
73BuildRequires: pulseaudio-devel >= 0.9
74BuildRequires: tslib-devel
75BuildRequires: udev-devel
76BuildRequires: xorg-lib-libX11-devel
77BuildRequires: xorg-lib-libXScrnSaver-devel
78BuildRequires: xorg-lib-libXcursor-devel
79BuildRequires: xorg-lib-libXext-devel
80BuildRequires: xorg-lib-libXi-devel
81BuildRequires: xorg-lib-libXinerama-devel
82BuildRequires: xorg-lib-libXrandr-devel
83BuildRequires: xorg-lib-libXrender-devel
84BuildRequires: xorg-lib-libXxf86vm-devel
85BuildRequires: xorg-proto-xextproto-devel
86BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
87
88%define specflags_ppc -maltivec
89
90%description
91SDL (Simple DirectMedia Layer) is a library that allows you portable,
92low level access to a video framebuffer, audio output, mouse, and
93keyboard. It can support both windowed and DGA modes of XFree86, and
94it is designed to be portable - applications linked with SDL can also
95be built on Win32 and BeOS.
96
97%description -l pl.UTF-8
98SDL (Simple DirectMedia Layer) jest biblioteką udostępniającą
99przenośny, niskopoziomowy dostęp do bufora ramki video, wyjścia audio,
100myszy oraz klawiatury. Może obsługiwać zarówno okienkowy tryb XFree86
101jak i DGA. Konstruując ją miano na uwadze przenośność: aplikacje
102konsolidowane z SDL można również budować w systemach Win32 i BeOS.
103
104%description -l pt_BR.UTF-8
105Esse é o Simple DirectMedia Layer, uma API genérica que dá acesso de
106baixo nível a áudio, teclado, mouse e vídeo em várias plataformas.
107
108Essa biblioteca é usada por alguns jogos.
109
110%description -l ru.UTF-8
111SDL (Simple DirectMedia Layer) это набор функций, предоставляющий
112низкоуровневый доступ к звуку, клавиатуре, манипулятору мышь и к
113буферу экрана на множестве различных платформ.
114
115%package devel
116Summary: SDL - Header files
117Summary(pl.UTF-8): SDL - Pliki nagłówkowe
118Summary(pt_BR.UTF-8): Bibliotecas e arquivos de cabeçalho para aplicações SDL
119Summary(ru.UTF-8): Файлы, необходимые для разработки программ, использующих SDL
120Summary(uk.UTF-8): Файли, необхідні для розробки програм, що використовують SDL
121Summary(zh_CN.UTF-8): SDL (Simple DirectMedia Layer) 开发库
122Group: Development/Libraries
123Requires: %{name} = %{version}-%{release}
124%{?with_directfb:Requires: DirectFB-devel >= 1.0.0}
125Requires: tslib-devel
126Requires: xorg-lib-libX11-devel
127Suggests: OpenGL-GLU-devel
128
129%description devel
130SDL - Header files.
131
132%description devel -l pl.UTF-8
133SDL - Pliki nagłówkowe.
134
135%description devel -l pt_BR.UTF-8
136Esse pacote contém bibliotecas, arquivos de cabeçalho e outros
137recursos para o desenvolvimento de aplicativos com SDL.
138
139%description devel -l ru.UTF-8
140Этот пакет содержит файлы, необходимые для разработки программ,
141использующих SDL.
142
143%description devel -l uk.UTF-8
144Цей пакет містить файли, необхідні для розробки програм, що
145використовують SDL.
146
147%package static
148Summary: SDL - static libraries
149Summary(pl.UTF-8): SDL - biblioteki statyczne
150Summary(pt_BR.UTF-8): Biblioteca estática para desenvolvimento de aplicações com a SDL
151Summary(ru.UTF-8): Статические библиотеки для разработки с использованием SDL
152Summary(uk.UTF-8): Статичні бібліотеки для розробки з використанням SDL
153Group: Development/Libraries
154Requires: %{name}-devel = %{version}-%{release}
155
156%description static
157SDL - static libraries.
158
159%description static -l pl.UTF-8
160SDL - biblioteki statyczne.
161
162%description static -l pt_BR.UTF-8
163Biblioteca estática para desenvolvimento de aplicações com a SDL.
164
165%description static -l ru.UTF-8
166Этот пакет содержит статические библиотеки для разработки программ,
167использующих SDL.
168
169%description static -l uk.UTF-8
170Цей пакет містить статичні бібліотеки для розробки програм, що
171використовують SDL.
172
173%package examples
174Summary: SDL - example programs
175Summary(pl.UTF-8): SDL - programy przykładowe
176License: Public Domain
177Group: Development/Libraries
178Requires: %{name}-devel = %{version}-%{release}
179
180%description examples
181SDL - example programs.
182
183%description examples -l pl.UTF-8
184SDL - przykładowe programy.
185
186%prep
187%setup -q
188%patch0 -p1
189
190%build
191%{__libtoolize}
192%{__aclocal} -I acinclude
193%{__autoconf}
194%configure \
195 %{!?with_3dnow:--disable-3dnow} \
196 %{!?with_alsa:--disable-alsa} \
197 %{!?with_altiveca:--disable-altivec} \
198 %{!?with_arts:--disable-arts} \
199 %{!?with_esd:--disable-esd} \
200 %{!?with_mmx:--disable-mmx} \
201 %{!?with_nas:--disable-nas} \
202 --enable-pthreads \
203 --enable-pthread-sem \
204 --disable-rpath \
205 %{!?with_sse:--disable-sse --disable-ssemath} \
206 %{!?with_sse2:--disable-sse2} \
207 %{?with_sse:--enable-ssemath} \
208 %{!?with_static_libs:--disable-static} \
209 %{!?with_directfb:--disable-video-directfb} \
210 --enable-video-opengl%{!?with_opengl:=no} \
211 --enable-video-opengles%{!?with_gles:=no} \
212 --with-x
213
214%{__make}
215
216%install
217rm -rf $RPM_BUILD_ROOT
218install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
219
220%{__make} install \
221 DESTDIR=$RPM_BUILD_ROOT \
222 m4datadir=%{_aclocaldir}
223
224cp -pr test/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
225
226%clean
227rm -rf $RPM_BUILD_ROOT
228
229%post -p /sbin/ldconfig
230%postun -p /sbin/ldconfig
231
232%files
233%defattr(644,root,root,755)
234# non-Linux READMEs packaged for portability information
235%doc BUGS.txt COPYING.txt CREDITS.txt README*.txt TODO.txt WhatsNew.txt
236%attr(755,root,root) %{_libdir}/libSDL2-2.0.so.*.*.*
237%attr(755,root,root) %ghost %{_libdir}/libSDL2-2.0.so.0
238
239%files devel
240%defattr(644,root,root,755)
241%attr(755,root,root) %{_bindir}/sdl2-config
242%attr(755,root,root) %{_libdir}/libSDL2.so
243%{_libdir}/libSDL2.la
244%{_libdir}/libSDL2_test.a
245%{_libdir}/libSDL2main.a
246%{_includedir}/SDL2
247%{_aclocaldir}/sdl2.m4
248%{_pkgconfigdir}/sdl2.pc
249
250%if %{with static_libs}
251%files static
252%defattr(644,root,root,755)
253%{_libdir}/libSDL2.a
254%endif
255
256%files examples
257%defattr(644,root,root,755)
258%{_examplesdir}/%{name}-%{version}
This page took 0.114048 seconds and 4 git commands to generate.