[Libreoffice-commits] .: Branch 'libreoffice-4-0' - 3 commits - config_host.mk.in configure.ac i18npool/CustomTarget_breakiterator.mk icu/icu4c-buffer-overflow.patch icu/makefile.mk officecfg/prj
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Sun Dec 23 04:38:59 PST 2012
config_host.mk.in | 1 -
configure.ac | 11 ++---------
i18npool/CustomTarget_breakiterator.mk | 2 +-
icu/icu4c-buffer-overflow.patch | 29 +++++++++++++++++++++++++++++
icu/makefile.mk | 1 +
officecfg/prj/build.lst | 2 +-
6 files changed, 34 insertions(+), 12 deletions(-)
New commits:
commit 343a92f18cb4069acca547d455fcbd9ce42815e1
Author: Tomáš Chvátal <tchvatal at suse.cz>
Date: Thu Dec 20 15:35:29 2012 +0100
Require icu 4.6 or later with system icu
Change-Id: I8c0da25a000e10d65479665a61be054fdb2486a5
Reviewed-on: https://gerrit.libreoffice.org/1453
Reviewed-by: David Tardon <dtardon at redhat.com>
Tested-by: Tomáš Chvátal <tchvatal at suse.cz>
diff --git a/config_host.mk.in b/config_host.mk.in
index 4bab5d6..6ffd0fe 100644
--- a/config_host.mk.in
+++ b/config_host.mk.in
@@ -247,7 +247,6 @@ export ICECREAM_RUN=@ICECREAM_RUN@
export ICU_MAJOR=@ICU_MAJOR@
export ICU_MICRO=@ICU_MICRO@
export ICU_MINOR=@ICU_MINOR@
-export ICU_RECLASSIFIED_CLOSE_PARENTHESIS=@ICU_RECLASSIFIED_CLOSE_PARENTHESIS@
export ICU_RECLASSIFIED_CONDITIONAL_JAPANESE_STARTER=@ICU_RECLASSIFIED_CONDITIONAL_JAPANESE_STARTER@
export ICU_RECLASSIFIED_HEBREW_LETTER=@ICU_RECLASSIFIED_HEBREW_LETTER@
export ICU_RECLASSIFIED_PREPEND_SET_EMPTY=@ICU_RECLASSIFIED_PREPEND_SET_EMPTY@
diff --git a/configure.ac b/configure.ac
index 064a2e9..b028e39 100644
--- a/configure.ac
+++ b/configure.ac
@@ -8109,7 +8109,6 @@ SYSTEM_GENCMN=
ICU_MAJOR=49
ICU_MINOR=1
ICU_MICRO=1
-ICU_RECLASSIFIED_CLOSE_PARENTHESIS="YES"
ICU_RECLASSIFIED_PREPEND_SET_EMPTY="YES"
ICU_RECLASSIFIED_CONDITIONAL_JAPANESE_STARTER="YES"
ICU_RECLASSIFIED_HEBREW_LETTER="YES"
@@ -8134,10 +8133,10 @@ if test "$with_system_icu" = "yes"; then
ICU_MINOR=`echo $ICU_VERSION | cut -d"." -f2`
ICU_MICRO=`echo $ICU_VERSION | cut -d"." -f3`
- if test "$ICU_MAJOR" -ge "4"; then
+ if test "$ICU_MAJOR" -ge "49" -o \( "$ICU_MAJOR" = "4" -a "$ICU_MINOR" -ge "6" \); then
AC_MSG_RESULT([OK, $ICU_VERSION])
else
- AC_MSG_ERROR([not suitable, only >= 4.0 supported currently])
+ AC_MSG_ERROR([not suitable, only >= 4.6 supported currently])
fi
if test "$cross_compiling" = "yes" -a \( "$with_system_icu_for_build" = "yes" -o "$with_system_icu_for_build" = "force" \); then
@@ -8172,11 +8171,6 @@ You can use --with-system-icu-for-build=force to use it anyway.])
if test -z "$SYSTEM_GENCMN"; then
AC_MSG_ERROR([\'gencmn\' not found in \$PATH, install the icu development tool \'gencmn\'])
fi
- if test "$ICU_MAJOR" -ge "49" -o \( "$ICU_MAJOR" = "4" -a "$ICU_MINOR" -ge "4" \); then
- ICU_RECLASSIFIED_CLOSE_PARENTHESIS="YES"
- else
- ICU_RECLASSIFIED_CLOSE_PARENTHESIS="NO"
- fi
if test "$ICU_MAJOR" -ge "49"; then
ICU_RECLASSIFIED_PREPEND_SET_EMPTY="YES"
else
@@ -8203,7 +8197,6 @@ AC_SUBST(SYSTEM_GENCMN)
AC_SUBST(ICU_MAJOR)
AC_SUBST(ICU_MINOR)
AC_SUBST(ICU_MICRO)
-AC_SUBST(ICU_RECLASSIFIED_CLOSE_PARENTHESIS)
AC_SUBST([ICU_RECLASSIFIED_CONDITIONAL_JAPANESE_STARTER])
AC_SUBST([ICU_RECLASSIFIED_HEBREW_LETTER])
AC_SUBST(ICU_RECLASSIFIED_PREPEND_SET_EMPTY)
diff --git a/i18npool/CustomTarget_breakiterator.mk b/i18npool/CustomTarget_breakiterator.mk
index f7df926..f12b94c 100644
--- a/i18npool/CustomTarget_breakiterator.mk
+++ b/i18npool/CustomTarget_breakiterator.mk
@@ -121,7 +121,7 @@ $(i18npool_BIDIR)/%.brk : $(i18npool_BIDIR)/%.txt $(i18npool_GENBRKTARGET)
$(i18npool_BIDIR)/%.txt : \
$(SRCDIR)/i18npool/source/breakiterator/data/%.txt | $(i18npool_BIDIR)/.dir
sed -e ': dummy' \
- $(if $(filter YES,$(ICU_RECLASSIFIED_CLOSE_PARENTHESIS)),-e "s#\[:LineBreak = Close_Punctuation:\]#\[& \[:LineBreak = Close_Parenthesis:\]\]#") \
+ -e "s#\[:LineBreak = Close_Punctuation:\]#\[& \[:LineBreak = Close_Parenthesis:\]\]#" \
$(if $(filter-out YES,$(ICU_RECLASSIFIED_CONDITIONAL_JAPANESE_STARTER)),\
-e '/\[:LineBreak = Conditional_Japanese_Starter:\]/d' \
-e 's# $$CJ##' \
commit aa7b9f0da9e810ff165204d4c6a51633c177ac78
Author: Tomáš Chvátal <tchvatal at suse.cz>
Date: Thu Dec 20 23:53:52 2012 +0100
Require l10ntools on officecfg
Change-Id: I31f212f21f57b37b2b4f1f5dd753a4211c58bcdb
diff --git a/officecfg/prj/build.lst b/officecfg/prj/build.lst
index 8f0653a..411d267 100644
--- a/officecfg/prj/build.lst
+++ b/officecfg/prj/build.lst
@@ -1,2 +1,2 @@
-oc officecfg : soltools solenv LIBXSLT:libxslt NULL
+oc officecfg : l10ntools soltools solenv LIBXSLT:libxslt NULL
oc officecfg\prj nmake - all oc_prj NULL
commit 0892ab21a71c316c801f1be7c9c0ae6603495b21
Author: Tomáš Chvátal <tchvatal at suse.cz>
Date: Sun Dec 23 13:21:27 2012 +0100
Add icu patch to avoid buffer overflow, taken from obs
Change-Id: I42ae81279fedca04b7ba08269a6c47f174cf6b01
diff --git a/icu/icu4c-buffer-overflow.patch b/icu/icu4c-buffer-overflow.patch
new file mode 100644
index 0000000..1f3d2ca
--- /dev/null
+++ b/icu/icu4c-buffer-overflow.patch
@@ -0,0 +1,29 @@
+I: Statement might be overflowing a buffer in strncat. Common mistake:
+ BAD: strncat(buffer,charptr,sizeof(buffer)) is wrong, it takes the left over size as 3rd argument
+ GOOD: strncat(buffer,charptr,sizeof(buffer)-strlen(buffer)-1)
+E: icu bufferoverflowstrncat pkgdata.cpp:299:87
+
+---
+ source/tools/pkgdata/pkgdata.cpp | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+Index: icu/source/tools/pkgdata/pkgdata.cpp
+===================================================================
+--- icu.orig/source/tools/pkgdata/pkgdata.cpp
++++ icu/source/tools/pkgdata/pkgdata.cpp
+@@ -1914,12 +1914,12 @@ static void loadLists(UPKGOptions *o, UE
+ const char cmd[] = "icu-config --incpkgdatafile";
+
+ /* #1 try the same path where pkgdata was called from. */
+- findDirname(progname, cmdBuf, 1024, &status);
++ findDirname(progname, cmdBuf, sizeof(cmdBuf), &status);
+ if(U_SUCCESS(status)) {
+ if (cmdBuf[0] != 0) {
+- uprv_strncat(cmdBuf, U_FILE_SEP_STRING, 1024);
++ uprv_strncat(cmdBuf, U_FILE_SEP_STRING, sizeof(cmdBuf)-1-strlen(cmdBuf));
+ }
+- uprv_strncat(cmdBuf, cmd, 1024);
++ uprv_strncat(cmdBuf, cmd, sizeof(cmdBuf)-1-strlen(cmdBuf));
+
+ if(verbose) {
+ fprintf(stdout, "# Calling icu-config: %s\n", cmdBuf);
diff --git a/icu/makefile.mk b/icu/makefile.mk
index 2d50a24..5494fa5 100644
--- a/icu/makefile.mk
+++ b/icu/makefile.mk
@@ -57,6 +57,7 @@ PATCH_FILES=\
icu4c-macosx.patch \
icu4c-solarisgcc.patch \
icu4c-mkdir.patch \
+ icu4c-buffer-overflow.patch \
.IF "$(OS)"=="ANDROID"
PATCH_FILES+=\
More information about the Libreoffice-commits
mailing list