3 %bcond_without static_libs # static library
5 Summary: Simple DirectMedia Layer 2 - ttf handling
6 Summary(pl.UTF-8): Biblioteka obsługi fontów TTF dla SDL2
7 Summary(pt_BR.UTF-8): Simple DirectMedia Layer 2 - Biblioteca de fontes TrueType
13 Source0: https://github.com/libsdl-org/SDL_ttf/releases/download/release-%{version}/SDL2_ttf-%{version}.tar.gz
14 # Source0-md5: 686e685caaa215d8fa1ac7bb02b2cf54
15 URL: https://github.com/libsdl-org/SDL_ttf
16 BuildRequires: OpenGL-devel
17 BuildRequires: SDL2-devel >= 2.0.10
18 BuildRequires: autoconf >= 2.63
19 BuildRequires: automake >= 1:1.16
20 BuildRequires: freetype-devel >= 2.1.4
21 BuildRequires: harfbuzz-devel >= 2.3.1
22 BuildRequires: libstdc++-devel >= 6:4.8.1
23 BuildRequires: libtool >= 2:2.0
24 BuildRequires: pkgconfig >= 1:0.9.0
25 BuildRequires: rpmbuild(macros) >= 1.527
26 Requires: SDL2 >= 2.0.10
27 Requires: freetype >= 2.1.4
28 Requires: harfbuzz >= 2.3.1
29 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32 This is a sample library which allows you to use TrueType fonts in
33 your SDL2 applications. It comes with an example program "sdl2font"
34 which displays an example string for a given TrueType font file.
36 %description -l pl.UTF-8
37 Przykładowa biblioteka do obsługi fontów TrueType w aplikacjach SDL2.
38 Pakiet zawiera przykładowy program "sdl2font", wyświetlający
39 przykładowy ciąg znaków zadanym fontem TrueType.
41 %description -l pt_BR.UTF-8
42 Esta é uma biblioteca que permite a utilização de fontes TrueType em
43 suas aplicações SDL2. Ela vem com o programa exemplo "sdl2font" que
44 mostra uma string exemplo para uma fonte TrueType fornecida.
47 Summary: Header files and more to develop SDL2_ttf applications
48 Summary(pl.UTF-8): Pliki nagłówkowe do rozwijania aplikacji używających SDL2_ttf
49 Summary(pt_BR.UTF-8): Cabeçalhos para desenvolver programas utilizando a SDL2_ttf
50 Group: Development/Libraries
51 Requires: %{name} = %{version}-%{release}
52 Requires: SDL2-devel >= 2.0.8
53 Requires: freetype-devel >= 2.1.4
56 Header files and more to develop SDL2_ttf applications.
58 %description devel -l pl.UTF-8
59 Pliki nagłówkowe do rozwijania aplikacji używających SDL2_ttf.
61 %description devel -l pt_BR.UTF-8
62 Este pacote contém os cabeçalhos que programadores vão precisar para
63 desenvolver aplicações utilizando a SDL2_ttf.
66 Summary: Static SDL2_ttf library
67 Summary(pl.UTF-8): Biblioteka statyczna SDL2_ttf
68 Summary(pt_BR.UTF-8): Biblioteca estática para desenvolvimento utilizando a SDL2_ttf
69 Group: Development/Libraries
70 Requires: %{name}-devel = %{version}-%{release}
73 Static SDL2_ttf library.
75 %description static -l pl.UTF-8
76 Biblioteka statyczna SDL2_ttf.
78 %description static -l pt_BR.UTF-8
79 Este pacote contém a biblioteca estática que programadores vão
80 precisar para desenvolver aplicações linkados estaticamente com a
86 %{__rm} -r external/{freetype,harfbuzz}
94 %{__enable_disable static_libs static} \
95 --disable-freetype-builtin \
96 --disable-harfbuzz-builtin
101 rm -rf $RPM_BUILD_ROOT
102 install -d $RPM_BUILD_ROOT%{_bindir}
105 DESTDIR=$RPM_BUILD_ROOT
107 install .libs/showfont $RPM_BUILD_ROOT%{_bindir}/sdl2font
109 # obsoleted by pkg-config
110 %{__rm} $RPM_BUILD_ROOT%{_libdir}/lib*.la
113 rm -rf $RPM_BUILD_ROOT
115 %post -p /sbin/ldconfig
116 %postun -p /sbin/ldconfig
119 %defattr(644,root,root,755)
120 %doc CHANGES.txt LICENSE.txt README.txt
121 %attr(755,root,root) %{_bindir}/sdl2font
122 %attr(755,root,root) %{_libdir}/libSDL2_ttf-2.0.so.*.*.*
123 %attr(755,root,root) %ghost %{_libdir}/libSDL2_ttf-2.0.so.0
126 %defattr(644,root,root,755)
127 %attr(755,root,root) %{_libdir}/libSDL2_ttf.so
128 %{_libdir}/cmake/SDL2_ttf
129 %{_includedir}/SDL2/SDL_ttf.h
130 %{_pkgconfigdir}/SDL2_ttf.pc
132 %if %{with static_libs}
134 %defattr(644,root,root,755)
135 %{_libdir}/libSDL2_ttf.a