%define build_bytecode_interpreter 0 %define build_subpixel 0 %define build_plf 0 %{?_with_plf: %global build_plf 1} %{?_with_bytecode_interpreter: %global build_bytecode_interpreter 1} %{?_with_subpixel: %global build_subpixel 1} %define name freetype2 %define version 2.3.5 %if %build_plf %define distsuffix plf %define build_subpixel 1 %define build_bytecode_interpreter 1 %endif %define major 6 %define libname %mklibname freetype %{major} %define develname %mklibname -d freetype %{major} %define staticdevelname %mklibname -d -s freetype %{major} Name: %name Summary: A free and portable TrueType font rendering engine Version: %version Release: %mkrel 1 License: FreeType License/GPL URL: http://www.freetype.org/ Source0: ftp://ftp.freetype.org/pub/freetype/freetype2/freetype-%{version}.tar.bz2 Source1: ftp://ftp.freetype.org/pub/freetype/freetype2/freetype-doc-%{version}.tar.bz2 Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildRequires: zlib-devel BuildRequires: pkgconfig Group: System/Libraries %description The FreeType2 engine is a free and portable TrueType font rendering engine. It has been developed to provide TT support to a great variety of platforms and environments. Note that FreeType2 is a library, not a stand-alone application, though some utility applications are included %if %{build_plf} This package is in PLF because this build has bytecode interpreter and subpixel hinting enabled which are covered by software patents. %endif %package -n %{libname} Summary: Shared libraries for a free and portable TrueType font rendering engine Group: System/Libraries Obsoletes: %{name} Provides: %{name} = %{version}-%{release} %description -n %{libname} The FreeType2 engine is a free and portable TrueType font rendering engine. It has been developed to provide TT support to a great variety of platforms and environments. Note that FreeType2 is a library, not a stand-alone application, though some utility applications are included %if %{build_plf} This package is in PLF because this build has bytecode interpreter and subpixel hinting enabled which are covered by software patents. %endif %package -n %{develname} Summary: Header files and static library for development with FreeType2 Group: Development/C Requires: %{libname} = %{version} Requires: zlib-devel Obsoletes: %{name}-devel Provides: %{name}-devel = %{version}-%{release} %description -n %{develname} This package is only needed if you intend to develop or compile applications which rely on the FreeType2 library. If you simply want to run existing applications, you won't need this package. %package -n %{staticdevelname} Summary: Static libraries for programs which will use the FreeType2 library Group: Development/C Requires: %{libname}-devel = %{version} Obsoletes: %{name}-static-devel Provides: %{name}-static-devel = %{version}-%{release} %description -n %{staticdevelname} This package includes the static libraries necessary for developing programs which will use the FreeType2 library. If you are going to develop programs which use the FreeType2 library you should install freetype2-devel. You'll also need to have the freetype2 package installed. %prep %setup -q -n freetype-%version -b 1 %if %{build_bytecode_interpreter} perl -pi -e 's|/\* #define TT_CONFIG_OPTION_BYTECODE_INTERPRETER \*/|#define TT_CONFIG_OPTION_BYTECODE_INTERPRETER|' include/freetype/config/ftoption.h %endif %if %{build_subpixel} perl -pi -e 's|^/\* #define FT_CONFIG_OPTION_SUBPIXEL_RENDERING \*/| #define FT_CONFIG_OPTION_SUBPIXEL_RENDERING|' include/freetype/config/ftoption.h %endif %build %{?__cputoolize: %{__cputoolize} -c builds/unix} GCC_VERSION=`gcc --version | grep "^gcc" | awk '{ print $3 }' | sed 's+\([0-9]\)\.\([0-9]\)\..*+\1\2+'` if [ $GCC_VERSION -lt 34 ]; then #old gcc is generating wrong code with optimizations export CFLAGS="-O" fi # some apps crash on ppc without this %ifarch ppc export CFLAGS="`echo %optflags |sed s/O2/O0/`" %endif %configure2_5x %make %install rm -fr %buildroot %makeinstall %multiarch_binaries $RPM_BUILD_ROOT%{_bindir}/freetype-config %multiarch_includes $RPM_BUILD_ROOT%{_includedir}/freetype2/freetype/config/ftconfig.h %clean rm -fr %buildroot %post -n %{libname} -p /sbin/ldconfig %postun -n %{libname} -p /sbin/ldconfig %files -n %{libname} %defattr(-, root, root) %{_libdir}/*.so.%{major}* %files -n %{develname} %defattr(-, root, root) %doc docs/* %{_bindir}/freetype-config %{_libdir}/*.so %{_libdir}/*.la %dir %{_includedir}/freetype2 %{_includedir}/freetype2/* %{_includedir}/ft2build.h %{_datadir}/aclocal/* %{_libdir}/pkgconfig/* %multiarch %multiarch_bindir/freetype-config %multiarch %dir %multiarch_includedir/freetype2 %multiarch %multiarch_includedir/freetype2/* %files -n %{staticdevelname} %defattr(-, root, root) %{_libdir}/*.a %changelog * Tue Jul 03 2007 Funda Wang <fundawang@mandriva.org> 2.3.5-1mdv2008.0 + Revision: 47335 - New version + Anssi Hannula <anssi@mandriva.org> - plf: update reason * Fri Apr 27 2007 Frederic Crozat <fcrozat@mandriva.com> 2.3.4-1mdv2008.0 + Revision: 18751 - Release 2.3.4 - Remove patch0, merged upstream - add build options in package to enable individually subpixel hinting and bytecode interpreter * Sat Apr 21 2007 Anssi Hannula <anssi@mandriva.org> 2.3.1-4mdv2008.0 + Revision: 16552 - patch0: fix CVE-2007-1351 * Sun Feb 18 2007 Götz Waschk <waschk@mandriva.org> 2.3.1-3mdv2007.0 + Revision: 122328 - fix buildrequires * Sun Feb 18 2007 Götz Waschk <waschk@mandriva.org> 2.3.1-2mdv2007.1 + Revision: 122284 - rebuild to fix pkgconfig deps * Wed Jan 31 2007 Frederic Crozat <fcrozat@mandriva.com> 2.3.1-1mdv2007.1 + Revision: 115653 - Release 2.3.1 * Wed Jan 17 2007 Frederic Crozat <fcrozat@mandriva.com> 2.3.0-1mdv2007.1 + Revision: 109964 - Release 2.3.0 - Removes all patches, merged upstream * Sat Dec 02 2006 Olivier Blin <oblin@mandriva.com> 2.2.1-9mdv2007.1 + Revision: 89940 - fix overlapping segments (#23258) * Sat Nov 11 2006 Anssi Hannula <anssi@mandriva.org> 2.2.1-8mdv2007.0 + Revision: 81091 - plf: really enable full hinting * Fri Nov 03 2006 Anssi Hannula <anssi@mandriva.org> 2.2.1-7mdv2007.1 + Revision: 76248 - increase release - plf: fix reason + Oden Eriksson <oeriksson@mandriva.com> - bzip2 cleanup - rebuild * Thu Oct 12 2006 Oden Eriksson <oeriksson@mandriva.com> 2.2.1-5mdv2007.1 + Revision: 63443 - bunzip patches - Import freetype2 * Tue Sep 12 2006 Frederic Crozat <fcrozat@mandriva.com> 2.2.1-4mdv2007.0 - Patch6 (pterjan): fix crash (fdo bug #6841) * Sat Jul 22 2006 Frederic Crozat <fcrozat@mandriva.com> 2.2.1-3mdv2007.0 - Patch0 (CVS): fix CVE-2006-3467 - Patch1 (CVS): handles correctly bdf fonts without POINT_SIZE property - Patch2 (CVS): fix bytecode hint instructions - Patch3 (CVS): fix handling of some strange PFR fonts - Patch4 (CVS): speedup small gzip fonts loading - Patch5 (CVS): fix rogue client crash * Tue May 30 2006 Götz Waschk <waschk@mandriva.org> 2.2.1-2mdv2007.0 - mkrel * Tue May 16 2006 Frederic Crozat <fcrozat@mandriva.com> 2.2.1-1mdk - Release 2.2.1 - Remove patches 0, 1, 2, 3, 5, 6 (merged upstream) * Wed Nov 16 2005 Frederic Crozat <fcrozat@mandriva.com> 2.1.10-10mdk - Rebuild to get debug package * Tue Sep 27 2005 Frederic Crozat <fcrozat@mandriva.com> 2.1.10-9mdk - Patch6 (David Turner): fix anti-aliasing rendering * Wed Sep 21 2005 Frederic Crozat <fcrozat@mandriva.com> 2.1.10-8mdk - Remove patch4, it wasn't fixing the real problem which is in cairo * Wed Sep 14 2005 Frederic Crozat <fcrozat@mandriva.com> 2.1.10-7mdk - Patch5 (CVS): fix disabled kerning * Wed Aug 31 2005 Frederic Crozat <fcrozat@mandriva.com> 2.1.10-6mdk - Patch4 (Owen Taylor): fix font rendering in Cairo * Thu Aug 25 2005 Frederic Crozat <fcrozat@mandriva.com> 2.1.10-5mdk - Patch2 (CVS): fix autofit render setup - Patch3 (CVS): fix memleak * Thu Aug 25 2005 Götz Waschk <waschk@mandriva.org> 2.1.10-4mdk - fix bug 17248 * Thu Aug 04 2005 Frederic Crozat <fcrozat@mandriva.com> 2.1.10-3mdk - Patch1 (David Turner): put back internal API used by xorg-x11 (Mdk bug #14636) * Wed Aug 03 2005 Frederic Crozat <fcrozat@mandriva.com> 2.1.10-2mdk - Patch0 (CVS): various fixes (mostly embolding) * Tue Jul 05 2005 Frederic Crozat <fcrozat@mandriva.com> 2.1.10-1mdk - Release 2.1.10 - Remove patches 0, 3, 4, 5, 6, 7 (merged upstream) * Thu Mar 17 2005 Frederic Crozat <fcrozat@mandrakesoft.com> 2.1.9-6mdk - Disable patches 1 & 2, they seems to alter CJK (Mdk bug #14725) * Thu Mar 10 2005 Frederic Crozat <fcrozat@mandrakesoft.com> 2.1.9-5mdk - Patch1 (CVS): fix ttf hints distortions - Patch2 (CVS): fix ttf interpreter - Patch3 (CVS): fix stroker for closed outlines and single points - Patch4 (CVS): fix cff font load - Patch5 (CVS): fix size comparison for BDF files - Patch6 (CVS): fix size comparison for PCF files - Patch7 (CVS): fix fractional size handling * Thu Feb 10 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.1.9-4mdk - nuke lib64 rpaths - multiarch freetype-config (for --libtool) * Mon Jan 31 2005 Frederic Lepied <flepied@mandrakesoft.com> 2.1.9-3mdk - multiarch * Fri Jul 23 2004 Christiaan Welvaart <cjw@daneel.dyndns.org> 2.1.9-2mdk - use -O0 on ppc to prevent crashes with new fontconfig installed * Tue Jul 20 2004 Frederic Crozat <fcrozat@mandrakesoft.com> 2.1.9-1mdk - Release 2.1.9 - Add check to lower optimizations for old gcc * Sat Jul 10 2004 Frederic Crozat <fcrozat@mandrakesoft.com> 2.1.8-2mdk - Enable back optimizations (safe with gcc 3.4.x) * Thu Apr 22 2004 Frederic Crozat <fcrozat@mandrakesoft.com> 2.1.8-1mdk - Release 2.1.8 - Remove patch0 (merged upstream)