[Libreoffice-commits] core.git: Branch 'feature/commonsallayout' - 3 commits - config_host.mk.in configure.ac RepositoryExternal.mk vcl/source
Khaled Hosny
khaledhosny at eglug.org
Thu Sep 22 17:50:33 UTC 2016
RepositoryExternal.mk | 14 --------
config_host.mk.in | 1
configure.ac | 62 +++++++++++++++----------------------
vcl/source/gdi/CommonSalLayout.cxx | 2 -
4 files changed, 27 insertions(+), 52 deletions(-)
New commits:
commit 229558d95e1b247e312c107802bb308cce549845
Author: Khaled Hosny <khaledhosny at eglug.org>
Date: Thu Sep 22 19:48:10 2016 +0200
Always pass BCP 47 tags to HarfBuzz
This is what it is expecting anyway, no need to special case it for
Chinese.
Change-Id: I6732412375d19816b599005d78abd796f67599ee
diff --git a/vcl/source/gdi/CommonSalLayout.cxx b/vcl/source/gdi/CommonSalLayout.cxx
index ea4e5f9..c3d7157 100644
--- a/vcl/source/gdi/CommonSalLayout.cxx
+++ b/vcl/source/gdi/CommonSalLayout.cxx
@@ -379,7 +379,7 @@ bool CommonSalLayout::LayoutText(ImplLayoutArgs& rArgs)
aHbScript = it->maScript;
// hb_language_from_string() accept ISO639-3 language tag except for Chinese.
LanguageTag &rTag = rArgs.maLanguageTag;
- OString sLanguage = OUStringToOString( MsLangId::isChinese(rTag.getLanguageType()) ? rTag.getBcp47():rTag.getLanguage() , RTL_TEXTENCODING_UTF8 );
+ OString sLanguage = OUStringToOString(rTag.getBcp47(), RTL_TEXTENCODING_UTF8);
int nHbFlags = HB_BUFFER_FLAGS_DEFAULT;
if (nMinRunPos == 0)
commit 400a7faf260997b481b130df3a5c1b5d91e073eb
Author: Khaled Hosny <khaledhosny at eglug.org>
Date: Thu Sep 22 19:45:23 2016 +0200
Always build HarfBuzz everywhere
It is no longer an optional feature on any platform. The
--enable-graphite stuff is kept as it controls the old Graphite
integration code and it should be removed without.
Change-Id: Ib4d76bba782a1439f02f93411b22d237a1987ea5
diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk
index e0f1337..64eeacf 100644
--- a/RepositoryExternal.mk
+++ b/RepositoryExternal.mk
@@ -1357,8 +1357,6 @@ endef
endif # SYSTEM_FONTCONFIG
-ifeq ($(ENABLE_GRAPHITE),TRUE)
-
ifneq ($(SYSTEM_GRAPHITE),)
define gb_LinkTarget__use_graphite
@@ -1386,12 +1384,6 @@ endef
endif # SYSTEM_GRAPHITE
-else # !ENABLE_GRAPHITE
-
-gb_LinkTarget__use_graphite :=
-
-endif # ENABLE_GRAPHITE
-
ifneq ($(SYSTEM_ICU),)
gb_LinkTarget__use_icu_headers:=
diff --git a/configure.ac b/configure.ac
index be56b53..51a51d1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -9231,19 +9231,20 @@ AC_SUBST(ICU_LIBS)
dnl ===================================================================
dnl Graphite
dnl ===================================================================
+libo_CHECK_SYSTEM_MODULE([graphite],[GRAPHITE],[graphite2 >= 0.9.3],["-I${WORKDIR}/UnpackedTarball/graphite/include"],["-L${WORKDIR}/LinkTarget/StaticLibrary -lgraphite"])
+if test "$with_system_graphite" = "yes"; then
+ libo_MINGW_CHECK_DLL([libgraphite2])
+fi
+if test "$COM" = "MSC"; then # override the above
+ GRAPHITE_LIBS="${WORKDIR}/LinkTarget/StaticLibrary/graphite.lib"
+fi
+# This is the old Graphite support that will eventually be removed
AC_MSG_CHECKING([whether to enable graphite support])
if test $_os != Darwin -a $_os != Android -a $_os != iOS -a \( -z "$enable_graphite" -o "$enable_graphite" != no \); then
AC_MSG_RESULT([yes])
ENABLE_GRAPHITE="TRUE"
AC_DEFINE(ENABLE_GRAPHITE)
- libo_CHECK_SYSTEM_MODULE([graphite],[GRAPHITE],[graphite2 >= 0.9.3],["-I${WORKDIR}/UnpackedTarball/graphite/include"],["-L${WORKDIR}/LinkTarget/StaticLibrary -lgraphite"])
- if test "$with_system_graphite" = "yes"; then
- libo_MINGW_CHECK_DLL([libgraphite2])
- fi
- if test "$COM" = "MSC"; then # override the above
- GRAPHITE_LIBS="${WORKDIR}/LinkTarget/StaticLibrary/graphite.lib"
- fi
else
AC_MSG_RESULT([no])
@@ -9330,6 +9331,9 @@ if test "$COM" = "MSC"; then # override the above
HARFBUZZ_LIBS="${WORKDIR}/UnpackedTarball/harfbuzz/src/.libs/libharfbuzz.lib"
fi
if test "$with_system_harfbuzz" = "yes"; then
+ if test "$with_system_graphite" = "no"; then
+ AC_MSG_ERROR([--with-system-graphite must be used when --with-system-harfbuzz is used])
+ fi
AC_MSG_CHECKING([whether system Harfbuzz is built with Graphite support])
_save_libs="$LIBS"
_save_cflags="$CFLAGS"
@@ -9338,6 +9342,10 @@ if test "$with_system_harfbuzz" = "yes"; then
AC_CHECK_FUNC(hb_graphite2_face_get_gr_face,,[AC_MSG_ERROR([Harfbuzz needs to be built with Graphite support.])])
LIBS="$_save_libs"
CFLAGS="$_save_cflags"
+else
+ if test "$with_system_graphite" = "yes"; then
+ AC_MSG_ERROR([--without-system-graphite must be used when --without-system-harfbuzz is used])
+ fi
fi
AC_MSG_CHECKING([whether to use X11])
commit 9b9203630b5e6417daa4118d696e515e918c64ea
Author: Khaled Hosny <khaledhosny at eglug.org>
Date: Thu Sep 22 19:29:04 2016 +0200
Always build HarfBuzz everywhere
It is no longer an optional feature on any platform.
Change-Id: I70cdcd2c0df69d961ecc5f36b4e8d035d251ef16
diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk
index 95241ab..e0f1337 100644
--- a/RepositoryExternal.mk
+++ b/RepositoryExternal.mk
@@ -1490,7 +1490,6 @@ endef
endif # SYSTEM_ICU
-ifeq ($(ENABLE_HARFBUZZ),TRUE)
ifneq ($(SYSTEM_HARFBUZZ),)
define gb_LinkTarget__use_harfbuzz
@@ -1515,11 +1514,6 @@ $(call gb_LinkTarget_use_external_project,$(1),harfbuzz)
endef
endif # SYSTEM_HARFBUZZ
-else # ENABLE_HARFBUZZ != YES
-
-gb_LinkTarget__use_harfbuzz :=
-
-endif # ENABLE_HARFBUZZ
ifeq ($(DISABLE_OPENSSL),TRUE)
diff --git a/config_host.mk.in b/config_host.mk.in
index 25b9609..c467a14 100644
--- a/config_host.mk.in
+++ b/config_host.mk.in
@@ -133,7 +133,6 @@ export ENABLE_FIREBIRD_SDBC=@ENABLE_FIREBIRD_SDBC@
export ENABLE_GIO=@ENABLE_GIO@
export ENABLE_GRAPHITE=@ENABLE_GRAPHITE@
export ENABLE_ORCUS=@ENABLE_ORCUS@
-export ENABLE_HARFBUZZ=@ENABLE_HARFBUZZ@
export ENABLE_GLTF=@ENABLE_GLTF@
export SYSTEM_LIBGLTF=@SYSTEM_LIBGLTF@
export LIBGLTF_CFLAGS=@LIBGLTF_CFLAGS@
diff --git a/configure.ac b/configure.ac
index 285a871..be56b53 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2135,12 +2135,6 @@ AC_ARG_WITH(iwyu,
Use only if you are hacking on it.]),
,)
-AC_ARG_WITH(harfbuzz,
- AS_HELP_STRING([--with-harfbuzz],
- [Enable HarfBuzz support regardless of the platform.
- Experimental only. Use only if working on it.]),
-,)
-
dnl ===================================================================
dnl Branding
dnl ===================================================================
@@ -9331,32 +9325,20 @@ AC_SUBST(ENABLE_ORCUS)
dnl ===================================================================
dnl HarfBuzz
dnl ===================================================================
-AC_MSG_CHECKING([whether to enable HarfBuzz support])
-if test "$with_harfbuzz" = "yes" -o \( $_os != WINNT -a $_os != Darwin -a $_os != iOS \); then
- AC_MSG_RESULT([yes])
- ENABLE_HARFBUZZ="TRUE"
- if $PKG_CONFIG --atleast-version 0.9.18 harfbuzz; then
- libo_CHECK_SYSTEM_MODULE([harfbuzz],[HARFBUZZ],[harfbuzz-icu >= 0.9.18],["-I${WORKDIR}/UnpackedTarball/harfbuzz/src"],["-L${WORKDIR}/UnpackedTarball/harfbuzz/src/.libs -lharfbuzz"])
- else
- libo_CHECK_SYSTEM_MODULE([harfbuzz],[HARFBUZZ],[harfbuzz >= 0.9.10],[-I${WORKDIR}/UnpackedTarball/harfbuzz/src],["-L${WORKDIR}/UnpackedTarball/harfbuzz/src/.libs -lharfbuzz"])
- fi
- if test "$COM" = "MSC"; then # override the above
- HARFBUZZ_LIBS="${WORKDIR}/UnpackedTarball/harfbuzz/src/.libs/libharfbuzz.lib"
- fi
- if test "$with_system_harfbuzz" = "yes"; then
- AC_MSG_CHECKING([whether system Harfbuzz is built with Graphite support])
- _save_libs="$LIBS"
- _save_cflags="$CFLAGS"
- LIBS="$LIBS $HARFBUZZ_LIBS"
- CFLAGS="$CFLAGS $HARFBUZZ_CFLAGS"
- AC_CHECK_FUNC(hb_graphite2_face_get_gr_face,,[AC_MSG_ERROR([Harfbuzz needs to be built with Graphite support.])])
- LIBS="$_save_libs"
- CFLAGS="$_save_cflags"
- fi
-else
- AC_MSG_RESULT([no])
+libo_CHECK_SYSTEM_MODULE([harfbuzz],[HARFBUZZ],[harfbuzz-icu >= 0.9.18],["-I${WORKDIR}/UnpackedTarball/harfbuzz/src"],["-L${WORKDIR}/UnpackedTarball/harfbuzz/src/.libs -lharfbuzz"])
+if test "$COM" = "MSC"; then # override the above
+ HARFBUZZ_LIBS="${WORKDIR}/UnpackedTarball/harfbuzz/src/.libs/libharfbuzz.lib"
+fi
+if test "$with_system_harfbuzz" = "yes"; then
+ AC_MSG_CHECKING([whether system Harfbuzz is built with Graphite support])
+ _save_libs="$LIBS"
+ _save_cflags="$CFLAGS"
+ LIBS="$LIBS $HARFBUZZ_LIBS"
+ CFLAGS="$CFLAGS $HARFBUZZ_CFLAGS"
+ AC_CHECK_FUNC(hb_graphite2_face_get_gr_face,,[AC_MSG_ERROR([Harfbuzz needs to be built with Graphite support.])])
+ LIBS="$_save_libs"
+ CFLAGS="$_save_cflags"
fi
-AC_SUBST(ENABLE_HARFBUZZ)
AC_MSG_CHECKING([whether to use X11])
dnl ***************************************
More information about the Libreoffice-commits
mailing list