commit
189ab6c399
@ -1,20 +0,0 @@
|
||||
--- freetype-2.2.1/modules.cfg.orig 2006-07-07 21:01:09.000000000 -0400
|
||||
+++ freetype-2.2.1/modules.cfg 2006-07-07 21:01:54.000000000 -0400
|
||||
@@ -110,7 +110,7 @@
|
||||
# TrueType GX/AAT table validation. Needs `ftgxval.c' below.
|
||||
#
|
||||
# No FT_CONFIG_OPTION_PIC support.
|
||||
-# AUX_MODULES += gxvalid
|
||||
+AUX_MODULES += gxvalid
|
||||
|
||||
# Support for streams compressed with gzip (files with suffix .gz).
|
||||
#
|
||||
@@ -124,7 +124,7 @@
|
||||
# OpenType table validation. Needs `ftotval.c' below.
|
||||
#
|
||||
# No FT_CONFIG_OPTION_PIC support.
|
||||
-# AUX_MODULES += otvalid
|
||||
+AUX_MODULES += otvalid
|
||||
|
||||
# Auxiliary PostScript driver component to share common code.
|
||||
#
|
||||
@ -1,11 +0,0 @@
|
||||
--- freetype-2.3.0/include/freetype/config/ftoption.h.spf 2007-01-18 14:27:34.000000000 -0500
|
||||
+++ freetype-2.3.0/include/freetype/config/ftoption.h 2007-01-18 14:27:48.000000000 -0500
|
||||
@@ -92,7 +92,7 @@
|
||||
/* rendering technology that produces excellent output without LCD */
|
||||
/* filtering. */
|
||||
/* */
|
||||
-/* #define FT_CONFIG_OPTION_SUBPIXEL_RENDERING */
|
||||
+#define FT_CONFIG_OPTION_SUBPIXEL_RENDERING
|
||||
|
||||
|
||||
/*************************************************************************/
|
||||
@ -1,11 +0,0 @@
|
||||
--- freetype-2.8/builds/unix/freetype-config.in.orig 2017-03-30 12:20:23.000000001 +0200
|
||||
+++ freetype-2.8/builds/unix/freetype-config.in 2017-05-16 13:25:39.223041128 +0200
|
||||
@@ -205,7 +205,7 @@ if test "$echo_libs" = "yes" ; then
|
||||
fi
|
||||
|
||||
if test "$echo_libtool" = "yes" ; then
|
||||
- echo ${SYSROOT}$libdir/libfreetype.la
|
||||
+ echo ""
|
||||
fi
|
||||
|
||||
# EOF
|
||||
@ -1,65 +0,0 @@
|
||||
--- freetype-2.9/builds/unix/freetype-config.in
|
||||
+++ freetype-2.9/builds/unix/freetype-config.in
|
||||
@@ -13,45 +13,25 @@ LC_ALL=C
|
||||
export LC_ALL
|
||||
|
||||
|
||||
-# if `pkg-config' is available, use values from `freetype2.pc'
|
||||
-%PKG_CONFIG% --atleast-pkgconfig-version 0.24 >/dev/null 2>&1
|
||||
-if test $? -eq 0 ; then
|
||||
- # note that option `--variable' is not affected by the
|
||||
- # PKG_CONFIG_SYSROOT_DIR environment variable
|
||||
- if test "x$SYSROOT" != "x" ; then
|
||||
- PKG_CONFIG_SYSROOT_DIR="$SYSROOT"
|
||||
- export PKG_CONFIG_SYSROOT_DIR
|
||||
- fi
|
||||
-
|
||||
- prefix=`%PKG_CONFIG% --variable prefix freetype2`
|
||||
- exec_prefix=`%PKG_CONFIG% --variable exec_prefix freetype2`
|
||||
-
|
||||
- includedir=`%PKG_CONFIG% --variable includedir freetype2`
|
||||
- libdir=`%PKG_CONFIG% --variable libdir freetype2`
|
||||
-
|
||||
- version=`%PKG_CONFIG% --modversion freetype2`
|
||||
-
|
||||
- cflags=`%PKG_CONFIG% --cflags freetype2`
|
||||
- dynamic_libs=`%PKG_CONFIG% --libs freetype2`
|
||||
- static_libs=`%PKG_CONFIG% --static --libs freetype2`
|
||||
-else
|
||||
- prefix="%prefix%"
|
||||
- exec_prefix="%exec_prefix%"
|
||||
-
|
||||
- includedir="%includedir%"
|
||||
- libdir="%libdir%"
|
||||
-
|
||||
- version=%ft_version%
|
||||
-
|
||||
- cflags="-I${SYSROOT}$includedir/freetype2"
|
||||
- dynamic_libs="-lfreetype"
|
||||
- static_libs="%LIBSSTATIC_CONFIG%"
|
||||
- if test "${SYSROOT}$libdir" != "/usr/lib" &&
|
||||
- test "${SYSROOT}$libdir" != "/usr/lib64" ; then
|
||||
- libs_L="-L${SYSROOT}$libdir"
|
||||
- fi
|
||||
+# note that option `--variable' is not affected by the
|
||||
+# PKG_CONFIG_SYSROOT_DIR environment variable
|
||||
+if test "x$SYSROOT" != "x" ; then
|
||||
+ PKG_CONFIG_SYSROOT_DIR="$SYSROOT"
|
||||
+ export PKG_CONFIG_SYSROOT_DIR
|
||||
fi
|
||||
|
||||
+prefix=`%PKG_CONFIG% --variable prefix freetype2`
|
||||
+exec_prefix=`%PKG_CONFIG% --variable exec_prefix freetype2`
|
||||
+
|
||||
+includedir=`%PKG_CONFIG% --variable includedir freetype2`
|
||||
+libdir=`%PKG_CONFIG% --variable libdir freetype2`
|
||||
+
|
||||
+version=`%PKG_CONFIG% --modversion freetype2`
|
||||
+
|
||||
+cflags=`%PKG_CONFIG% --cflags freetype2`
|
||||
+dynamic_libs=`%PKG_CONFIG% --libs freetype2`
|
||||
+static_libs=`%PKG_CONFIG% --static --libs freetype2`
|
||||
+
|
||||
orig_prefix=$prefix
|
||||
orig_exec_prefix=$exec_prefix
|
||||
|
||||
@ -1,101 +0,0 @@
|
||||
--- a/src/smooth/ftsmooth.c
|
||||
+++ b/src/smooth/ftsmooth.c
|
||||
@@ -232,39 +232,13 @@
|
||||
FT_UInt i, j;
|
||||
|
||||
unsigned int height = bitmap->rows;
|
||||
- unsigned int width = bitmap->width;
|
||||
+ unsigned int width = bitmap->width / 3;
|
||||
int pitch = bitmap->pitch;
|
||||
|
||||
-
|
||||
- /* Render 3 separate monochrome bitmaps, shifting the outline */
|
||||
- /* by 1/3 pixel. */
|
||||
- width /= 3;
|
||||
-
|
||||
- bitmap->buffer += width;
|
||||
-
|
||||
- error = render->raster_render( render->raster, ¶ms );
|
||||
- if ( error )
|
||||
- goto Exit;
|
||||
-
|
||||
- FT_Outline_Translate( outline, -21, 0 );
|
||||
- x_shift -= 21;
|
||||
- bitmap->buffer += width;
|
||||
-
|
||||
error = render->raster_render( render->raster, ¶ms );
|
||||
if ( error )
|
||||
goto Exit;
|
||||
|
||||
- FT_Outline_Translate( outline, 42, 0 );
|
||||
- x_shift += 42;
|
||||
- bitmap->buffer -= 2 * width;
|
||||
-
|
||||
- error = render->raster_render( render->raster, ¶ms );
|
||||
- if ( error )
|
||||
- goto Exit;
|
||||
-
|
||||
- /* XXX: Rearrange the bytes according to FT_PIXEL_MODE_LCD. */
|
||||
- /* XXX: It is more efficient to render every third byte above. */
|
||||
-
|
||||
if ( FT_ALLOC( temp, (FT_ULong)pitch ) )
|
||||
goto Exit;
|
||||
|
||||
@@ -272,11 +246,7 @@
|
||||
{
|
||||
line = bitmap->buffer + i * (FT_ULong)pitch;
|
||||
for ( j = 0; j < width; j++ )
|
||||
- {
|
||||
- temp[3 * j ] = line[j];
|
||||
- temp[3 * j + 1] = line[j + width];
|
||||
- temp[3 * j + 2] = line[j + width + width];
|
||||
- }
|
||||
+ temp[3 * j] = temp[3 * j + 1] = temp[3 * j + 2] = line[j];
|
||||
FT_MEM_COPY( line, temp, pitch );
|
||||
}
|
||||
|
||||
@@ -284,35 +254,23 @@
|
||||
}
|
||||
else if ( vmul ) /* lcd_v */
|
||||
{
|
||||
- int pitch = bitmap->pitch;
|
||||
-
|
||||
+ FT_Byte* line;
|
||||
+ FT_UInt i;
|
||||
+ int original_pitch = bitmap->pitch;
|
||||
|
||||
- /* Render 3 separate monochrome bitmaps, shifting the outline */
|
||||
- /* by 1/3 pixel. Triple the pitch to render on each third row. */
|
||||
bitmap->pitch *= 3;
|
||||
bitmap->rows /= 3;
|
||||
|
||||
- bitmap->buffer += pitch;
|
||||
-
|
||||
- error = render->raster_render( render->raster, ¶ms );
|
||||
- if ( error )
|
||||
- goto Exit;
|
||||
-
|
||||
- FT_Outline_Translate( outline, 0, 21 );
|
||||
- y_shift += 21;
|
||||
- bitmap->buffer += pitch;
|
||||
-
|
||||
error = render->raster_render( render->raster, ¶ms );
|
||||
if ( error )
|
||||
goto Exit;
|
||||
|
||||
- FT_Outline_Translate( outline, 0, -42 );
|
||||
- y_shift -= 42;
|
||||
- bitmap->buffer -= 2 * pitch;
|
||||
-
|
||||
- error = render->raster_render( render->raster, ¶ms );
|
||||
- if ( error )
|
||||
- goto Exit;
|
||||
+ for ( i = 0; i < bitmap->rows; i++ )
|
||||
+ {
|
||||
+ line = bitmap->buffer + i * bitmap->pitch;
|
||||
+ FT_MEM_COPY( line + original_pitch, line, bitmap->width );
|
||||
+ FT_MEM_COPY( line + 2 * original_pitch, line, bitmap->width );
|
||||
+ }
|
||||
|
||||
bitmap->pitch /= 3;
|
||||
bitmap->rows *= 3;
|
||||
@ -4,28 +4,16 @@
|
||||
|
||||
Name: freetype
|
||||
Version: 2.9.1
|
||||
Release: 3
|
||||
Release: 4
|
||||
Summary: FreeType is a freely available software library to render fonts
|
||||
License: (FTL or GPLv2+) and BSD and MIT and Public Domain and zlib with acknowledgement
|
||||
URL: http://www.freetype.org
|
||||
Source0: http://download.savannah.gnu.org/releases/freetype/freetype-%{version}.tar.bz2
|
||||
Source1: http://download.savannah.gnu.org/releases/freetype/freetype-doc-%{version}.tar.bz2
|
||||
Source2: http://download.savannah.gnu.org/releases/freetype/ft2demos-%{version}.tar.bz2
|
||||
#ftconfig.h from fedora project
|
||||
Source3: ftconfig.h
|
||||
|
||||
#PATCH-FIX-https://bugzilla.redhat.com/
|
||||
Patch0: freetype-2.3.0-enable-spr.patch
|
||||
#PATCH-FIX-https://bugzilla.redhat.com/ Enable otvalid and gxvalid modules patch from fedora project
|
||||
Patch1: freetype-2.2.1-enable-valid.patch
|
||||
#PATCH-FIX-https://bugzilla.redhat.com/ Enable additional demos patch from fedora project
|
||||
Patch2: freetype-2.5.2-more-demos.patch
|
||||
#PATCH-FIX-https://bugzilla.redhat.com/
|
||||
Patch3: freetype-2.6.5-libtool.patch
|
||||
#PATCH-FIX-https://bugzilla.redhat.com/
|
||||
Patch4: freetype-2.8-multilib.patch
|
||||
#PATCH-FIX-https://bugzilla.redhat.com/
|
||||
Patch5: freetype-2.9-ftsmooth.patch
|
||||
Patch1: freetype-2.5.2-more-demos.patch
|
||||
|
||||
BuildRequires: gcc libX11-devel libpng-devel zlib-devel bzip2-devel
|
||||
|
||||
@ -59,20 +47,10 @@ Man pages and other related for freetype documents.
|
||||
%prep
|
||||
%setup -q -b 1 -a 2
|
||||
|
||||
%if %{?_with_subpixel_rendering:1}%{!?_with_subpixel_rendering:0}
|
||||
%patch0 -p1 -b .enable-spr
|
||||
%endif
|
||||
|
||||
%patch1 -p1 -b .enable-valid
|
||||
|
||||
pushd ft2demos-%{version}
|
||||
%patch2 -p1 -b .more-demos
|
||||
popd
|
||||
|
||||
%patch3 -p1 -b .libtool
|
||||
%patch4 -p1 -b .multilib
|
||||
%patch5 -p1 -b .ftsmooth
|
||||
|
||||
%build
|
||||
%configure --disable-static --with-zlib=yes --with-bzip2=yes --with-png=yes --enable-freetype-config --with-harfbuzz=no
|
||||
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' builds/unix/libtool
|
||||
@ -143,5 +121,12 @@ install -p -m 644 %{SOURCE3} $RPM_BUILD_ROOT%{_includedir}/freetype2/freetype/co
|
||||
%{_mandir}/man1/*
|
||||
|
||||
%changelog
|
||||
* Sat Jan 11 2020 openEuler Buildteam <buildteam@openeuler.org> - 2.9.1-4
|
||||
- Type:enhancement
|
||||
- Id:NA
|
||||
- SUG:NA
|
||||
- DESC:optimization the spec
|
||||
|
||||
|
||||
* Wed Sep 11 2019 openEuler jimmy<dukaitian@huawei.com> - 2.9.1-3
|
||||
- Package init jimmy
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user