rpms/freetype1/devel freetype-1.3.1-1.4pre.patch, NONE, 1.1 freetype-1.4-disable-ft1-bci.patch, NONE, 1.1 freetype1.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
Hans de Goede (jwrdegoede)
fedora-extras-commits at redhat.com
Thu Jan 11 12:43:48 UTC 2007
Author: jwrdegoede
Update of /cvs/extras/rpms/freetype1/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv2765/devel
Modified Files:
.cvsignore sources
Added Files:
freetype-1.3.1-1.4pre.patch freetype-1.4-disable-ft1-bci.patch
freetype1.spec
Log Message:
auto-import freetype1-1.4-0.2.pre on branch devel from freetype1-1.4-0.2.pre.src.rpm
freetype-1.3.1-1.4pre.patch:
--- NEW FILE freetype-1.3.1-1.4pre.patch ---
diff -ur freetype-1.3.1/FILES freetype-pre1.4/FILES
--- freetype-1.3.1/FILES 1999-08-20 08:11:40.000000000 +0200
+++ freetype-pre1.4/FILES 2000-02-23 18:43:28.000000000 +0100
@@ -31,9 +31,6 @@
po/ Contributions to the internationalized error
message strings extension.
- pascal/lib Pascal engine source directory.
- pascal/test Pascal test programs.
-
The following files might be helpful:
diff -ur freetype-1.3.1/INSTALL freetype-pre1.4/INSTALL
--- freetype-1.3.1/INSTALL 1999-11-30 06:07:57.000000000 +0100
+++ freetype-pre1.4/INSTALL 2000-02-23 18:43:28.000000000 +0100
@@ -1,5 +1,5 @@
- The FreeType compilation guide
+ The FreeType compilation guide
Table of contents
@@ -29,9 +29,6 @@
IV. Compiling the Pascal source
- 1. Compiling the library
- 2. Compiling the test programs
- 3. Porting the library to a different Pascal compiler
--------------------------------------------------------------------
@@ -53,15 +50,15 @@
********************************************************************
- This package, known as the FreeType 1.3.1 Public Release, contains
+ This package, known as the FreeType 1.4 Public Release, contains
several things which are best described by the directories
containing them:
- `lib'
- Contains the 1.3.1 release of the FreeType library. It is written
- in portable ANSI C and should compile fine with any type of
- ANSI C compiler.
+ Contains the 1.4 release of the FreeType library. It is written
+ in portable ANSI C and should compile fine with any type of ANSI
+ C compiler.
Note however that some system-specific files are provided in the
`lib/arch' directory, in order to provide enhanced performance.
@@ -76,17 +73,6 @@
that some of these programs might not compile on all platforms,
as they need to display graphics.
- - `pascal'
-
- Contains the Pascal version of FreeType's source code. Note
- that the library has been successfully compiled with Turbo
- Pascal 6, Borland Pascal 7, Virtual Pascal, Free Pascal,
- Delphi 1, 2 and 3.
-
- The pascal source tree contains its own test programs which
- should *only* run with either Borland or Virtual Pascal
- compilers.
-
- `po'
On Unix, all of FreeType test programs support
@@ -154,7 +140,8 @@
library.
This release also provides configuration files for the following
- systems: MS-DOS, OS/2, Unix, VMS, Win 16, Amiga OS, and Win 32.
+ systems: MS-DOS, OS/2, Unix, VMS, Win 16, Win 32, Amiga OS, Mac,
+ and BeOS.
Make sure, when compiling each source file of the FreeType
library, to include the path to your configuration file in your
@@ -688,7 +675,8 @@
interpreter, as it provides a much easier windowed interface
through the use of the Turbo Vision library. The C debugger is
mainly used to check that both Pascal and C sources produce the
- same output.
+ same output. The Pascal debugger is available in the `ftpascal'
+ package, it is not included with this release.
You will need gcc to compile the debugger. It uses a special
build of the FreeType engine to work. Follow these steps to
@@ -731,149 +719,9 @@
IV. Compiling the Pascal source
===============================
- This section deals with the compilation of the Pascal version of
- the FreeType engine, whose source code is located in the `pascal'
- directory.
-
- Note that the Pascal version is more limited than the C one, as it
- lacks the following `features':
-
- - Extensions are neither supported nor provided in Pascal.
-
- - The interpreter is more pedantic than the C one and will
- probably not work with many broken glyphs.
-
- - It doesn't compile on old Turbo Pascal (TP 6.0 is a minimum), as
- it uses inline assembly code.
-
- Other than that, the Pascal version supports charmaps and the name
- table correctly since the 1.3 release.
-
-********************************************************************
-* *
-* AN IMPORTANT NOTE REGARDING TURBO AND BORLAND PASCAL USERS *
-* ========================================================== *
-* *
-* Programs compiled with TP6 and BP7 might not be able to run on *
-* fast machines! *
-* *
-* Usually, the program aborts immediately with a message like *
-* *
-* Runtime error 200: Divide by zero at xxxx:xxxx *
-* *
-* The bug is located in the runtime's initialization routine *
-* used to compute the machine's speed. It does so by dividing a *
-* value taken through the BIOS timer by a small constant. *
-* *
-* On fast machines, the result exceeds 16 bits, which causes a *
-* CPU exception/interrupt. The latter is caught by the *
-* runtime's exception handlers which aborts the execution and *
-* prints the above message. *
-* *
-* We don't know anything that can be done to fix this bug, as it *
-* would need a recompilation of a version of the Borland runtime *
-* initialization code. *
-* *
-********************************************************************
-
- Due to lack of time, the library could not be fully tested under
- TP6 or BP7.
-
-
- 1. Compiling the library
- ------------------------
-
- The library itself is located in `pascal/lib'. You can compile
- it very simply by invoking your Pascal compiler on the file
- `freetype.pas'.
-
- As always with Pascal, dependencies are resolved automatically.
-
-
- 2. Compiling the test programs
- ------------------------------
-
- The test programs are located in `pascal/test'. You will mainly
- find there the following:
-
- lint - A TrueType glyph loading checker. This test program
- will simply load each glyph in a font file and check
- for errors in its hinting programs. It is useful to
- find broken glyphs in fonts.
-
- view - A simple TrueType glyph viewer. Shows all the glyphs
- within a given font file on a graphics screen. Only
- works under DOS (with Borland Pascal) and OS/2 (with
- Virtual Pascal).
-
- timer - A simple benchmark program for the scan-line
- converter. Similar to the C `fttimer' test program.
-
- debugger - A TrueType bytecode debugger. This one must be
- compiled with the Turbo Vision library. It uses a
- rather advanced windowed interface to display the
- glyph program and their execution. It can also
- display the current glyph in a graphics window. A
- bit rough but extremely useful to the development
- of FreeType.
-
- dump - A TrueType metrics checker. This test program simply
- checks that the hinted width of each glyph corresponds
- to the one found in the TrueType `hdmx' table when
- present. This program is now obsolete and should be
- ignored.
-
- As always, simply invoke the root source file to make an
- executable automatically -- don't forget to include the path to
- the FreeType unit as described in section III.1.
-
-
- 3. Porting the library to a different Pascal compiler
- -----------------------------------------------------
-
- The Pascal sources use inline assembly to implement the 64-bit
- computation routines needed by the TrueType engine. This
- release comes with various versions of the `ttcalc' inline
- assembly.
[...11268 lines suppressed...]
ft_basename( filename ),
+ res,
pt_size,
+ imetrics.x_ppem,
hinted ? "on" : "off",
has_kern ? " kerning: " : "",
has_kern ? ( use_kern ? "on" : "off" ) : "",
has_sbit ? " sbit: " : "",
has_sbit ? ( use_sbit ? "on" : "off" ) : "",
has_gsub ? " GSUB: " : "",
- has_gsub ? ( use_gsub ? "on" : "off" ) : "" );
+ has_gsub ? ( use_gsub ? "on" : "off" ) : "",
+ has_gpos ? " GPOS: " : "",
+ has_gpos ? ( use_gpos ? "on" : "off" ) : "" );
Display_Bitmap_On_Screen( Bit.bitmap, Bit.rows, Bit.cols );
diff -ur freetype-1.3.1/test/ftview.c freetype-pre1.4/test/ftview.c
--- freetype-1.3.1/test/ftview.c 1999-10-04 23:02:42.000000000 +0200
+++ freetype-pre1.4/test/ftview.c 2000-02-24 10:35:23.000000000 +0100
@@ -2,11 +2,10 @@
/* */
/* The FreeType project -- a free and portable quality TrueType renderer. */
/* */
-/* Copyright 1996-1999 by */
+/* Copyright 1996-2000 by */
/* D. Turner, R.Wilhelm, and W. Lemberg */
/* */
-/* ftview: A simple font viewer. Now supports hinting and grayscaling */
-/* with the '-g' option. */
+/* ftview: A simple font viewer. Supports hinting and grayscaling. */
/* */
/* */
/* Keys: */
@@ -79,37 +78,35 @@
*/
#define Ignore_Err_Not_SBit 1
- char Header[128];
+ TT_Engine engine;
- TT_Engine engine;
-
- TT_Face face;
- TT_Instance instance;
- TT_Glyph glyph;
- TT_CharMap char_map;
+ TT_Face face;
+ TT_Instance instance;
+ TT_Glyph glyph;
TT_Big_Glyph_Metrics metrics;
TT_Outline outline;
TT_Face_Properties properties;
TT_Instance_Metrics imetrics;
- TT_SBit_Image* sbit;
+ TT_SBit_Image* sbit;
+
+ int num_glyphs;
- int num_glyphs;
+ int ptsize;
+ int hinted;
- int ptsize;
- int hinted;
+ char Header[128];
int Rotation;
int Fail;
int Num;
- unsigned char autorun;
int gray_render;
unsigned int sbit_flag; /* 0 if to display outlines
- * 1 if to use embedded bitmaps
- * 2 if to show sbit and outline glyphs
- */
+ * 1 if to use embedded bitmaps
+ * 2 if to show sbit and outline glyphs
+ */
int glyph_has_sbit;
@@ -120,10 +117,11 @@
TT_Error error;
TT_SBit_Strike strike;
+
if ( (error = TT_Set_Instance_PointSize( instance, pointSize )) )
{
RestoreScreen();
- fprintf( stderr, "Error = 0x%x.\n", (int)error );
+ fprintf( stderr, "Error = 0x%x.\n", (unsigned)error );
Panic( "Could not reset instance.\n" );
}
TT_Get_Instance_Metrics( instance, &imetrics );
@@ -144,8 +142,7 @@
}
- static TT_Error LoadTrueTypeChar( int idx,
- int hint )
+ static TT_Error LoadTrueTypeChar( int idx, int hint )
{
int flags;
@@ -158,10 +155,9 @@
}
- static TT_Error Render_All( int first_glyph,
- int ptsize )
+ static TT_Error Render_All( int first_glyph, int ptsize )
{
- TT_F26Dot6 start_x, start_y, step_x, step_y, x, y;
+ TT_F26Dot6 start_x, start_y, step_y, x, y;
int i;
TT_Error error = 0;
@@ -170,7 +166,6 @@
start_x = 4;
start_y = vio_Height - ( ( ptsize * 96 + 36 ) / 72 + 10 );
- step_x = imetrics.x_ppem + 4;
step_y = imetrics.y_ppem + 10;
x = start_x;
@@ -187,9 +182,9 @@
Blit_Bitmap( &Bit,
&sbit->map,
gray_render ? 8 : 1,
- x + (sbit->metrics.horiBearingX/64),
- Bit.rows - y - (sbit->metrics.horiBearingY/64),
- gray_palette[4] );
+ (int)x + (int)(sbit->metrics.horiBearingX/64),
+ Bit.rows - (int)y - (int)(sbit->metrics.horiBearingY/64),
+ gray_palette[4] );
metrics = sbit->metrics;
goto Step;
}
@@ -201,7 +196,7 @@
TT_Get_Glyph_Outline( glyph, &outline );
TT_Get_Glyph_Big_Metrics( glyph, &metrics );
- Render_Single_Glyph( gray_render, glyph, x, y );
+ Render_Single_Glyph( gray_render, glyph, (int)x, (int)y );
}
else
{
@@ -270,24 +265,25 @@
static void usage( char* execname )
{
- fprintf( stderr, "\n" );
- fprintf( stderr, "ftview: simple TrueType interpreter tester -- part of the FreeType project\n" );
- fprintf( stderr, "--------------------------------------------------------------------------\n" );
- fprintf( stderr, "\n" );
- fprintf( stderr, "Usage: %s [options below] ppem fontname[.ttf|.ttc] ...\n",
- execname );
- fprintf( stderr, "\n" );
- fprintf( stderr, " -g gray-level rendering (default: none)\n" );
- fprintf( stderr, " -r R use resolution R dpi (default: 96)\n" );
- fprintf( stderr, " -B use embedded bitmaps (default: none)\n" );
- fprintf( stderr, "\n" );
+ fprintf( stderr,
+ "\n"
+ "ftview: simple TrueType interpreter tester -- part of the FreeType project\n"
+ "--------------------------------------------------------------------------\n"
+ "\n"
+ "Usage: %s [options below] ppem fontname[.ttf|.ttc] ...\n",
+ execname );
+ fprintf( stderr,
+ "\n"
+ " -g gray-level rendering (default: none)\n"
+ " -r R use resolution R dpi (default: 96)\n"
+ " -B use embedded bitmaps (default: none)\n"
+ "\n" );
exit( EXIT_FAILURE );
}
- int main( int argc,
- char** argv )
+ int main( int argc, char** argv )
{
int i, old_ptsize, orig_ptsize, file;
int XisSetup = 0;
@@ -396,7 +392,8 @@
if ( error == TT_Err_Could_Not_Open_File )
Panic( "Could not find/open %s.\n", filename );
else if ( error )
- Panic( "Error while opening %s, code = 0x%x.\n", filename, error );
+ Panic( "Error while opening %s, error code = 0x%x.\n",
+ filename, error );
/* get face properties and allocate preload arrays */
freetype-1.4-disable-ft1-bci.patch:
--- NEW FILE freetype-1.4-disable-ft1-bci.patch ---
--- freetype-pre1.4/ft_conf.h.in.disable-ft1-bci 1999-09-03 09:09:55.000000000 -0400
+++ freetype-pre1.4/ft_conf.h.in 2003-06-09 18:17:28.000000000 -0400
@@ -93,7 +93,7 @@
/* emerged recently on the FreeType lists. We still do not have Apple's */
/* opinion on the subject and will change this as soon as we have. */
-#undef TT_CONFIG_OPTION_NO_INTERPRETER
+#define TT_CONFIG_OPTION_NO_INTERPRETER
/*************************************************************************/
--- NEW FILE freetype1.spec ---
# Disables bytecode interpreter. Setting to 0 enables
# the bytecode interpreter
%define without_bytecode_interpreter 1
Name: freetype1
Version: 1.4
Release: 0.2.pre%{?dist}
Summary: Free TrueType font rendering engine, compatibility version
Group: System Environment/Libraries
License: BSD-like
URL: http://www.freetype.org
# notice we don't use %{version} as this package is based on 1.3.1, which is
# then patched to a 1.4 pre release.
Source: http://dl.sf.net/sourceforge/freetype/freetype-1.3.1.tar.gz
Patch0: freetype-1.3.1-1.4pre.patch
Patch1: freetype-1.4-disable-ft1-bci.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: zlib-devel libXt-devel gettext
%description
The FreeType engine is a free and portable TrueType font rendering engine,
developed to provide TrueType support for a variety of platforms and
environments. FreeType is a library which can open and manages font files as
well as efficiently load, hint and render individual glyphs. FreeType is not a
font server or a complete text-rendering library.
This package contains the obsolote version 1.x of FreeType for applications
which still need this old version. New applications should use the more
advanced FreeType 2.x library packaged as freetype.
%package utils
Summary: A collection of FreeType 1.x utilities
Group: System Environment/Libraries
Requires: %{name} = %{version}-%{release}
# Upgrade path
Provides: freetype-utils = 1:%{version}-%{release}
Obsoletes: freetype-utils < 1:%{version}-%{release}
%description utils
Various utilities for the FreeType 1.x TrueType font rendering engine.
%package devel
Summary: FreeType 1.x development libraries and header files
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
Requires: zlib-devel
%description devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}.
%prep
%setup -q -n freetype-1.3.1
%patch0 -p1
%if %{without_bytecode_interpreter}
%patch1 -p1 -b .disable-ft1-bci
%endif
%build
# Work around code generation problem with strict-aliasing
# https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=118021
#
export CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing"
export CXXFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing"
%configure --disable-debug --disable-static --enable-shared \
--with-locale-dir=%{_datadir}/locale
# Don't use rpath!
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
# Don't use %%{?_smp_mflags} as that breaks the build
make
%install
rm -rf $RPM_BUILD_ROOT
# "make install DESTDIR=$RPM_BUILD_ROOT" doesn't work.
%makeinstall gnulocaledir=$RPM_BUILD_ROOT%{_datadir}/locale
%find_lang freetype
mkdir -p $RPM_BUILD_ROOT/%{_includedir}/freetype1
mv $RPM_BUILD_ROOT/%{_includedir}/freetype $RPM_BUILD_ROOT/%{_includedir}/freetype1
# freetype-demos installs new versions of these
rm $RPM_BUILD_ROOT%{_bindir}/ftdump $RPM_BUILD_ROOT%{_bindir}/ftlint
rm $RPM_BUILD_ROOT%{_libdir}/libttf.la
%clean
rm -rf $RPM_BUILD_ROOT
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files -f freetype.lang
%defattr(-,root,root)
%{_libdir}/libttf.so.*
%doc README announce docs
%files utils
%defattr(-,root,root)
%{_bindir}/fterror
%{_bindir}/ftmetric
%{_bindir}/ftsbit
%{_bindir}/ftstrpnm
%files devel
%defattr(-,root,root)
%{_libdir}/libttf.so
%{_includedir}/freetype1
%changelog
* Thu Oct 19 2006 Hans de Goede <j.w.r.degoede at hhs.nl> 1.4-0.2.pre
- Base on freetype-1.3.1.tar.gz + a patch with the changes contained
in the 1.4pre tarbal found in previous Fedora Core freetype releases
- Cleanup and FE-ize the spec file
- Don't reautoconf as that doesn't seem nescesarry
- Fix (remove) use of rpath
- Don't include static libs and .la files
- Give the freetype1-utils Obsoletes and Provides an Epoch instead of
using a 2.x version.
* Thu Jul 13 2006 Behdad Esfahbod <besfahbo at redhat.com> 1.4-0.1.pre
- Created based on freetype-2.1.10-6 spec
Index: .cvsignore
===================================================================
RCS file: /cvs/extras/rpms/freetype1/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore 11 Jan 2007 12:42:26 -0000 1.1
+++ .cvsignore 11 Jan 2007 12:43:18 -0000 1.2
@@ -0,0 +1 @@
+freetype-1.3.1.tar.gz
Index: sources
===================================================================
RCS file: /cvs/extras/rpms/freetype1/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources 11 Jan 2007 12:42:26 -0000 1.1
+++ sources 11 Jan 2007 12:43:18 -0000 1.2
@@ -0,0 +1 @@
+9a9e7ad00c1ef6dfbf8f8e19ceefb300 freetype-1.3.1.tar.gz
More information about the fedora-extras-commits
mailing list