Fridrich Strba 2023-03-23 06:19:20 +00:00 committed by Git OBS Bridge
parent 8c6747c5bb
commit 86343c777d
5 changed files with 218 additions and 83 deletions

View File

@ -18,11 +18,11 @@ Change-Id: I09f046f54b107b53c86f76a39553bd11ef03d9f6
delete mode 100644 ridljar/source/libreoffice/module-info.java delete mode 100644 ridljar/source/libreoffice/module-info.java
delete mode 100644 ridljar/source/unoloader/module-info.java delete mode 100644 ridljar/source/unoloader/module-info.java
diff --git a/configure.ac b/configure.ac Index: libreoffice-7.5.1.2/configure.ac
index f4850a8cb2dc..c2df878df1d7 100644 ===================================================================
--- a/configure.ac --- libreoffice-7.5.1.2.orig/configure.ac
+++ b/configure.ac +++ libreoffice-7.5.1.2/configure.ac
@@ -2313,7 +2313,7 @@ AC_ARG_WITH(linker-hash-style, @@ -2518,7 +2518,7 @@ AC_ARG_WITH(linker-hash-style,
AC_ARG_WITH(jdk-home, AC_ARG_WITH(jdk-home,
AS_HELP_STRING([--with-jdk-home=<absolute path to JDK home>], AS_HELP_STRING([--with-jdk-home=<absolute path to JDK home>],
@ -31,7 +31,7 @@ index f4850a8cb2dc..c2df878df1d7 100644
path here. Note that this is not the location of the java command but the path here. Note that this is not the location of the java command but the
location of the entire distribution. In case of cross-compiling, this location of the entire distribution. In case of cross-compiling, this
is the JDK of the host os. Use --with-build-platform-configure-options is the JDK of the host os. Use --with-build-platform-configure-options
@@ -8089,7 +8097,24 @@ if test "$ENABLE_JAVA" != "" -a "$cross_compiling" != "yes"; then @@ -8613,7 +8613,24 @@ if test "$ENABLE_JAVA" != "" -a "$cross_
elif test `$JAVAINTERPRETER -version 2>&1 | $AWK '{ print }' | $GREP -c "BEA"` -gt 0; then elif test `$JAVAINTERPRETER -version 2>&1 | $AWK '{ print }' | $GREP -c "BEA"` -gt 0; then
AC_MSG_ERROR([No valid check available. Please check the block for your desired java in configure.ac]) AC_MSG_ERROR([No valid check available. Please check the block for your desired java in configure.ac])
elif test `$JAVAINTERPRETER -version 2>&1 | $AWK '{ print }' | $GREP -c "IBM"` -gt 0; then elif test `$JAVAINTERPRETER -version 2>&1 | $AWK '{ print }' | $GREP -c "IBM"` -gt 0; then
@ -57,7 +57,7 @@ index f4850a8cb2dc..c2df878df1d7 100644
else else
JDK=sun JDK=sun
@@ -8097,10 +8122,10 @@ if test "$ENABLE_JAVA" != "" -a "$cross_compiling" != "yes"; then @@ -8621,10 +8638,10 @@ if test "$ENABLE_JAVA" != "" -a "$cross_
_jdk=`$JAVAINTERPRETER -version 2>&1 | $AWK -F'"' '{ print \$2 }' | $SED '/^$/d' | $SED s/[[-A-Za-z]]*//` _jdk=`$JAVAINTERPRETER -version 2>&1 | $AWK -F'"' '{ print \$2 }' | $SED '/^$/d' | $SED s/[[-A-Za-z]]*//`
_jdk_ver=`echo "$_jdk" | $AWK -F. '{ print (($1 * 100) + $2) * 100 + $3;}'` _jdk_ver=`echo "$_jdk" | $AWK -F. '{ print (($1 * 100) + $2) * 100 + $3;}'`
@ -70,8 +70,8 @@ index f4850a8cb2dc..c2df878df1d7 100644
+ if test "$_jdk_ver" -gt 10800; then + if test "$_jdk_ver" -gt 10800; then
JAVA_CLASSPATH_NOT_SET=TRUE JAVA_CLASSPATH_NOT_SET=TRUE
fi fi
dnl TODO: Presumably, the Security Manager will not merely be disallowed, but be
@@ -8116,7 +8141,7 @@ if test "$ENABLE_JAVA" != "" -a "$cross_compiling" != "yes"; then @@ -8646,7 +8663,7 @@ if test "$ENABLE_JAVA" != "" -a "$cross_
JAVACFLAGS=-J-Xmx128M JAVACFLAGS=-J-Xmx128M
fi fi
else else
@ -80,11 +80,11 @@ index f4850a8cb2dc..c2df878df1d7 100644
fi fi
else else
if test -z "$ENABLE_JAVA"; then if test -z "$ENABLE_JAVA"; then
diff --git a/jvmfwk/CustomTarget_jreproperties.mk b/jvmfwk/CustomTarget_jreproperties.mk Index: libreoffice-7.5.1.2/jvmfwk/CustomTarget_jreproperties.mk
index da509dbff5ac..ac8f7c053373 100644 ===================================================================
--- a/jvmfwk/CustomTarget_jreproperties.mk --- libreoffice-7.5.1.2.orig/jvmfwk/CustomTarget_jreproperties.mk
+++ b/jvmfwk/CustomTarget_jreproperties.mk +++ libreoffice-7.5.1.2/jvmfwk/CustomTarget_jreproperties.mk
@@ -17,7 +17,7 @@ $(call gb_CustomTarget_get_workdir,jvmfwk/jreproperties)/JREProperties.class : \ @@ -17,7 +17,7 @@ $(call gb_CustomTarget_get_workdir,jvmfw
$(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),JCS,1) $(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),JCS,1)
$(call gb_Trace_StartRange,$(subst $(WORKDIR)/,,$@),JCS) $(call gb_Trace_StartRange,$(subst $(WORKDIR)/,,$@),JCS)
$(call gb_Helper_abbreviate_dirs, \ $(call gb_Helper_abbreviate_dirs, \
@ -93,10 +93,10 @@ index da509dbff5ac..ac8f7c053373 100644
$(call gb_Trace_EndRange,$(subst $(WORKDIR)/,,$@),JCS) $(call gb_Trace_EndRange,$(subst $(WORKDIR)/,,$@),JCS)
# vim:set shiftwidth=4 tabstop=4 noexpandtab: # vim:set shiftwidth=4 tabstop=4 noexpandtab:
diff --git a/ridljar/Jar_libreoffice.mk b/ridljar/Jar_libreoffice.mk Index: libreoffice-7.5.1.2/ridljar/Jar_libreoffice.mk
index d34ae3f5ebda..4d0f5ef2545f 100644 ===================================================================
--- a/ridljar/Jar_libreoffice.mk --- libreoffice-7.5.1.2.orig/ridljar/Jar_libreoffice.mk
+++ b/ridljar/Jar_libreoffice.mk +++ libreoffice-7.5.1.2/ridljar/Jar_libreoffice.mk
@@ -7,7 +7,7 @@ @@ -7,7 +7,7 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/. # file, You can obtain one at http://mozilla.org/MPL/2.0/.
# #
@ -106,7 +106,7 @@ index d34ae3f5ebda..4d0f5ef2545f 100644
$(eval $(call gb_Jar_use_customtargets,libreoffice,\ $(eval $(call gb_Jar_use_customtargets,libreoffice,\
ridljar/javamaker \ ridljar/javamaker \
@@ -27,15 +27,9 @@ $(eval $(call gb_Jar_add_manifest_classpath,libreoffice, \ @@ -27,15 +27,9 @@ $(eval $(call gb_Jar_add_manifest_classp
$(if $(filter MACOSX,$(OS)),../../Frameworks/,../) \ $(if $(filter MACOSX,$(OS)),../../Frameworks/,../) \
)) ))
@ -122,10 +122,10 @@ index d34ae3f5ebda..4d0f5ef2545f 100644
)) ))
$(eval $(call gb_Jar_add_sourcefiles,libreoffice,\ $(eval $(call gb_Jar_add_sourcefiles,libreoffice,\
diff --git a/ridljar/Jar_unoloader.mk b/ridljar/Jar_unoloader.mk Index: libreoffice-7.5.1.2/ridljar/Jar_unoloader.mk
index 2acf20b5b289..50b32e8f0f88 100644 ===================================================================
--- a/ridljar/Jar_unoloader.mk --- libreoffice-7.5.1.2.orig/ridljar/Jar_unoloader.mk
+++ b/ridljar/Jar_unoloader.mk +++ libreoffice-7.5.1.2/ridljar/Jar_unoloader.mk
@@ -7,21 +7,12 @@ @@ -7,21 +7,12 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/. # file, You can obtain one at http://mozilla.org/MPL/2.0/.
# #
@ -149,10 +149,9 @@ index 2acf20b5b289..50b32e8f0f88 100644
$(eval $(call gb_Jar_add_sourcefiles,unoloader,\ $(eval $(call gb_Jar_add_sourcefiles,unoloader,\
ridljar/source/unoloader/com/sun/star/lib/unoloader/UnoClassLoader \ ridljar/source/unoloader/com/sun/star/lib/unoloader/UnoClassLoader \
ridljar/source/unoloader/com/sun/star/lib/unoloader/UnoLoader \ ridljar/source/unoloader/com/sun/star/lib/unoloader/UnoLoader \
diff --git a/ridljar/source/libreoffice/module-info.java b/ridljar/source/libreoffice/module-info.java Index: libreoffice-7.5.1.2/ridljar/source/libreoffice/module-info.java
deleted file mode 100644 ===================================================================
index 8d24c7ccb13c..000000000000 --- libreoffice-7.5.1.2.orig/ridljar/source/libreoffice/module-info.java
--- a/ridljar/source/libreoffice/module-info.java
+++ /dev/null +++ /dev/null
@@ -1,142 +0,0 @@ @@ -1,142 +0,0 @@
-/* -/*
@ -297,10 +296,9 @@ index 8d24c7ccb13c..000000000000
- exports com.sun.star.xml.xslt; - exports com.sun.star.xml.xslt;
- exports com.sun.star.xsd; - exports com.sun.star.xsd;
-} -}
diff --git a/ridljar/source/unoloader/module-info.java b/ridljar/source/unoloader/module-info.java Index: libreoffice-7.5.1.2/ridljar/source/unoloader/module-info.java
deleted file mode 100644 ===================================================================
index 6eed39c96df4..000000000000 --- libreoffice-7.5.1.2.orig/ridljar/source/unoloader/module-info.java
--- a/ridljar/source/unoloader/module-info.java
+++ /dev/null +++ /dev/null
@@ -1,12 +0,0 @@ @@ -1,12 +0,0 @@
-/* -/*
@ -315,10 +313,10 @@ index 6eed39c96df4..000000000000
-{ -{
- exports com.sun.star.lib.unoloader; - exports com.sun.star.lib.unoloader;
-} -}
diff --git a/solenv/gbuild/Jar.mk b/solenv/gbuild/Jar.mk Index: libreoffice-7.5.1.2/solenv/gbuild/Jar.mk
index 9592fbbad6a6..3fa40e03c754 100644 ===================================================================
--- a/solenv/gbuild/Jar.mk --- libreoffice-7.5.1.2.orig/solenv/gbuild/Jar.mk
+++ b/solenv/gbuild/Jar.mk +++ libreoffice-7.5.1.2/solenv/gbuild/Jar.mk
@@ -94,7 +94,6 @@ endef @@ -94,7 +94,6 @@ endef
# creates a class set and a dependency to it # creates a class set and a dependency to it
# registers target and clean target # registers target and clean target
@ -327,7 +325,7 @@ index 9592fbbad6a6..3fa40e03c754 100644
define gb_Jar_Jar define gb_Jar_Jar
ifeq (,$$(findstring $(1),$$(gb_Jar_KNOWN))) ifeq (,$$(findstring $(1),$$(gb_Jar_KNOWN)))
$$(eval $$(call gb_Output_info,Currently known jars are: $(sort $(gb_Jar_KNOWN)),ALL)) $$(eval $$(call gb_Output_info,Currently known jars are: $(sort $(gb_Jar_KNOWN)),ALL))
@@ -107,7 +106,7 @@ $(call gb_Jar_get_target,$(1)) : PACKAGEDIRS := @@ -107,7 +106,7 @@ $(call gb_Jar_get_target,$(1)) : PACKAGE
$(call gb_Jar_get_target,$(1)) : PACKAGEFILES := $(call gb_Jar_get_target,$(1)) : PACKAGEFILES :=
$(call gb_Jar_get_target,$(1)) : \ $(call gb_Jar_get_target,$(1)) : \
$(call gb_JavaClassSet_get_target,$(call gb_Jar_get_classsetname,$(1))) $(call gb_JavaClassSet_get_target,$(call gb_Jar_get_classsetname,$(1)))
@ -336,7 +334,7 @@ index 9592fbbad6a6..3fa40e03c754 100644
$(eval $(call gb_Module_register_target,$(call gb_Jar_get_target,$(1)),$(call gb_Jar_get_clean_target,$(1)))) $(eval $(call gb_Module_register_target,$(call gb_Jar_get_target,$(1)),$(call gb_Jar_get_clean_target,$(1))))
$(call gb_Helper_make_userfriendly_targets,$(1),Jar,$(call gb_Jar_get_target,$(1))) $(call gb_Helper_make_userfriendly_targets,$(1),Jar,$(call gb_Jar_get_target,$(1)))
@@ -122,12 +121,6 @@ $(call gb_JavaClassSet_add_sourcefile,$(call gb_Jar_get_classsetname,$(1)),$(2)) @@ -122,12 +121,6 @@ $(call gb_JavaClassSet_add_sourcefile,$(
endef endef
@ -349,7 +347,7 @@ index 9592fbbad6a6..3fa40e03c754 100644
# PACKAGEROOTS is the list of all root folders created by the JavaClassSet to pack into the jar (without META-INF as this is added automatically) # PACKAGEROOTS is the list of all root folders created by the JavaClassSet to pack into the jar (without META-INF as this is added automatically)
define gb_Jar_set_packageroot define gb_Jar_set_packageroot
$(call gb_Jar_get_target,$(1)) : PACKAGEROOTS := $(2) $(call gb_Jar_get_target,$(1)) : PACKAGEROOTS := $(2)
@@ -166,11 +159,6 @@ $(foreach sourcefile,$(2),$(call gb_Jar_add_sourcefile,$(1),$(sourcefile))) @@ -166,11 +159,6 @@ $(foreach sourcefile,$(2),$(call gb_Jar_
endef endef
@ -361,10 +359,10 @@ index 9592fbbad6a6..3fa40e03c754 100644
define gb_Jar_add_generated_sourcefile define gb_Jar_add_generated_sourcefile
$(call gb_JavaClassSet_add_generated_sourcefile,$(call gb_Jar_get_classsetname,$(1)),$(2)) $(call gb_JavaClassSet_add_generated_sourcefile,$(call gb_Jar_get_classsetname,$(1)),$(2))
diff --git a/solenv/gbuild/JavaClassSet.mk b/solenv/gbuild/JavaClassSet.mk Index: libreoffice-7.5.1.2/solenv/gbuild/JavaClassSet.mk
index 39887dee6e5b..dc7d02e8904a 100644 ===================================================================
--- a/solenv/gbuild/JavaClassSet.mk --- libreoffice-7.5.1.2.orig/solenv/gbuild/JavaClassSet.mk
+++ b/solenv/gbuild/JavaClassSet.mk +++ libreoffice-7.5.1.2/solenv/gbuild/JavaClassSet.mk
@@ -17,11 +17,10 @@ @@ -17,11 +17,10 @@
# the License at http://www.apache.org/licenses/LICENSE-2.0 . # the License at http://www.apache.org/licenses/LICENSE-2.0 .
# #
@ -393,7 +391,7 @@ index 39887dee6e5b..dc7d02e8904a 100644
mkdir -p $(dir $(1)) && \ mkdir -p $(dir $(1)) && \
$(if $(filter-out $(JARDEPS),$(4)), \ $(if $(filter-out $(JARDEPS),$(4)), \
rm -rf $(call gb_JavaClassSet_get_classdir,$(2))/* && \ rm -rf $(call gb_JavaClassSet_get_classdir,$(2))/* && \
RESPONSEFILE=$(call gb_var2file,$(shell $(gb_MKTEMP)),500,\ RESPONSEFILE=$(call gb_var2file,$(shell $(gb_MKTEMP)),\
- $(filter-out $(JARDEPS) $(T_JAVA9FILES),$(4))) && \ - $(filter-out $(JARDEPS) $(T_JAVA9FILES),$(4))) && \
- $(if $(3),$(call gb_JavaClassSet_JAVACCOMMAND,$(JAVA_TARGET_VER)) \ - $(if $(3),$(call gb_JavaClassSet_JAVACCOMMAND,$(JAVA_TARGET_VER)) \
+ $(filter-out $(JARDEPS),$(4))) && \ + $(filter-out $(JARDEPS),$(4))) && \
@ -404,7 +402,7 @@ index 39887dee6e5b..dc7d02e8904a 100644
@$$RESPONSEFILE &&) \ @$$RESPONSEFILE &&) \
rm -f $$RESPONSEFILE &&) \ rm -f $$RESPONSEFILE &&) \
- $(if $(T_MODULENAME),\ - $(if $(T_MODULENAME),\
- RESPONSEFILE=$(call gb_var2file,$(shell $(gb_MKTEMP)),500,\ - RESPONSEFILE=$(call gb_var2file,$(shell $(gb_MKTEMP)),\
- $(T_JAVA9FILES)) && \ - $(T_JAVA9FILES)) && \
- $(if $(3),$(call gb_JavaClassSet_JAVACCOMMAND,9) \ - $(if $(3),$(call gb_JavaClassSet_JAVACCOMMAND,9) \
- $(gb_JavaClassSet_JAVACDEBUG) \ - $(gb_JavaClassSet_JAVACDEBUG) \
@ -417,7 +415,7 @@ index 39887dee6e5b..dc7d02e8904a 100644
touch $(1)) touch $(1))
endef endef
@@ -81,7 +64,6 @@ $(call gb_JavaClassSet_get_preparation_target,%) : @@ -81,7 +64,6 @@ $(call gb_JavaClassSet_get_preparation_t
mkdir -p $(dir $@) && touch $@ mkdir -p $(dir $@) && touch $@
# depend on makefile to enforce a rebuild if files are removed from the classset # depend on makefile to enforce a rebuild if files are removed from the classset
@ -425,7 +423,7 @@ index 39887dee6e5b..dc7d02e8904a 100644
define gb_JavaClassSet_JavaClassSet define gb_JavaClassSet_JavaClassSet
$(call gb_JavaClassSet_get_target,$(1)) : \ $(call gb_JavaClassSet_get_target,$(1)) : \
$(gb_Module_CURRENTMAKEFILE) \ $(gb_Module_CURRENTMAKEFILE) \
@@ -89,8 +71,6 @@ $(call gb_JavaClassSet_get_target,$(1)) : \ @@ -89,8 +71,6 @@ $(call gb_JavaClassSet_get_target,$(1))
$(call gb_JavaClassSet_get_target,$(1)) : JARDEPS := \ $(call gb_JavaClassSet_get_target,$(1)) : JARDEPS := \
$(gb_Module_CURRENTMAKEFILE) \ $(gb_Module_CURRENTMAKEFILE) \
$(call gb_JavaClassSet_get_preparation_target,$(1)) $(call gb_JavaClassSet_get_preparation_target,$(1))
@ -434,7 +432,7 @@ index 39887dee6e5b..dc7d02e8904a 100644
endef endef
@@ -112,17 +92,6 @@ $(foreach sourcefile,$(2),$(call gb_JavaClassSet_add_sourcefile,$(1),$(sourcefil @@ -112,17 +92,6 @@ $(foreach sourcefile,$(2),$(call gb_Java
endef endef
@ -452,10 +450,10 @@ index 39887dee6e5b..dc7d02e8904a 100644
define gb_JavaClassSet_add_generated_sourcefile define gb_JavaClassSet_add_generated_sourcefile
$(call gb_JavaClassSet_get_target,$(1)) : $(call gb_JavaClassSet__get_generated_sourcefile,$(2)) $(call gb_JavaClassSet_get_target,$(1)) : $(call gb_JavaClassSet__get_generated_sourcefile,$(2))
$(call gb_JavaClassSet__get_generated_sourcefile,$(2)) :| $(call gb_JavaClassSet_get_preparation_target,$(1)) $(call gb_JavaClassSet__get_generated_sourcefile,$(2)) :| $(call gb_JavaClassSet_get_preparation_target,$(1))
diff --git a/solenv/gbuild/gbuild.mk b/solenv/gbuild/gbuild.mk Index: libreoffice-7.5.1.2/solenv/gbuild/gbuild.mk
index 86ed3d32a376..da6a3d700864 100644 ===================================================================
--- a/solenv/gbuild/gbuild.mk --- libreoffice-7.5.1.2.orig/solenv/gbuild/gbuild.mk
+++ b/solenv/gbuild/gbuild.mk +++ libreoffice-7.5.1.2/solenv/gbuild/gbuild.mk
@@ -62,8 +62,6 @@ COMMA :=, @@ -62,8 +62,6 @@ COMMA :=,
OPEN_PAREN :=( OPEN_PAREN :=(
CLOSE_PAREN :=) CLOSE_PAREN :=)
@ -465,6 +463,3 @@ index 86ed3d32a376..da6a3d700864 100644
gb_VERBOSE := $(verbose) gb_VERBOSE := $(verbose)
include $(GBUILDDIR)/Helper.mk include $(GBUILDDIR)/Helper.mk
--
2.30.2

View File

@ -0,0 +1,148 @@
From 187d3e94f0bd28b63c934bac84ba7c5fb7beb049 Mon Sep 17 00:00:00 2001
From: Danilo Spinella <oss@danyspin97.org>
Date: Tue, 14 Mar 2023 16:31:09 +0100
Subject: [PATCH 2/2] Revert "Require HarfBuzz 5.1.0"
This reverts commit cbdcc18778f9736ca6f186e2bbb9f0db456b1cee.
---
configure.ac | 1 -
vcl/inc/font/LogicalFontInstance.hxx | 2 ++
vcl/source/font/LogicalFontInstance.cxx | 13 ++++++++++++-
vcl/source/gdi/CommonSalLayout.cxx | 9 +++++++--
4 files changed, 21 insertions(+), 4 deletions(-)
Index: libreoffice-7.5.1.2/configure.ac
===================================================================
--- libreoffice-7.5.1.2.orig/configure.ac
+++ libreoffice-7.5.1.2/configure.ac
@@ -10848,7 +10848,7 @@ AC_SUBST(SYSTEM_LIBORCUS)
dnl ===================================================================
dnl HarfBuzz
dnl ===================================================================
-harfbuzz_required_version=5.1.0
+harfbuzz_required_version=0.93
GRAPHITE_CFLAGS_internal="-I${WORKDIR}/UnpackedTarball/graphite/include -DGRAPHITE2_STATIC"
GRAPHITE_LIBS_internal="-L${WORKDIR}/LinkTarget/StaticLibrary -lgraphite"
Index: libreoffice-7.5.1.2/vcl/inc/font/LogicalFontInstance.hxx
===================================================================
--- libreoffice-7.5.1.2.orig/vcl/inc/font/LogicalFontInstance.hxx
+++ libreoffice-7.5.1.2/vcl/inc/font/LogicalFontInstance.hxx
@@ -156,8 +156,10 @@ private:
// The value is initialized and used in NeedOffsetCorrection().
std::optional<FontFamilyEnum> m_xeFontFamilyEnum;
+#if HB_VERSION_ATLEAST(4, 0, 0)
mutable hb_draw_funcs_t* m_pHbDrawFuncs = nullptr;
basegfx::B2DPolygon m_aDrawPolygon;
+#endif
};
inline hb_font_t* LogicalFontInstance::GetHbFont()
Index: libreoffice-7.5.1.2/vcl/source/font/LogicalFontInstance.cxx
===================================================================
--- libreoffice-7.5.1.2.orig/vcl/source/font/LogicalFontInstance.cxx
+++ libreoffice-7.5.1.2/vcl/source/font/LogicalFontInstance.cxx
@@ -54,8 +54,10 @@ LogicalFontInstance::~LogicalFontInstanc
if (m_pHbFontUntransformed)
hb_font_destroy(m_pHbFontUntransformed);
+#if HB_VERSION_ATLEAST(4, 0, 0)
if (m_pHbDrawFuncs)
hb_draw_funcs_destroy(m_pHbDrawFuncs);
+#endif
}
hb_font_t* LogicalFontInstance::InitHbFont()
@@ -73,10 +75,12 @@ hb_font_t* LogicalFontInstance::InitHbFo
if (!aVariations.empty())
hb_font_set_variations(pHbFont, aVariations.data(), aVariations.size());
+#if HB_VERSION_ATLEAST(3, 3, 0)
// If we are applying artificial italic, instruct HarfBuzz to do the same
// so that mark positioning is also transformed.
if (NeedsArtificialItalic())
hb_font_set_synthetic_slant(pHbFont, ARTIFICIAL_ITALIC_SKEW);
+#endif
ImplInitHbFont(pHbFont);
@@ -87,6 +91,7 @@ hb_font_t* LogicalFontInstance::GetHbFon
{
auto* pHbFont = const_cast<LogicalFontInstance*>(this)->GetHbFont();
+#if HB_VERSION_ATLEAST(3, 3, 0)
if (NeedsArtificialItalic()) // || NeedsArtificialBold()
{
if (!m_pHbFontUntransformed)
@@ -98,7 +103,7 @@ hb_font_t* LogicalFontInstance::GetHbFon
}
return m_pHbFontUntransformed;
}
-
+#endif
return pHbFont;
}
@@ -254,6 +259,7 @@ bool LogicalFontInstance::NeedsArtificia
return m_aFontSelData.GetItalic() != ITALIC_NONE && m_pFontFace->GetItalic() == ITALIC_NONE;
}
+#if HB_VERSION_ATLEAST(4, 0, 0)
namespace
{
void move_to_func(hb_draw_funcs_t*, void* /*pDrawData*/, hb_draw_state_t*, float to_x, float to_y,
@@ -288,10 +294,12 @@ void close_path_func(hb_draw_funcs_t*, v
pPoly->clear();
}
}
+#endif
bool LogicalFontInstance::GetGlyphOutlineUntransformed(sal_GlyphId nGlyph,
basegfx::B2DPolyPolygon& rPolyPoly) const
{
+#if HB_VERSION_ATLEAST(4, 0, 0)
if (!m_pHbDrawFuncs)
{
m_pHbDrawFuncs = hb_draw_funcs_create();
@@ -308,6 +316,9 @@ bool LogicalFontInstance::GetGlyphOutlin
hb_font_get_glyph_shape(GetHbFontUntransformed(), nGlyph, m_pHbDrawFuncs, &rPolyPoly);
return true;
+#else
+ return false;
+#endif
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Index: libreoffice-7.5.1.2/vcl/source/gdi/CommonSalLayout.cxx
===================================================================
--- libreoffice-7.5.1.2.orig/vcl/source/gdi/CommonSalLayout.cxx
+++ libreoffice-7.5.1.2/vcl/source/gdi/CommonSalLayout.cxx
@@ -421,10 +421,10 @@ bool GenericSalLayout::LayoutText(vcl::t
const int nRunLen = nEndRunPos - nMinRunPos;
int nHbFlags = HB_BUFFER_FLAGS_DEFAULT;
-
+#if HB_VERSION_ATLEAST(5, 1, 0)
// Produce HB_GLYPH_FLAG_SAFE_TO_INSERT_TATWEEL that we use below.
nHbFlags |= HB_BUFFER_FLAG_PRODUCE_SAFE_TO_INSERT_TATWEEL;
-
+#endif
if (nMinRunPos == 0)
nHbFlags |= HB_BUFFER_FLAG_BOT; /* Beginning-of-text */
if (nEndRunPos == nLength)
@@ -545,8 +545,13 @@ bool GenericSalLayout::LayoutText(vcl::t
if (hb_glyph_info_get_glyph_flags(&pHbGlyphInfos[i]) & HB_GLYPH_FLAG_UNSAFE_TO_BREAK)
nGlyphFlags |= GlyphItemFlags::IS_UNSAFE_TO_BREAK;
+#if HB_VERSION_ATLEAST(5, 1, 0)
if (hb_glyph_info_get_glyph_flags(&pHbGlyphInfos[i]) & HB_GLYPH_FLAG_SAFE_TO_INSERT_TATWEEL)
nGlyphFlags |= GlyphItemFlags::IS_SAFE_TO_INSERT_KASHIDA;
+#else
+ // If support is not present, then allow kashida anywhere.
+ nGlyphFlags |= GlyphItemFlags::IS_SAFE_TO_INSERT_KASHIDA;
+#endif
DeviceCoordinate nAdvance, nXOffset, nYOffset;
if (aSubRun.maDirection == HB_DIRECTION_TTB)

View File

@ -1,32 +1,10 @@
Index: libreoffice-7.4.1.2/vcl/source/font/fontinstance.cxx Index: libreoffice-7.5.1.2/vcl/source/font/fontmetric.cxx
=================================================================== ===================================================================
--- libreoffice-7.4.1.2.orig/vcl/source/font/fontinstance.cxx --- libreoffice-7.5.1.2.orig/vcl/source/font/fontmetric.cxx
+++ libreoffice-7.4.1.2/vcl/source/font/fontinstance.cxx +++ libreoffice-7.5.1.2/vcl/source/font/fontmetric.cxx
@@ -160,17 +160,6 @@ bool LogicalFontInstance::NeedOffsetCorr @@ -549,20 +549,7 @@ void ImplFontMetricData::ImplInitBaselin
unsigned int familyname_size = 10; double fScale = 0;
pFontInstance->GetScale(nullptr, &fScale);
m_xeFontFamilyEnum = FontFamilyEnum::Unclassified;
-
- if (hb_ot_name_get_utf8 (hb_font_get_face(GetHbFont()),
- HB_OT_NAME_ID_FONT_FAMILY , HB_LANGUAGE_INVALID, &familyname_size, familyname) == 8)
- {
- // DFKai-SB (ukai.ttf) is a built-in font under traditional Chinese
- // Windows. It has wrong extent values in glyf table. The problem results
- // in wrong positioning of glyphs in vertical writing.
- // Check https://github.com/harfbuzz/harfbuzz/issues/3521 for reference.
- if (!strncmp("DFKai-SB", familyname, 8))
- m_xeFontFamilyEnum = FontFamilyEnum::DFKaiSB;
- }
}
bool bRet = true;
Index: libreoffice-7.4.1.2/vcl/source/font/fontmetric.cxx
===================================================================
--- libreoffice-7.4.1.2.orig/vcl/source/font/fontmetric.cxx
+++ libreoffice-7.4.1.2/vcl/source/font/fontmetric.cxx
@@ -449,20 +449,7 @@ void ImplFontMetricData::ImplInitBaselin
double nUPEM = hb_face_get_upem(pHbFace);
double fScale = mnHeight / nUPEM;
hb_position_t nBaseline = 0; hb_position_t nBaseline = 0;
- -
- if (hb_ot_layout_get_baseline(pHbFont, - if (hb_ot_layout_get_baseline(pHbFont,

View File

@ -1,3 +1,12 @@
-------------------------------------------------------------------
Wed Mar 22 16:13:39 UTC 2023 - Danilo Spinella <danilo.spinella@suse.com>
- Fix build on SLE-15-SP4 and SLE-12-SP5
- Refresh patches:
* 0001-Revert-java-9-changes.patch
* 0002-Revert-Require-HarfBuzz-5.1.0.patch
* fix_harfbuzz_on_sle12_sp5.patch
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Mar 21 13:32:12 UTC 2023 - Danilo Spinella <danilo.spinella@suse.com> Tue Mar 21 13:32:12 UTC 2023 - Danilo Spinella <danilo.spinella@suse.com>

View File

@ -113,6 +113,8 @@ Patch12: fix_harfbuzz_on_sle12_sp5.patch
Patch14: use-fixmath-shared-library.patch Patch14: use-fixmath-shared-library.patch
# PATCH-FIX-SUSE Fix make distro-pack-install # PATCH-FIX-SUSE Fix make distro-pack-install
Patch15: fix-sdk-idl.patch Patch15: fix-sdk-idl.patch
# PATCH-FIX-SUSE Allow the use of old harfbuzz versions
Patch16: 0002-Revert-Require-HarfBuzz-5.1.0.patch
# Build with java 8 # Build with java 8
Patch101: 0001-Revert-java-9-changes.patch Patch101: 0001-Revert-java-9-changes.patch
# try to save space by using hardlinks # try to save space by using hardlinks
@ -1039,7 +1041,10 @@ Provides %{langname} translations and additional resources (help files, etc.) fo
%endif %endif
%patch14 -p1 %patch14 -p1
%patch15 -p1 %patch15 -p1
#%patch990 -p1 %if 0%{?suse_version} < 1550
%patch16 -p1
%endif
%patch990 -p1
%patch991 -p1 %patch991 -p1
# Disable some of the failing tests (some are random) # Disable some of the failing tests (some are random)