]>
Commit | Line | Data |
---|---|---|
0fe9ae1e | 1 | # |
f50b7aa0 | 2 | # Conditional build: |
2d7c1ea5 JB |
3 | %bcond_without fontconfig # without fontconfig support |
4 | %bcond_without xpm # without XPM support (requires X11 libs) | |
0fe9ae1e | 5 | # |
a8cb6661 | 6 | Summary: Library for PNG, JPEG creation |
276f8082 ER |
7 | Summary(es.UTF-8): Biblioteca para manipulación de imágenes |
8 | Summary(pl.UTF-8): Biblioteka do tworzenia grafiki w formacie PNG, JPEG | |
9 | Summary(pt_BR.UTF-8): Biblioteca para manipulação de imagens | |
bf525458 | 10 | Name: gd |
e2fa0ae5 | 11 | Version: 2.0.35 |
4c5e5b22 | 12 | Release: 11 |
f5fd6f82 | 13 | License: BSD-like |
bf525458 | 14 | Group: Libraries |
41392427 AG |
15 | Source0: http://www.libgd.org/releases/%{name}-%{version}.tar.bz2 |
16 | # Source0-md5: 6c6c3dbb7bf079e0bb5fbbfd3bb8a71c | |
f0e7dffb | 17 | Patch0: %{name}-fontpath.patch |
e2fa0ae5 | 18 | Patch1: %{name}-rotate_from_php.patch |
0f4482da AM |
19 | Patch2: %{name}-2.0.33-BoxBound.patch |
20 | Patch3: %{name}-2.0.35-AALineThick.patch | |
21 | Patch4: %{name}-2.0.35-overflow.patch | |
22 | Patch5: %{name}-2.0.35-security3.patch | |
23 | Patch6: %{name}-loop.patch | |
4c5e5b22 | 24 | Patch7: format-security.patch |
e2fa0ae5 | 25 | URL: http://www.libgd.org/ |
91cfdb36 | 26 | BuildRequires: autoconf >= 2.54 |
b2f653fd | 27 | BuildRequires: automake |
2d7c1ea5 | 28 | %{?with_fontconfig:BuildRequires: fontconfig-devel} |
96d1fc3c | 29 | BuildRequires: freetype-devel >= 2.0 |
b099b9cd | 30 | BuildRequires: gettext-devel |
c0a00bcf | 31 | BuildRequires: libjpeg-devel |
0f4482da | 32 | BuildRequires: libpng-devel >= 2:1.4.0 |
2aa7d3df | 33 | BuildRequires: libtiff-devel |
6e5b17d6 | 34 | BuildRequires: libtool >= 1:1.4.3 |
ab0e31ee | 35 | %{?with_xpm:BuildRequires: xorg-lib-libXpm-devel} |
96d1fc3c | 36 | BuildRequires: zlib-devel |
f0e7dffb | 37 | Provides: gd(gif) = %{version}-%{release} |
04a4831a JB |
38 | # versioned by php version rotate_from_php code comes from |
39 | Provides: gd(imagerotate) = 5.2.0 | |
60d61c9a | 40 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
64f72052 | 41 | |
cb954d5c | 42 | %description |
0fe9ae1e JB |
43 | gd is the image manipulating library. It was created to allow graphs, |
44 | charts and the like to be generated on the fly for use on the World | |
45 | wide Web, but is useful for any application in which custom images are | |
46 | useful. It is not a paint program; it is a library. gd library creates | |
f0e7dffb JB |
47 | PNG, JPEG, GIF and WBMP images. PNG is a more compact format, and full |
48 | compression is available. JPEG works well with photographic images, | |
49 | and is still more compatible with the major Web browsers than even PNG | |
50 | is. WBMP is intended for wireless devices (not regular web browsers). | |
cb954d5c | 51 | |
0a1333ac JR |
52 | %description -l es.UTF-8 |
53 | Esta es la biblioteca gd para el manejo de imágenes. Fue creada para | |
54 | uso en la Web, creando gráficos automáticamente. Pero es útil para | |
55 | cualquier programa que necesite de imágenes personalizados. No es un | |
b2f4bbcd | 56 | programa de dibujo; es una biblioteca. |
57 | ||
0a1333ac JR |
58 | %description -l pl.UTF-8 |
59 | gd to biblioteka do obróbki obrazów. Została stworzona, aby umożliwić | |
60 | dynamiczne generowanie wykresów i podobnych rzeczy na potrzeby WWW, | |
61 | ale może być przydatna także dla każdej aplikacji tworzącej własne | |
62 | obrazy. Biblioteka ta pozwala na tworzenie plików graficznych w | |
f0e7dffb | 63 | formatach PNG, JPEG, GIF i WBMP. PNG jest zwartym formatem z |
0a1333ac JR |
64 | bezstratną kompresją. JPEG dobrze nadaje się do obrazów |
65 | fotograficznych i jest obsługiwany nawet przez więcej przeglądarek WWW | |
66 | niż PNG. WBMP jest przeznaczony dla urządzeń bezprzewodowych (a nie | |
67 | zwykłych przeglądarek WWW). | |
10511b86 | 68 | |
0a1333ac JR |
69 | %description -l pt_BR.UTF-8 |
70 | Esta é a biblioteca gd para manipulação de imagens. Ela foi criada | |
71 | para uso na Web, gerando gráficos automaticamente. Mas é útil para | |
72 | qualquer programa que precise de imagens personalizados. Não é um | |
73 | programa de desenho; é uma biblioteca. | |
b2f4bbcd | 74 | |
cb954d5c | 75 | %package devel |
bf525458 | 76 | Summary: Development part of the GD library |
276f8082 ER |
77 | Summary(es.UTF-8): Archivos de inclusión y bibliotecas para desarrollar programas usando gd |
78 | Summary(pl.UTF-8): Część biblioteki GD przeznaczona dla developerów | |
79 | Summary(pt_BR.UTF-8): Arquivos de inclusão e bibliotecas para desenvolver programas usando gd | |
bf525458 | 80 | Group: Development/Libraries |
f50b7aa0 | 81 | Requires: %{name} = %{version}-%{release} |
5dc4c1e0 | 82 | Requires: fontconfig-devel |
0fe9ae1e JB |
83 | Requires: freetype-devel >= 2.0 |
84 | Requires: libjpeg-devel | |
bd2f5b37 | 85 | Requires: libpng-devel |
ab0e31ee | 86 | %{?with_xpm:Requires: xorg-lib-libXpm-devel} |
bd2f5b37 | 87 | Requires: zlib-devel |
f0e7dffb | 88 | Provides: gd-devel(gif) = %{version}-%{release} |
04a4831a | 89 | Provides: gd-devel(imagerotate) = 5.2.0 |
cb954d5c | 90 | |
91 | %description devel | |
ad076400 | 92 | This package contains the files needed for development of programs |
93 | linked against GD. | |
cb954d5c | 94 | |
0a1333ac JR |
95 | %description devel -l es.UTF-8 |
96 | Este paquete contiene los archivos de inclusión y las bibliotecas | |
b2f4bbcd | 97 | necesarias para desarrollar programas usando gd. |
98 | ||
0a1333ac JR |
99 | %description devel -l pl.UTF-8 |
100 | Pakiet ten zawiera pliki potrzebne do rozwoju programów korzystających | |
76d4466d | 101 | z biblioteki GD. |
10511b86 | 102 | |
0a1333ac JR |
103 | %description devel -l pt_BR.UTF-8 |
104 | Este pacote contém os arquivos de inclusão e as bibliotecas | |
105 | necessárias para desenvolver programas usando gd. | |
b2f4bbcd | 106 | |
e4dcaf92 | 107 | %package static |
76d4466d | 108 | Summary: Static GD library |
276f8082 ER |
109 | Summary(pl.UTF-8): Statyczna biblioteka GD |
110 | Summary(pt_BR.UTF-8): Bibliotecas estáticas para desenvolvimento com libgd | |
76d4466d | 111 | Group: Development/Libraries |
f50b7aa0 | 112 | Requires: %{name}-devel = %{version}-%{release} |
f0e7dffb | 113 | Provides: gd-static(gif) = %{version}-%{release} |
04a4831a | 114 | Provides: gd-static(imagerotate) = 5.2.0 |
cb954d5c | 115 | |
777cca0f | 116 | %description static |
0fe9ae1e | 117 | This package contains static gd library. |
b2f4bbcd | 118 | |
0a1333ac JR |
119 | %description static -l pl.UTF-8 |
120 | Ten pakiet zawiera statyczną bibliotekę gd. | |
e4dcaf92 | 121 | |
0a1333ac JR |
122 | %description static -l pt_BR.UTF-8 |
123 | Este pacote contem bibliotecas estáticas para desenvolvimento com | |
b2f4bbcd | 124 | libgd. |
125 | ||
e81f3f85 | 126 | %package progs |
127 | Summary: Utility programs that use libgd | |
276f8082 ER |
128 | Summary(es.UTF-8): Programas utilitarios libgd |
129 | Summary(pl.UTF-8): Narzędzia używające libgd | |
130 | Summary(pt_BR.UTF-8): Programas utilitários libgd | |
e81f3f85 | 131 | Group: Applications/Graphics |
f50b7aa0 | 132 | Requires: %{name} = %{version}-%{release} |
e81f3f85 | 133 | |
134 | %description progs | |
0fe9ae1e | 135 | These are utility programs supplied with gd, the image manipulation |
26e69c10 | 136 | library. The libgd-progs package contains a group of scripts for |
137 | manipulating the graphics files in formats which are supported by the | |
138 | libgd library. | |
b2f4bbcd | 139 | |
0a1333ac JR |
140 | %description progs -l pl.UTF-8 |
141 | Ten pakiet zawiera programy używające biblioteki gd, służące do | |
142 | obróbki plików graficznych w formatach obsługiwanych przez libgd. | |
e81f3f85 | 143 | |
0a1333ac JR |
144 | %description progs -l pt_BR.UTF-8 |
145 | Este pacote inclui vários utilitários para manipulação de arquivos gd | |
b2f4bbcd | 146 | para uso pelos programas que usam a libgd. |
147 | ||
e4dcaf92 | 148 | %prep |
41392427 | 149 | %setup -q |
f0e7dffb | 150 | %patch0 -p1 |
91cfdb36 | 151 | %patch1 -p1 |
0f4482da AM |
152 | %patch2 -p1 |
153 | %patch3 -p1 | |
154 | %patch4 -p1 | |
155 | %patch5 -p1 | |
156 | %patch6 -p1 | |
4c5e5b22 | 157 | %patch7 -p1 |
11a3aa5c | 158 | |
6eb2ae1b | 159 | # hack to avoid inclusion of -s in --ldflags |
160 | %{__perl} -pi -e 's,\@LDFLAGS\@,,g' config/gdlib-config.in | |
5c31e4cb | 161 | |
76b282ae | 162 | # png_check_sig was replaced by png_sig_cmp in libpng |
163 | %{__sed} -i -e 's/if (!png_check_sig (sig, 8))/if (png_sig_cmp(sig, 0, 8))/g' gd_png.c | |
164 | ||
e4dcaf92 | 165 | %build |
dfe01bee | 166 | %{__libtoolize} |
6de95af7 | 167 | %{__aclocal} |
1b927a19 | 168 | %{__automake} |
f0e7dffb | 169 | %{__autoheader} |
1b927a19 | 170 | %{__autoconf} |
2d7c1ea5 JB |
171 | %configure \ |
172 | %{!?with_fontconfig:--without-fontconfig} \ | |
173 | %{!?with_xpm:--without-xpm} | |
b7b66453 | 174 | %{__make} |
1bb411e9 | 175 | |
cb954d5c | 176 | %install |
b7b66453 | 177 | rm -rf $RPM_BUILD_ROOT |
ad076400 | 178 | |
2260ee2f | 179 | %{__make} install \ |
e87e503b | 180 | DESTDIR=$RPM_BUILD_ROOT |
ad076400 | 181 | |
cb954d5c | 182 | %clean |
d2ddf380 | 183 | rm -rf $RPM_BUILD_ROOT |
cb954d5c | 184 | |
e87e503b | 185 | %post -p /sbin/ldconfig |
cb954d5c | 186 | %postun -p /sbin/ldconfig |
187 | ||
188 | %files | |
e4dcaf92 | 189 | %defattr(644,root,root,755) |
bd13356b | 190 | %doc COPYING index.html |
04a4831a | 191 | %attr(755,root,root) %{_libdir}/libgd.so.*.*.* |
45d93025 | 192 | %attr(755,root,root) %ghost %{_libdir}/libgd.so.2 |
cb954d5c | 193 | |
194 | %files devel | |
bf525458 | 195 | %defattr(644,root,root,755) |
bd13356b | 196 | %attr(755,root,root) %{_bindir}/gdlib-config |
04a4831a JB |
197 | %attr(755,root,root) %{_libdir}/libgd.so |
198 | %{_libdir}/libgd.la | |
45d93025 JB |
199 | %{_includedir}/entities.h |
200 | %{_includedir}/gd*.h | |
e4dcaf92 | 201 | |
b2f653fd | 202 | %files static |
203 | %defattr(644,root,root,755) | |
04a4831a | 204 | %{_libdir}/libgd.a |
e81f3f85 | 205 | |
206 | %files progs | |
207 | %defattr(644,root,root,755) | |
45d93025 JB |
208 | %attr(755,root,root) %{_bindir}/annotate |
209 | %attr(755,root,root) %{_bindir}/bdftogd | |
210 | %attr(755,root,root) %{_bindir}/gd2copypal | |
211 | %attr(755,root,root) %{_bindir}/gd2togif | |
212 | %attr(755,root,root) %{_bindir}/gd2topng | |
213 | %attr(755,root,root) %{_bindir}/gdcmpgif | |
214 | %attr(755,root,root) %{_bindir}/gdparttopng | |
215 | %attr(755,root,root) %{_bindir}/gdtopng | |
216 | %attr(755,root,root) %{_bindir}/giftogd2 | |
217 | %attr(755,root,root) %{_bindir}/pngtogd | |
218 | %attr(755,root,root) %{_bindir}/pngtogd2 | |
219 | %attr(755,root,root) %{_bindir}/webpng |