Skip to content

Commit

Permalink
Update FreeType from Chromium 112.0.5615.134
Browse files Browse the repository at this point in the history
Reviewed-on: #2115
  • Loading branch information
dahlstrom-g authored Dec 19, 2023
2 parents dee7f54 + 19a8aef commit e5680fb
Show file tree
Hide file tree
Showing 84 changed files with 1,387 additions and 2,116 deletions.
4 changes: 2 additions & 2 deletions third_party/freetype2/METADATA
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ third_party {
type: GIT
value: "https://chromium.googlesource.com/chromium/src/third_party/freetype2"
}
# Note: version is 2.13.0 release.
version: "de8b92dd7ec634e9e2b25ef534c54a3537555c11"
version: "e78e2d29a95baf6053e30cc9422aa20319259803"
# from https://chromium.googlesource.com/chromium/src/+/112.0.5615.134/DEPS#353
last_upgrade_date {
year: 2023
month: 05
Expand Down
14 changes: 0 additions & 14 deletions third_party/freetype2/README.cobalt

This file was deleted.

6 changes: 5 additions & 1 deletion third_party/freetype2/builds/meson/parse_modules_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,12 @@ def generate_ftmodule(lists):

for module in lists["AUX_MODULES"]:
if module in ("psaux", "psnames", "otvalid", "gxvalid"):
name = {
"gxvalid": "gxv",
"otvalid": "otv",
}.get(module, module)
result += (
"FT_USE_MODULE( FT_Module_Class, %s_module_class )\n" % module
"FT_USE_MODULE( FT_Module_Class, %s_module_class )\n" % name
)

result += "/* EOF */\n"
Expand Down
2 changes: 1 addition & 1 deletion third_party/freetype2/builds/toplevel.mk
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,6 @@ do-dist: distclean refdoc
rm -f $(TOP_DIR)/docs/mkdocs.yml

@# Remove more stuff related to git.
rm -rf (TOP_DIR)/subprojects/dlg
rm -rf $(TOP_DIR)/subprojects/dlg

# EOF
Binary file removed third_party/freetype2/builds/vms/LIBS.OPT_IA64
Binary file not shown.
Binary file removed third_party/freetype2/builds/vms/_LINK.OPT_IA64
Binary file not shown.
2 changes: 2 additions & 0 deletions third_party/freetype2/builds/vms/apinames_vms.bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
src/tools/apinames -wV include/freetype/*.h > freetype_vms0.opt
mv freetype_vms0.opt freetype_vms.opt
28 changes: 0 additions & 28 deletions third_party/freetype2/builds/vms/vmslib.dat

This file was deleted.

16 changes: 8 additions & 8 deletions third_party/freetype2/builds/windows/vc2010/freetype.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@
<WarningLevel>Level4</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>4001</DisableSpecificWarnings>
<DisableSpecificWarnings>4001;4267</DisableSpecificWarnings>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName>
<InlineFunctionExpansion>Disabled</InlineFunctionExpansion>
Expand All @@ -195,7 +195,7 @@
<WarningLevel>Level4</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>4001</DisableSpecificWarnings>
<DisableSpecificWarnings>4001;4267</DisableSpecificWarnings>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName>
<InlineFunctionExpansion>Disabled</InlineFunctionExpansion>
Expand Down Expand Up @@ -248,7 +248,7 @@
<WarningLevel>Level4</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>4001</DisableSpecificWarnings>
<DisableSpecificWarnings>4001;4267</DisableSpecificWarnings>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName>
<InlineFunctionExpansion>Disabled</InlineFunctionExpansion>
Expand All @@ -274,7 +274,7 @@
<WarningLevel>Level4</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>4001</DisableSpecificWarnings>
<DisableSpecificWarnings>4001;4267</DisableSpecificWarnings>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName>
<InlineFunctionExpansion>Disabled</InlineFunctionExpansion>
Expand Down Expand Up @@ -328,7 +328,7 @@
<DisableLanguageExtensions>true</DisableLanguageExtensions>
<WarningLevel>Level4</WarningLevel>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>4001</DisableSpecificWarnings>
<DisableSpecificWarnings>4001;4267</DisableSpecificWarnings>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<EnableEnhancedInstructionSet>NotSet</EnableEnhancedInstructionSet>
<IntrinsicFunctions>true</IntrinsicFunctions>
Expand Down Expand Up @@ -356,7 +356,7 @@
<DisableLanguageExtensions>true</DisableLanguageExtensions>
<WarningLevel>Level4</WarningLevel>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>4001</DisableSpecificWarnings>
<DisableSpecificWarnings>4001;4267</DisableSpecificWarnings>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<IntrinsicFunctions>true</IntrinsicFunctions>
</ClCompile>
Expand Down Expand Up @@ -409,7 +409,7 @@
<DisableLanguageExtensions>true</DisableLanguageExtensions>
<WarningLevel>Level4</WarningLevel>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>4001</DisableSpecificWarnings>
<DisableSpecificWarnings>4001;4267</DisableSpecificWarnings>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<EnableEnhancedInstructionSet>NotSet</EnableEnhancedInstructionSet>
<IntrinsicFunctions>true</IntrinsicFunctions>
Expand All @@ -435,7 +435,7 @@
<DisableLanguageExtensions>true</DisableLanguageExtensions>
<WarningLevel>Level4</WarningLevel>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>4001</DisableSpecificWarnings>
<DisableSpecificWarnings>4001;4267</DisableSpecificWarnings>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<IntrinsicFunctions>true</IntrinsicFunctions>
</ClCompile>
Expand Down
4 changes: 2 additions & 2 deletions third_party/freetype2/configure
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ rm -f config.mk builds/unix/unix-def.mk builds/unix/unix-cc.mk
# respect GNUMAKE environment variable for backward compatibility
if test "x$GNUMAKE" = x; then
if test "x$MAKE" = x; then
if test "x`make -v 2>/dev/null | grep -E 'GNU|makepp'`" = x; then
if test "x`make -v 2>/dev/null | sed -n -e '/GNU/p' -e '/makepp/p'`" = x; then
MAKE=gmake
else
MAKE=make
Expand All @@ -28,7 +28,7 @@ else
MAKE=$GNUMAKE
fi

if test "x`$MAKE -v 2>/dev/null | grep -E 'GNU|makepp'`" = x; then
if test "x`$MAKE -v 2>/dev/null | sed -n -e '/GNU/p' -e '/makepp/p'`" = x; then
echo "GNU make (>= 3.81) or makepp (>= 2.0) is required to build FreeType2." >&2
echo "Please try" >&2
echo >&2
Expand Down
47 changes: 7 additions & 40 deletions third_party/freetype2/devel/ftoption.h
Original file line number Diff line number Diff line change
Expand Up @@ -661,36 +661,12 @@ FT_BEGIN_HEADER
* not) instructions in a certain way so that all TrueType fonts look like
* they do in a Windows ClearType (DirectWrite) environment. See [1] for a
* technical overview on what this means. See `ttinterp.h` for more
* details on the LEAN option.
* details on this option.
*
* There are three possible values.
*
* Value 1:
* This value is associated with the 'Infinality' moniker, contributed by
* an individual nicknamed Infinality with the goal of making TrueType
* fonts render better than on Windows. A high amount of configurability
* and flexibility, down to rules for single glyphs in fonts, but also
* very slow. Its experimental and slow nature and the original
* developer losing interest meant that this option was never enabled in
* default builds.
*
* The corresponding interpreter version is v38.
*
* Value 2:
* The new default mode for the TrueType driver. The Infinality code
* base was stripped to the bare minimum and all configurability removed
* in the name of speed and simplicity. The configurability was mainly
* aimed at legacy fonts like 'Arial', 'Times New Roman', or 'Courier'.
* Legacy fonts are fonts that modify vertical stems to achieve clean
* black-and-white bitmaps. The new mode focuses on applying a minimal
* set of rules to all fonts indiscriminately so that modern and web
* fonts render well while legacy fonts render okay.
*
* The corresponding interpreter version is v40.
*
* Value 3:
* Compile both, making both v38 and v40 available (the latter is the
* default).
* The new default mode focuses on applying a minimal set of rules to all
* fonts indiscriminately so that modern and web fonts render well while
* legacy fonts render okay. The corresponding interpreter version is v40.
* The so-called Infinality mode (v38) is no longer available in FreeType.
*
* By undefining these, you get rendering behavior like on Windows without
* ClearType, i.e., Windows XP without ClearType enabled and Win9x
Expand All @@ -705,9 +681,7 @@ FT_BEGIN_HEADER
* [1]
* https://www.microsoft.com/typography/cleartype/truetypecleartype.aspx
*/
/* #define TT_CONFIG_OPTION_SUBPIXEL_HINTING 1 */
/* #define TT_CONFIG_OPTION_SUBPIXEL_HINTING 2 */
#define TT_CONFIG_OPTION_SUBPIXEL_HINTING ( 1 | 2 )
#define TT_CONFIG_OPTION_SUBPIXEL_HINTING
/**************************************************************************
Expand Down Expand Up @@ -977,21 +951,14 @@ FT_BEGIN_HEADER


/*
* The next three macros are defined if native TrueType hinting is
* The next two macros are defined if native TrueType hinting is
* requested by the definitions above. Don't change this.
*/
#ifdef TT_CONFIG_OPTION_BYTECODE_INTERPRETER
#define TT_USE_BYTECODE_INTERPRETER

#ifdef TT_CONFIG_OPTION_SUBPIXEL_HINTING
#if TT_CONFIG_OPTION_SUBPIXEL_HINTING & 1
#define TT_SUPPORT_SUBPIXEL_HINTING_INFINALITY
#endif

#if TT_CONFIG_OPTION_SUBPIXEL_HINTING & 2
#define TT_SUPPORT_SUBPIXEL_HINTING_MINIMAL
#endif
#endif
#endif


Expand Down
4 changes: 4 additions & 0 deletions third_party/freetype2/docs/CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,10 @@ CHANGES BETWEEN 2.12.1 and 2.13.0 (2023-Feb-09)
af_debug_hints_
```

- The internal zlib library was updated to version 1.2.13. Note,
however, that FreeType is *not* affected by CVE-2022-37434 since
it doesn't use the `inflateGetHeader` function.


======================================================================

Expand Down
49 changes: 28 additions & 21 deletions third_party/freetype2/docs/INSTALL.VMS
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
How to build the FreeType 2 library on VMS
-----------------------------------------
How to build the FreeType library on VMS
----------------------------------------

It is actually very straightforward to install the FreeType 2 library.
Just execute vms_make.com from the toplevel directory to build the
It is actually very straightforward to install the FreeType library.
Just execute `vms_make.com from` the toplevel directory to build the
library. This procedure currently accepts the following options:

DEBUG
* `DEBUG`
Build the library with debug information and without optimization.

lopts=<value>
Options to pass to the link command e.g. lopts=/traceback
* `lopts=<value>`
Options to pass to the link command, e.g., `lopts=/traceback`.

ccopt=<value>
Options to pass to the C compiler e.g. ccopt=/float=ieee
* `ccopt=<value>`
Options to pass to the C compiler, e.g., `ccopt=/float=ieee`.

In case you did download the demos, place them in a separate directory
sharing the same top level as the directory of FreeType 2 and follow
the same instructions as above for the demos from there. The build
process relies on this to figure out the location of the FreeType 2
sharing the same top level as the directory of FreeType and follow the
same instructions as above for the demos from there. The build
process relies on this to figure out the location of the FreeType
include files.


Expand All @@ -28,24 +28,31 @@ The library is available in the directory

[.LIB]

To compile applications using FreeType 2 you have to define the
logical FREETYPE pointing to the directory
To compile applications using FreeType you have to define the logical
`FREETYPE` pointing to the directory

[.INCLUDE.FREETYPE]

i.e., if the directory in which this INSTALL.VMS file is located is
$disk:[freetype] then define the logical with
i.e., if the directory in which this `INSTALL.VMS` file is located is
`$disk:[freetype.docs]`, then define the logical with

define freetype $disk:[freetype.include.freetype]

This version has been tested with Compaq C V6.2-006 on OpenVMS Alpha
V7.2-1.
See http://nchrem.tnw.tudelft.nl/openvms/software2.html#Freetype for
the packages FreeType depends on.

The latest versions were tested using
- VSI C V7.4-002 and DECWindows V1.7-F on OpenVMS Alpha V8.4-2L1
- VSI C V7.4-001 and DECWindows V1.7-E on OpenVMS IA64 V8.4-2L3

Any problems can be reported to

Jouk Jansen <[email protected]> or
Martin P.J. Zinser <[email protected]>
Any problems can be reported to

Jouk Jansen <[email protected]> or

Orginal version of the build procedures was created by

Martin P.J. Zinser <[email protected]>

------------------------------------------------------------------------

Expand Down
Loading

0 comments on commit e5680fb

Please sign in to comment.