2007-01-15 23:13:51 +00:00
|
|
|
#
|
2011-06-15 07:07:29 +00:00
|
|
|
# spec file for package gd
|
2007-01-15 23:13:51 +00:00
|
|
|
#
|
2011-06-15 07:07:29 +00:00
|
|
|
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2007-01-15 23:13:51 +00:00
|
|
|
#
|
2008-11-17 15:50:55 +00:00
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2007-01-15 23:13:51 +00:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
# norootforbuild
|
|
|
|
|
2008-03-10 01:55:24 +00:00
|
|
|
|
2007-01-15 23:13:51 +00:00
|
|
|
Name: gd
|
|
|
|
BuildRequires: fontconfig-devel freetype2-devel libjpeg-devel libpng-devel xorg-x11-libX11-devel xorg-x11-libXau-devel xorg-x11-libXdmcp-devel xorg-x11-libXpm-devel
|
2011-10-03 07:19:14 +00:00
|
|
|
BuildRequires: libtool
|
2010-04-04 18:06:20 +00:00
|
|
|
License: MIT
|
2007-01-15 23:13:51 +00:00
|
|
|
Group: System/Libraries
|
2007-12-22 18:32:58 +00:00
|
|
|
Provides: gdlib
|
2007-01-15 23:13:51 +00:00
|
|
|
Obsoletes: gdlib
|
2007-12-22 18:32:58 +00:00
|
|
|
AutoReqProv: on
|
2008-03-10 01:55:24 +00:00
|
|
|
Version: 2.0.36.RC1
|
2011-06-15 07:07:29 +00:00
|
|
|
Release: 65
|
2007-12-22 18:32:58 +00:00
|
|
|
Url: http://www.libgd.org/
|
2007-01-15 23:13:51 +00:00
|
|
|
Summary: A Drawing Library for Programs That Use PNG and JPEG Output
|
|
|
|
Source: gd-%{version}.tar.bz2
|
2010-04-07 15:42:12 +00:00
|
|
|
Source1: baselibs.conf
|
2008-03-10 01:55:24 +00:00
|
|
|
Patch0: gd-2.0.36RC1-warn.patch
|
2007-02-25 22:24:04 +00:00
|
|
|
#Patch1: gd-CAN-2004-0941.patch
|
2007-01-15 23:13:51 +00:00
|
|
|
Patch2: gd-format.patch
|
|
|
|
Patch3: gd-aliasing.patch
|
|
|
|
Patch6: gd-fontpath.patch
|
2008-03-10 01:55:24 +00:00
|
|
|
Patch7: gd-2.0.36RC1-config.patch
|
2008-11-17 15:50:55 +00:00
|
|
|
Patch8: gd-2.0.36.RC1-ppc64.patch
|
2010-04-04 18:06:20 +00:00
|
|
|
Patch9: gd-png_check_sig.patch
|
2007-01-15 23:13:51 +00:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
|
|
|
|
%description
|
|
|
|
Gd allows your code to quickly draw images complete with lines, arcs,
|
|
|
|
text, and multiple colors. It supports cut and paste from other images
|
|
|
|
and flood fills. It outputs PNG, JPEG, and WBMP (for wireless devices)
|
|
|
|
and is supported by PHP4.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Authors:
|
|
|
|
--------
|
|
|
|
Thomas Boutell <boutell@boutell.com>
|
|
|
|
|
|
|
|
%package devel
|
2007-12-22 18:32:58 +00:00
|
|
|
Requires: %{name} = %{version} glibc-devel
|
2010-04-04 18:06:20 +00:00
|
|
|
License: MIT
|
2007-01-15 23:13:51 +00:00
|
|
|
Summary: Drawing Library for Programs with PNG and JPEG Output
|
|
|
|
Group: Development/Libraries/C and C++
|
2011-06-15 07:07:16 +00:00
|
|
|
Requires: zlib-devel libpng-devel
|
2007-01-15 23:13:51 +00:00
|
|
|
|
|
|
|
%description devel
|
|
|
|
gd allows code to quickly draw images complete with lines, arcs, text,
|
|
|
|
multiple colors, cut and paste from other images, and flood fills. gd
|
|
|
|
writes out the result as a PNG or JPEG file. This is particularly
|
|
|
|
useful in World Wide Web applications, where PNG and JPEG are two of
|
|
|
|
the formats accepted for inline images by most browsers.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Authors:
|
|
|
|
--------
|
|
|
|
Thomas Boutell <boutell@boutell.com>
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q
|
2007-02-25 22:24:04 +00:00
|
|
|
#%patch0
|
2007-01-15 23:13:51 +00:00
|
|
|
%patch2 -p1
|
|
|
|
%patch3
|
|
|
|
%patch6
|
2007-12-22 18:32:58 +00:00
|
|
|
%patch7
|
2008-11-17 15:50:55 +00:00
|
|
|
%patch8
|
2010-04-04 18:06:20 +00:00
|
|
|
%patch9
|
2007-01-15 23:13:51 +00:00
|
|
|
|
|
|
|
%build
|
2008-11-17 15:50:55 +00:00
|
|
|
autoreconf -fiv
|
2007-12-22 18:32:58 +00:00
|
|
|
export CFLAGS="$RPM_OPT_FLAGS"
|
|
|
|
export CPPFLAGS="%{optflags}"
|
|
|
|
%configure \
|
2007-01-15 23:13:51 +00:00
|
|
|
--with-freetype \
|
|
|
|
--with-jpeg \
|
2011-10-06 14:02:39 +00:00
|
|
|
--with-png=%{?_sysroot}/usr \
|
2007-01-15 23:13:51 +00:00
|
|
|
--with-xpm \
|
2007-12-22 18:32:58 +00:00
|
|
|
--disable-static \
|
2007-01-15 23:13:51 +00:00
|
|
|
--with-pic
|
2008-11-17 15:50:55 +00:00
|
|
|
%{__make} %{?jobs:-j%jobs}
|
|
|
|
|
|
|
|
%check
|
|
|
|
export MALLOC_CHECK_=2 MALLOC_PERTURB_=$((${RANDOM:-256} % 256))
|
2007-01-15 23:13:51 +00:00
|
|
|
#run test programs
|
|
|
|
cp test/gdtest_wbmp_to_png.png gdtest.png
|
|
|
|
./gdtest gdtest.png 2>&1 |tee gdtest.log
|
|
|
|
grep ERROR gdtest.log && exit 1
|
|
|
|
./gdtest demoin.png 2>&1 |tee gdtest.log
|
|
|
|
# wbmp test fails on color image, this is OK
|
|
|
|
grep -v "gdtest.png, gdtest.wbmp.*ERROR" gdtest.log | grep ERROR && exit 1
|
|
|
|
./gddemo
|
|
|
|
# The following would require xorg-x11-fonts-scalable which we do not like to have as requirement
|
|
|
|
# so disable it.
|
|
|
|
#for f in `find /usr/share/fonts/truetype /usr/X11R6/lib/X11/fonts/truetype -name "*.ttf"` ; do
|
|
|
|
# ./gdtestft $f
|
|
|
|
#done
|
2008-11-17 15:50:55 +00:00
|
|
|
unset MALLOC_CHECK_ MALLOC_PERTURB_
|
2007-01-15 23:13:51 +00:00
|
|
|
|
|
|
|
%install
|
|
|
|
make install DESTDIR=$RPM_BUILD_ROOT
|
|
|
|
|
|
|
|
%clean
|
|
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
2007-12-22 18:32:58 +00:00
|
|
|
%post -p /sbin/ldconfig
|
2007-01-15 23:13:51 +00:00
|
|
|
|
2007-12-22 18:32:58 +00:00
|
|
|
%postun -p /sbin/ldconfig
|
2007-01-15 23:13:51 +00:00
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%doc COPYING INSTALL README* index.html
|
|
|
|
/usr/bin/annotate
|
|
|
|
/usr/bin/bdftogd
|
|
|
|
/usr/bin/gd2copypal
|
|
|
|
/usr/bin/gd2togif
|
|
|
|
/usr/bin/gd2topng
|
|
|
|
/usr/bin/gdcmpgif
|
|
|
|
/usr/bin/gdparttopng
|
|
|
|
/usr/bin/gdtopng
|
|
|
|
/usr/bin/giftogd2
|
|
|
|
/usr/bin/pngtogd
|
|
|
|
/usr/bin/pngtogd2
|
|
|
|
/usr/bin/webpng
|
|
|
|
%{_libdir}/*.so.*
|
|
|
|
|
|
|
|
%files devel
|
|
|
|
%defattr(-,root,root)
|
2007-12-22 18:32:58 +00:00
|
|
|
%{_bindir}/gdlib-config
|
2007-01-15 23:13:51 +00:00
|
|
|
%{_includedir}/*
|
|
|
|
%{_libdir}/*.so
|
2007-12-22 18:32:58 +00:00
|
|
|
%exclude %{_libdir}/*.la
|
2007-01-15 23:13:51 +00:00
|
|
|
|
2007-02-25 22:24:04 +00:00
|
|
|
%changelog
|