3 %bcond_without fontconfig # fontconfig support
4 %bcond_without xpm # XPM support (requires X11 libs)
5 %bcond_without tests # "make check"
7 Summary: Library for PNG, JPEG creation
8 Summary(es.UTF-8): Biblioteca para manipulación de imágenes
9 Summary(pl.UTF-8): Biblioteka do tworzenia grafiki w formacie PNG, JPEG
10 Summary(pt_BR.UTF-8): Biblioteca para manipulação de imagens
16 Source0: https://bitbucket.org/libgd/gd-libgd/downloads/libgd-%{version}.tar.xz
17 # Source0-md5: 9076f3abd1f9815d106da36467ea15bc
18 Patch0: %{name}-fontpath.patch
19 Patch1: %{name}-2.0.33-BoxBound.patch
20 Patch2: %{name}-loop.patch
22 URL: http://www.libgd.org/
23 BuildRequires: autoconf >= 2.54
24 BuildRequires: automake
25 %{?with_fontconfig:BuildRequires: fontconfig-devel}
26 BuildRequires: freetype-devel >= 1:2.1.10
27 BuildRequires: gettext-tools
28 BuildRequires: libjpeg-devel
29 BuildRequires: libpng-devel >= 2:1.4.0
30 BuildRequires: libtiff-devel >= 4
31 BuildRequires: libtool >= 2:2
32 BuildRequires: libvpx-devel
33 BuildRequires: pkgconfig
34 BuildRequires: sed >= 4
35 BuildRequires: tar >= 1:1.22
36 %{?with_xpm:BuildRequires: xorg-lib-libXpm-devel}
38 BuildRequires: zlib-devel
39 Requires: freetype >= 1:2.1.10
40 Provides: gd(gif) = %{version}-%{release}
41 # versioned by php version rotate_from_php code comes from
42 Provides: gd(imagerotate) = 5.2.0
43 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46 gd is the image manipulating library. It was created to allow graphs,
47 charts and the like to be generated on the fly for use on the World
48 wide Web, but is useful for any application in which custom images are
49 useful. It is not a paint program; it is a library. gd library creates
50 PNG, JPEG, GIF and WBMP images. PNG is a more compact format, and full
51 compression is available. JPEG works well with photographic images,
52 and is still more compatible with the major Web browsers than even PNG
53 is. WBMP is intended for wireless devices (not regular web browsers).
55 %description -l es.UTF-8
56 Esta es la biblioteca gd para el manejo de imágenes. Fue creada para
57 uso en la Web, creando gráficos automáticamente. Pero es útil para
58 cualquier programa que necesite de imágenes personalizados. No es un
59 programa de dibujo; es una biblioteca.
61 %description -l pl.UTF-8
62 gd to biblioteka do obróbki obrazów. Została stworzona, aby umożliwić
63 dynamiczne generowanie wykresów i podobnych rzeczy na potrzeby WWW,
64 ale może być przydatna także dla każdej aplikacji tworzącej własne
65 obrazy. Biblioteka ta pozwala na tworzenie plików graficznych w
66 formatach PNG, JPEG, GIF i WBMP. PNG jest zwartym formatem z
67 bezstratną kompresją. JPEG dobrze nadaje się do obrazów
68 fotograficznych i jest obsługiwany nawet przez więcej przeglądarek WWW
69 niż PNG. WBMP jest przeznaczony dla urządzeń bezprzewodowych (a nie
70 zwykłych przeglądarek WWW).
72 %description -l pt_BR.UTF-8
73 Esta é a biblioteca gd para manipulação de imagens. Ela foi criada
74 para uso na Web, gerando gráficos automaticamente. Mas é útil para
75 qualquer programa que precise de imagens personalizados. Não é um
76 programa de desenho; é uma biblioteca.
79 Summary: Development part of the GD library
80 Summary(es.UTF-8): Archivos de inclusión y bibliotecas para desarrollar programas usando gd
81 Summary(pl.UTF-8): Część biblioteki GD przeznaczona dla developerów
82 Summary(pt_BR.UTF-8): Arquivos de inclusão e bibliotecas para desenvolver programas usando gd
83 Group: Development/Libraries
84 Requires: %{name} = %{version}-%{release}
85 Requires: fontconfig-devel
86 Requires: freetype-devel >= 1:2.1.10
87 Requires: libjpeg-devel
88 Requires: libpng-devel
89 Requires: libtiff-devel >= 4
90 Requires: libvpx-devel
91 %{?with_xpm:Requires: xorg-lib-libXpm-devel}
93 Provides: gd-devel(gif) = %{version}-%{release}
94 Provides: gd-devel(imagerotate) = 5.2.0
97 This package contains the files needed for development of programs
100 %description devel -l es.UTF-8
101 Este paquete contiene los archivos de inclusión y las bibliotecas
102 necesarias para desarrollar programas usando gd.
104 %description devel -l pl.UTF-8
105 Pakiet ten zawiera pliki potrzebne do rozwoju programów korzystających
108 %description devel -l pt_BR.UTF-8
109 Este pacote contém os arquivos de inclusão e as bibliotecas
110 necessárias para desenvolver programas usando gd.
113 Summary: Static GD library
114 Summary(pl.UTF-8): Statyczna biblioteka GD
115 Summary(pt_BR.UTF-8): Bibliotecas estáticas para desenvolvimento com libgd
116 Group: Development/Libraries
117 Requires: %{name}-devel = %{version}-%{release}
118 Provides: gd-static(gif) = %{version}-%{release}
119 Provides: gd-static(imagerotate) = 5.2.0
122 This package contains static gd library.
124 %description static -l pl.UTF-8
125 Ten pakiet zawiera statyczną bibliotekę gd.
127 %description static -l pt_BR.UTF-8
128 Este pacote contem bibliotecas estáticas para desenvolvimento com
132 Summary: Utility programs that use libgd
133 Summary(es.UTF-8): Programas utilitarios libgd
134 Summary(pl.UTF-8): Narzędzia używające libgd
135 Summary(pt_BR.UTF-8): Programas utilitários libgd
136 Group: Applications/Graphics
137 Requires: %{name} = %{version}-%{release}
140 These are utility programs supplied with gd, the image manipulation
141 library. The libgd-progs package contains a group of scripts for
142 manipulating the graphics files in formats which are supported by the
145 %description progs -l pl.UTF-8
146 Ten pakiet zawiera programy używające biblioteki gd, służące do
147 obróbki plików graficznych w formatach obsługiwanych przez libgd.
149 %description progs -l pt_BR.UTF-8
150 Este pacote inclui vários utilitários para manipulação de arquivos gd
151 para uso pelos programas que usam a libgd.
154 %setup -q -n libgd-%{version}
160 # hack to avoid inclusion of -s in --ldflags
161 %{__sed} -i -e 's,@LDFLAGS@,,g' config/gdlib-config.in
162 # disable error caused by subdir-objects warning in automake 1.14
163 %{__sed} -i -e '/AM_INIT_AUTOMAKE/s/-Werror//' configure.ac
172 %{!?with_fontconfig:--without-fontconfig} \
173 %{!?with_xpm:--without-xpm}
177 # https://bitbucket.org/libgd/gd-libgd/issue/72/gdimagestringft_bbox-test-fails-on-old
178 export XFAIL_TESTS=gdimagestringft/gdimagestringft_bbox
183 rm -rf $RPM_BUILD_ROOT
186 DESTDIR=$RPM_BUILD_ROOT
189 rm -rf $RPM_BUILD_ROOT
191 %post -p /sbin/ldconfig
192 %postun -p /sbin/ldconfig
195 %defattr(644,root,root,755)
196 %doc COPYING ChangeLog NEWS
197 %attr(755,root,root) %{_libdir}/libgd.so.*.*.*
198 %attr(755,root,root) %ghost %{_libdir}/libgd.so.3
201 %defattr(644,root,root,755)
202 %attr(755,root,root) %{_bindir}/gdlib-config
203 %attr(755,root,root) %{_libdir}/libgd.so
205 %{_includedir}/entities.h
207 %{_pkgconfigdir}/gdlib.pc
210 %defattr(644,root,root,755)
214 %defattr(644,root,root,755)
215 %attr(755,root,root) %{_bindir}/annotate
216 %attr(755,root,root) %{_bindir}/bdftogd
217 %attr(755,root,root) %{_bindir}/gd2copypal
218 %attr(755,root,root) %{_bindir}/gd2togif
219 %attr(755,root,root) %{_bindir}/gd2topng
220 %attr(755,root,root) %{_bindir}/gdcmpgif
221 %attr(755,root,root) %{_bindir}/gdparttopng
222 %attr(755,root,root) %{_bindir}/gdtopng
223 %attr(755,root,root) %{_bindir}/giftogd2
224 %attr(755,root,root) %{_bindir}/pngtogd
225 %attr(755,root,root) %{_bindir}/pngtogd2
226 %attr(755,root,root) %{_bindir}/webpng