Skip to content
This repository has been archived by the owner on Feb 2, 2023. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
8283323: libharfbuzz optimization level results in extreme build times
Reviewed-by: dcherepanov
Backport-of: 2c43ecb43fa3c94b69478039f1cd70ed4a577768
  • Loading branch information
Yuri Nesterenko committed Dec 12, 2022
1 parent c9232df commit 3493d0e
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion make/lib/Awt2dLibraries.gmk
Expand Up @@ -587,7 +587,6 @@ else

endif


LIBFONTMANAGER_EXTRA_HEADER_DIRS := \
libharfbuzz \
libharfbuzz/hb-ucdn \
Expand All @@ -604,6 +603,14 @@ BUILD_LIBFONTMANAGER_FONTLIB += $(LIBFREETYPE_LIBS)

LIBFONTMANAGER_OPTIMIZATION := HIGHEST

ifneq ($(filter $(TOOLCHAIN_TYPE), gcc clang), )
# gcc (and to an extent clang) is particularly bad at optimizing these files,
# causing a massive spike in compile time. We don't care about these
# particular files anyway, so lower optimization level.
BUILD_LIBFONTMANAGER_hb-subset.cc_OPTIMIZATION := SIZE
BUILD_LIBFONTMANAGER_hb-subset-plan.cc_OPTIMIZATION := SIZE
endif

ifeq ($(call isTargetOs, windows), true)
LIBFONTMANAGER_EXCLUDE_FILES += X11FontScaler.c \
X11TextRenderer.c
Expand Down

1 comment on commit 3493d0e

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.