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