]>
Commit | Line | Data |
---|---|---|
9e7e30d2 | 1 | %define realname SDL |
f29e2a06 JB |
2 | Summary: SDL (Simple DirectMedia Layer) - Game/Multimedia Library - MinGW32 cross version |
3 | Summary(pl.UTF-8): SDL (Simple DirectMedia Layer) - Biblioteka do gier/multimediów - wersja skrośna dla MinGW32 | |
9e7e30d2 | 4 | Name: crossmingw32-%{realname} |
acf5bdea | 5 | Version: 1.2.15 |
9e60ba3f | 6 | Release: 2 |
e608a184 | 7 | License: LGPL v2.1+ |
cfa7fe44 | 8 | Group: Libraries |
b53f7a3a | 9 | Source0: http://www.libsdl.org/release/%{realname}-%{version}.tar.gz |
acf5bdea JB |
10 | # Source0-md5: 9d96df8417572a2afb781a7c4c811a85 |
11 | Patch0: %{realname}-acfix.patch | |
9e7e30d2 | 12 | URL: http://www.libsdl.org/ |
acf5bdea | 13 | BuildRequires: autoconf >= 2.59-9 |
9e7e30d2 | 14 | BuildRequires: automake |
15 | BuildRequires: crossmingw32-gcc | |
e34dc44c | 16 | BuildRequires: crossmingw32-runtime |
ee573ed1 | 17 | BuildRequires: crossmingw32-w32api |
8b1b6f3a | 18 | BuildRequires: crossmingw32-w32api-dx |
6b62e051 | 19 | BuildRequires: libtool >= 2:2.0 |
9e7e30d2 | 20 | BuildRequires: nasm |
9e7e30d2 | 21 | BuildRequires: perl-modules |
5ea84172 JB |
22 | BuildConflicts: crossmingw32-dx70 |
23 | Requires: crossmingw32-runtime | |
9e7e30d2 | 24 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
25 | ||
26 | %define no_install_post_strip 1 | |
27 | ||
7cc0fac6 JB |
28 | %define target i386-mingw32 |
29 | %define target_platform i386-pc-mingw32 | |
9e7e30d2 | 30 | |
7cc0fac6 JB |
31 | %define _sysprefix /usr |
32 | %define _prefix %{_sysprefix}/%{target} | |
36f6a32f | 33 | %define _libdir %{_prefix}/lib |
86d3f3b6 | 34 | %define _pkgconfigdir %{_prefix}/lib/pkgconfig |
7cc0fac6 JB |
35 | %define _dlldir /usr/share/wine/windows/system |
36 | %define __cc %{target}-gcc | |
37 | %define __cxx %{target}-g++ | |
9e60ba3f | 38 | %define __pkgconfig_provides %{nil} |
9e7e30d2 | 39 | |
6b62e051 JB |
40 | %ifnarch %{ix86} |
41 | # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc | |
24a16a4a JB |
42 | %define optflags -O2 |
43 | %endif | |
6b62e051 JB |
44 | # -z options are invalid for mingw linker |
45 | %define filterout_ld -Wl,-z,.* | |
24a16a4a | 46 | |
9e7e30d2 | 47 | %description |
48 | SDL (Simple DirectMedia Layer) is a library that allows you portable, | |
49 | low level access to a video framebuffer, audio output, mouse, and | |
50 | keyboard. It can support both windowed and DGA modes of XFree86, and | |
51 | it is designed to be portable - applications linked with SDL can also | |
52 | be built on Win32 and BeOS. | |
53 | ||
7cc0fac6 JB |
54 | This package contains the cross version for Win32. |
55 | ||
1b084377 JR |
56 | %description -l pl.UTF-8 |
57 | SDL (Simple DirectMedia Layer) jest biblioteką udostępniającą | |
58 | przenośny, niskopoziomowy dostęp do bufora ramki video, wyjścia audio, | |
59 | myszy oraz klawiatury. Może obsługiwać zarówno okienkowy tryb XFree86 | |
60 | jak i DGA. Konstruując ją miano na uwadze przenośność: aplikacje | |
61 | konsolidowane z SDL można również budować w systemach Win32 i BeOS. | |
9e7e30d2 | 62 | |
7cc0fac6 JB |
63 | Ten pakiet zawiera wersję skrośną dla Win32. |
64 | ||
1b084377 JR |
65 | %description -l pt_BR.UTF-8 |
66 | Esse é o Simple DirectMedia Layer, uma API genérica que dá acesso de | |
67 | baixo nível a áudio, teclado, mouse e vídeo em várias plataformas. | |
9e7e30d2 | 68 | |
1b084377 | 69 | Essa biblioteca é usada por alguns jogos. |
9e7e30d2 | 70 | |
7cc0fac6 | 71 | %package static |
f29e2a06 JB |
72 | Summary: Static SDL library (cross MinGW32 version) |
73 | Summary(pl.UTF-8): Statyczna biblioteka SDL (wersja skrośna MinGW32) | |
7cc0fac6 JB |
74 | Group: Development/Libraries |
75 | Requires: %{name} = %{version}-%{release} | |
76 | ||
77 | %description static | |
f29e2a06 | 78 | Static SDL library (cross MinGW32 version). |
7cc0fac6 JB |
79 | |
80 | %description static -l pl.UTF-8 | |
f29e2a06 | 81 | Statyczna biblioteka SDL (wersja skrośna MinGW32). |
7cc0fac6 | 82 | |
8b1b6f3a | 83 | %package dll |
84 | Summary: SDL - DLL library for Windows | |
d736829d | 85 | Summary(pl.UTF-8): SDL - biblioteka DLL dla Windows |
8b1b6f3a | 86 | Group: Applications/Emulators |
87 | ||
88 | %description dll | |
89 | SDL - DLL library for Windows. | |
90 | ||
1b084377 | 91 | %description dll -l pl.UTF-8 |
8b1b6f3a | 92 | SDL - biblioteka DLL dla Windows. |
9e7e30d2 | 93 | |
94 | %prep | |
b53f7a3a | 95 | %setup -q -n %{realname}-%{version} |
9e7e30d2 | 96 | %patch0 -p1 |
9e7e30d2 | 97 | |
00c1e1dc JR |
98 | : > acinclude.m4 |
99 | echo 'AC_DEFUN([AM_PATH_ESD],[$3])' >> acinclude.m4 | |
100 | ||
9e7e30d2 | 101 | %build |
7cc0fac6 JB |
102 | %{__libtoolize} |
103 | %{__aclocal} | |
104 | %{__autoconf} | |
9e7e30d2 | 105 | %configure \ |
106 | --target=%{target} \ | |
107 | --host=%{target} \ | |
9e7e30d2 | 108 | --enable-nasm \ |
8b1b6f3a | 109 | --disable-stdio-redirect |
9e7e30d2 | 110 | |
111 | %{__make} | |
112 | ||
9e7e30d2 | 113 | %install |
114 | rm -rf $RPM_BUILD_ROOT | |
9e7e30d2 | 115 | |
7cc0fac6 JB |
116 | %{__make} install \ |
117 | DESTDIR=$RPM_BUILD_ROOT | |
9e7e30d2 | 118 | |
7cc0fac6 JB |
119 | install -d $RPM_BUILD_ROOT{%{_dlldir},%{_sysprefix}/bin} |
120 | mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir} | |
121 | ln -s %{_bindir}/sdl-config $RPM_BUILD_ROOT%{_sysprefix}/bin/%{target}-sdl-config | |
122 | ||
123 | %if 0%{!?debug:1} | |
124 | %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll | |
125 | %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a | |
126 | %endif | |
127 | ||
128 | rm -rf $RPM_BUILD_ROOT%{_datadir}/{aclocal,man} | |
9e7e30d2 | 129 | |
130 | %clean | |
131 | rm -rf $RPM_BUILD_ROOT | |
132 | ||
133 | %files | |
134 | %defattr(644,root,root,755) | |
7cc0fac6 JB |
135 | %doc BUGS CREDITS README README-SDL.txt TODO WhatsNew |
136 | %attr(755,root,root) %{_sysprefix}/bin/%{target}-sdl-config | |
137 | %attr(755,root,root) %{_bindir}/sdl-config | |
138 | %{_libdir}/libSDL.dll.a | |
139 | %{_libdir}/libSDL.la | |
140 | %{_libdir}/libSDLmain.a | |
141 | %{_includedir}/SDL | |
142 | %{_pkgconfigdir}/sdl.pc | |
143 | ||
144 | %files static | |
145 | %defattr(644,root,root,755) | |
146 | %{_libdir}/libSDL.a | |
8b1b6f3a | 147 | |
148 | %files dll | |
149 | %defattr(644,root,root,755) | |
4e42d656 | 150 | %{_dlldir}/libSDL-1-2-0.dll |