[packages/libreoffice] - fix build with mdds 1.2.0
baggins
baggins at pld-linux.org
Mon May 23 08:05:11 CEST 2016
commit 343e4b00eb099109cca0ffff0212dc8c9b87d900
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Mon May 23 08:04:57 2016 +0200
- fix build with mdds 1.2.0
libreoffice.spec | 6 +-
mdds-1.0.patch | 190 -------------------------------------------------------
mdds-1.2.0.patch | 124 ++++++++++++++++++++++++++++++++++++
3 files changed, 127 insertions(+), 193 deletions(-)
---
diff --git a/libreoffice.spec b/libreoffice.spec
index 7f203d8..0e293ee 100644
--- a/libreoffice.spec
+++ b/libreoffice.spec
@@ -51,7 +51,7 @@ Summary: LibreOffice - powerful office suite
Summary(pl.UTF-8): LibreOffice - potężny pakiet biurowy
Name: libreoffice
Version: %{major_ver}.1
-Release: 2
+Release: 1
License: GPL/LGPL
Group: X11/Applications
Source0: http://download.documentfoundation.org/libreoffice/src/%{major_ver}/%{name}-%{version}.tar.xz
@@ -86,7 +86,7 @@ Source28: http://dev-www.libreoffice.org/src/OpenCOLLADA-master-6509aa13af.tar.b
# Source28-md5: 4ca8a6ef0afeefc864e9ef21b9f14bd6
Patch0: disable-failing-test.patch
-Patch1: mdds-1.0.patch
+Patch1: mdds-1.2.0.patch
Patch2: boost-1.59.patch
URL: http://www.documentfoundation.org/
BuildRequires: /usr/bin/getopt
@@ -185,7 +185,7 @@ BuildRequires: libxml2-devel >= 2.0
BuildRequires: libxslt-devel
BuildRequires: libxslt-progs
%{?with_access:%{?with_system_mdbtools:BuildRequires: mdbtools-devel >= 0.6}}
-BuildRequires: mdds-devel >= 1.0
+BuildRequires: mdds-devel >= 1.2
%{?with_mono:BuildRequires: mono-csharp >= 1.2.3}
%{?with_mono:BuildRequires: mono-static >= 1.2.3}
%{?with_system_myspell:BuildRequires: myspell-devel}
diff --git a/mdds-1.0.patch b/mdds-1.0.patch
deleted file mode 100644
index 7abba66..0000000
--- a/mdds-1.0.patch
+++ /dev/null
@@ -1,190 +0,0 @@
-From a7c3a2a9be83686657c06f37d521f9f6d2004ddd Mon Sep 17 00:00:00 2001
-From: Markus Mohrhard <markus.mohrhard at googlemail.com>
-Date: Fri, 9 Oct 2015 01:03:29 +0200
-Subject: update to mdds 1.0
-
-Change-Id: I5b6e928ab5a5f2bf84d50f3f0221c0585670d972
-Reviewed-on: https://gerrit.libreoffice.org/20251
-Tested-by: Jenkins <ci at libreoffice.org>
-Reviewed-by: Markus Mohrhard <markus.mohrhard at googlemail.com>
-Tested-by: Markus Mohrhard <markus.mohrhard at googlemail.com>
-
-diff --git a/configure.ac b/configure.ac
-index 57a41f7..e00df959 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -8759,7 +8759,7 @@ AC_SUBST(SYSTEM_BOOST)
- dnl ===================================================================
- dnl Check for system mdds
- dnl ===================================================================
--libo_CHECK_SYSTEM_MODULE([mdds], [MDDS], [mdds >= 0.12.0], ["-I${WORKDIR}/UnpackedTarball/mdds/include"])
-+libo_CHECK_SYSTEM_MODULE([mdds], [MDDS], [mdds-1.0 >= 1.0.0], ["-I${WORKDIR}/UnpackedTarball/mdds/include"])
-
- dnl ===================================================================
- dnl Check for system glm
-diff --git a/download.lst b/download.lst
-index eabdbcf..8774343 100755
---- a/download.lst
-+++ b/download.lst
-@@ -93,8 +93,8 @@ export LIBXML_TARBALL := daece17e045f1c107610e137ab50c179-libxml2-2.9.3.tar.gz
- export LIBXSLT_TARBALL := 9667bf6f9310b957254fdcf6596600b7-libxslt-1.1.28.tar.gz
- export LPSOLVE_TARBALL := 26b3e95ddf3d9c077c480ea45874b3b8-lp_solve_5.5.tar.gz
- export MARIADB_TARBALL := a233181e03d3c307668b4c722d881661-mariadb_client-2.0.0-src.tar.gz
--export MDDS_MD5SUM := ef2560ed5416652a7fe195305b14cebe
--export MDDS_TARBALL := mdds_0.12.1.tar.bz2
-+export MDDS_MD5SUM := 74e0a81c5af4137285fe6a52217f71e4
-+export MDDS_TARBALL := mdds_1.0.0.tar.bz2
- export MSPUB_MD5SUM := ff9d0f9dd8fbc523408ea1953d5bde41
- export MSPUB_TARBALL := libmspub-0.1.2.tar.bz2
- export MWAW_MD5SUM := 4a8a53a9d997cf0e2bd208178797dbfb
-diff --git a/external/libetonyek/ExternalProject_libetonyek.mk b/external/libetonyek/ExternalProject_libetonyek.mk
-index d296a1e..c98889b 100644
---- a/external/libetonyek/ExternalProject_libetonyek.mk
-+++ b/external/libetonyek/ExternalProject_libetonyek.mk
-@@ -40,7 +40,7 @@ $(call gb_ExternalProject_get_state_target,libetonyek,build) :
- --disable-werror \
- --disable-weffc \
- --without-tools \
-- --with-mdds=0.x \
-+ --with-mdds=1.0 \
- $(if $(filter WNT,$(OS_FOR_BUILD)),MKDIR_P="$(shell cygpath -m /usr/bin/mkdir) -p") \
- $(if $(verbose),--disable-silent-rules,--enable-silent-rules) \
- $(if $(filter LINUX,$(OS)), \
-diff --git a/external/mdds/0001-another-step-to-allow-fst-to-use-any-value-type.patch.1 b/external/mdds/0001-another-step-to-allow-fst-to-use-any-value-type.patch.1
-deleted file mode 100644
-index bed9c9c..0000000
---- a/external/mdds/0001-another-step-to-allow-fst-to-use-any-value-type.patch.1
-+++ /dev/null
-@@ -1,55 +0,0 @@
--From 5fc9214fb94595e1a2c0b9e0285037f5a2fa59bf Mon Sep 17 00:00:00 2001
--From: David Tardon <dtardon at redhat.com>
--Date: Mon, 29 Jun 2015 14:28:42 +0200
--Subject: [PATCH] another step to allow fst to use any value type
--
--For some reason this is not a problem on modern compilers...
-----
-- include/mdds/flat_segment_tree.hpp | 1 -
-- include/mdds/flat_segment_tree_def.inl | 2 +-
-- src/flat_segment_tree_test.cpp | 4 ++++
-- 3 files changed, 5 insertions(+), 2 deletions(-)
--
--diff --git a/include/mdds/flat_segment_tree.hpp b/include/mdds/flat_segment_tree.hpp
--index b656bc3..02cf87e 100644
----- a/include/mdds/flat_segment_tree.hpp
--+++ b/include/mdds/flat_segment_tree.hpp
--@@ -32,7 +32,6 @@
-- #include <sstream>
-- #include <utility>
-- #include <cassert>
---#include <limits>
--
-- #include "mdds/node.hpp"
-- #include "mdds/flat_segment_tree_itr.hpp"
--diff --git a/include/mdds/flat_segment_tree_def.inl b/include/mdds/flat_segment_tree_def.inl
--index ebfee99..5fef1c3 100644
----- a/include/mdds/flat_segment_tree_def.inl
--+++ b/include/mdds/flat_segment_tree_def.inl
--@@ -46,7 +46,7 @@ flat_segment_tree<_Key, _Value>::flat_segment_tree(key_type min_val, key_type ma
-- // We don't ever use the value of the right leaf node, but we need the
-- // value to be always the same, to make it easier to check for
-- // equality.
--- m_right_leaf->value_leaf.value = ::std::numeric_limits<value_type>::max();
--+ m_right_leaf->value_leaf.value = init_val;
-- }
--
-- template<typename _Key, typename _Value>
--diff --git a/src/flat_segment_tree_test.cpp b/src/flat_segment_tree_test.cpp
--index 81858f5..f7aead7 100644
----- a/src/flat_segment_tree_test.cpp
--+++ b/src/flat_segment_tree_test.cpp
--@@ -1943,6 +1943,10 @@ void fst_test_non_numeric_value()
-- db.search(1, result);
--
-- assert(result == "hello world");
--+
--+ db_type db2(db);
--+
--+ assert(db == db2);
-- }
--
-- void fst_test_non_numeric_key()
----
--2.4.2
--
-diff --git a/external/mdds/UnpackedTarball_mdds.mk b/external/mdds/UnpackedTarball_mdds.mk
-index 504406b..2627257 100644
---- a/external/mdds/UnpackedTarball_mdds.mk
-+++ b/external/mdds/UnpackedTarball_mdds.mk
-@@ -14,9 +14,7 @@ $(eval $(call gb_UnpackedTarball_set_tarball,mdds,$(MDDS_TARBALL)))
- $(eval $(call gb_UnpackedTarball_set_patchlevel,mdds,3))
-
- $(eval $(call gb_UnpackedTarball_add_patches,mdds,\
-- external/mdds/mdds_0.6.0.patch \
- external/mdds/mdds-c++98.patch.0 \
-- external/mdds/0001-another-step-to-allow-fst-to-use-any-value-type.patch.1 \
- ))
-
- # vim: set noet sw=4 ts=4:
-diff --git a/external/mdds/mdds_0.6.0.patch b/external/mdds/mdds_0.6.0.patch
-deleted file mode 100644
-index fba1502..0000000
---- a/external/mdds/mdds_0.6.0.patch
-+++ /dev/null
-@@ -1,54 +0,0 @@
----- misc/mdds_0.6.0/include/mdds/mixed_type_matrix_def.inl 2011-07-13 13:26:27.000000000 -0600
--+++ misc/build/mdds_0.6.0/include/mdds/mixed_type_matrix_def.inl 2011-07-20 02:02:21.164198900 -0600
--@@ -216,8 +216,8 @@
-- // assignment to self.
-- return;
--
--- size_t row_count = ::std::min(mp_storage->rows(), r.mp_storage->rows());
--- size_t col_count = ::std::min(mp_storage->cols(), r.mp_storage->cols());
--+ size_t row_count = (::std::min)(mp_storage->rows(), r.mp_storage->rows());
--+ size_t col_count = (::std::min)(mp_storage->cols(), r.mp_storage->cols());
-- for (size_t i = 0; i < row_count; ++i)
-- for (size_t j = 0; j < col_count; ++j)
-- mp_storage->get_element(i, j) = r.mp_storage->get_element(i, j);
----- misc/mdds_0.6.0/include/mdds/mixed_type_matrix_storage_filled_linear.inl 2011-07-13 13:26:27.000000000 -0600
--+++ misc/build/mdds_0.6.0/include/mdds/mixed_type_matrix_storage_filled_linear.inl 2011-07-20 02:02:21.179798900 -0600
--@@ -354,8 +354,8 @@
-- }
--
-- array_type new_array(new_size, &m_init_elem);
--- size_t min_rows = ::std::min(row, m_rows);
--- size_t min_cols = ::std::min(col, m_cols);
--+ size_t min_rows = (::std::min)(row, m_rows);
--+ size_t min_cols = (::std::min)(col, m_cols);
-- for (size_t i = 0; i < min_rows; ++i)
-- {
-- for (size_t j = 0; j < min_cols; ++j)
--@@ -612,8 +612,8 @@
-- }
--
-- array_type new_array(new_size, element(0.0));
--- size_t min_rows = ::std::min(row, m_rows);
--- size_t min_cols = ::std::min(col, m_cols);
--+ size_t min_rows = (::std::min)(row, m_rows);
--+ size_t min_cols = (::std::min)(col, m_cols);
-- for (size_t i = 0; i < min_rows; ++i)
-- {
-- for (size_t j = 0; j < min_cols; ++j)
----- misc/mdds_0.6.0/include/mdds/point_quad_tree.hpp 2011-07-13 13:26:27.000000000 -0600
--+++ misc/build/mdds_0.6.0/include/mdds/point_quad_tree.hpp 2011-07-20 02:04:36.088835900 -0600
--@@ -623,10 +623,10 @@
-- template<typename _Key, typename _Data>
-- void point_quad_tree<_Key,_Data>::insert(key_type x, key_type y, data_type data)
-- {
--- m_xrange.first = ::std::min(m_xrange.first, x);
--- m_xrange.second = ::std::max(m_xrange.second, x);
--- m_yrange.first = ::std::min(m_yrange.first, y);
--- m_yrange.second = ::std::max(m_yrange.second, y);
--+ m_xrange.first = (::std::min)(m_xrange.first, x);
--+ m_xrange.second = (::std::max)(m_xrange.second, x);
--+ m_yrange.first = (::std::min)(m_yrange.first, y);
--+ m_yrange.second = (::std::max)(m_yrange.second, y);
--
-- if (!m_root)
-- {
---
-cgit v0.10.2
-
diff --git a/mdds-1.2.0.patch b/mdds-1.2.0.patch
new file mode 100644
index 0000000..89d1314
--- /dev/null
+++ b/mdds-1.2.0.patch
@@ -0,0 +1,124 @@
+From db729f3b685fd832a3ec7387b339cf2bbeb4bd4d Mon Sep 17 00:00:00 2001
+From: Kohei Yoshida <kohei.yoshida at gmail.com>
+Date: Wed, 11 May 2016 21:45:56 -0400
+Subject: Update mdds to 1.2.0. Note that the API version is also up.
+
+liborcus-0.11.2 is out only to make it buildable with mdds-1.2.
+
+Change-Id: I9648d827b008da252c57be0ebfd2efccb008ac70
+Reviewed-on: https://gerrit.libreoffice.org/24944
+Tested-by: Jenkins <ci at libreoffice.org>
+Reviewed-by: Kohei Yoshida <libreoffice at kohei.us>
+
+diff --git a/configure.ac b/configure.ac
+index 3f1b7f0..6dea282 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -8832,7 +8832,7 @@ AC_SUBST(SYSTEM_BOOST)
+ dnl ===================================================================
+ dnl Check for system mdds
+ dnl ===================================================================
+-libo_CHECK_SYSTEM_MODULE([mdds], [MDDS], [mdds >= 0.12.0], ["-I${WORKDIR}/UnpackedTarball/mdds/include"])
++libo_CHECK_SYSTEM_MODULE([mdds], [MDDS], [mdds-1.2 >= 1.2.0], ["-I${WORKDIR}/UnpackedTarball/mdds/include"])
+
+ dnl ===================================================================
+ dnl Check for system glm
+diff --git a/download.lst b/download.lst
+index a2483c2..ddd6edc 100644
+--- a/download.lst
++++ b/download.lst
+@@ -94,8 +94,8 @@
+ export LIBXSLT_TARBALL := 9667bf6f9310b957254fdcf6596600b7-libxslt-1.1.28.tar.gz
+ export LPSOLVE_TARBALL := 26b3e95ddf3d9c077c480ea45874b3b8-lp_solve_5.5.tar.gz
+ export MARIADB_TARBALL := a233181e03d3c307668b4c722d881661-mariadb_client-2.0.0-src.tar.gz
+-export MDDS_MD5SUM := ef2560ed5416652a7fe195305b14cebe
+-export MDDS_TARBALL := mdds_0.12.1.tar.bz2
++export MDDS_MD5SUM := 9f3383fb7bae825eab69f3a6ec1d74b2
++export MDDS_TARBALL := mdds-1.2.0.tar.bz2
+ export MSPUB_MD5SUM := ff9d0f9dd8fbc523408ea1953d5bde41
+ export MSPUB_TARBALL := libmspub-0.1.2.tar.bz2
+ export MWAW_MD5SUM := 4a8a53a9d997cf0e2bd208178797dbfb
+diff --git a/sc/inc/mtvelements.hxx b/sc/inc/mtvelements.hxx
+index 0bc5162..18edafc 100644
+--- a/sc/inc/mtvelements.hxx
++++ b/sc/inc/mtvelements.hxx
+@@ -53,6 +53,7 @@ const mdds::mtv::element_t element_type_cellnote = mdds::mtv::element_type_user_
+ /// Mapped standard element types (for convenience).
+ const mdds::mtv::element_t element_type_numeric = mdds::mtv::element_type_numeric;
+ const mdds::mtv::element_t element_type_empty = mdds::mtv::element_type_empty;
++const mdds::mtv::element_t element_type_uint16 = mdds::mtv::element_type_ushort;
+
+ /// Custom element blocks.
+
+@@ -65,6 +66,7 @@ typedef mdds::mtv::noncopyable_managed_element_block<element_type_formula, ScFor
+
+ /// Mapped standard element blocks (for convenience).
+ typedef mdds::mtv::numeric_element_block numeric_block;
++typedef mdds::mtv::ushort_element_block uint16_block;
+
+ /// This needs to be in the same namespace as CellTextAttr.
+ MDDS_MTV_DEFINE_ELEMENT_CALLBACKS(CellTextAttr, element_type_celltextattr, CellTextAttr(), celltextattr_block)
+diff --git a/sc/source/core/tool/scmatrix.cxx b/sc/source/core/tool/scmatrix.cxx
+index f1ce9a5..1689809 100644
+--- a/sc/source/core/tool/scmatrix.cxx
++++ b/sc/source/core/tool/scmatrix.cxx
+@@ -57,17 +57,15 @@ using ::std::unary_function;
+ * Custom string trait struct to tell mdds::multi_type_matrix about the
+ * custom string type and how to handle blocks storing them.
+ */
+-struct custom_string_trait
++struct matrix_trait
+ {
+- typedef svl::SharedString string_type;
+ typedef sc::string_block string_element_block;
+-
+- static const mdds::mtv::element_t string_type_identifier = sc::element_type_string;
++ typedef sc::uint16_block integer_element_block;
+
+ typedef mdds::mtv::custom_block_func1<sc::string_block> element_block_func;
+ };
+
+-typedef mdds::multi_type_matrix<custom_string_trait> MatrixImplType;
++typedef mdds::multi_type_matrix<matrix_trait> MatrixImplType;
+
+ namespace {
+
+@@ -2304,6 +2302,7 @@ public:
+ }
+ }
+ break;
++ case mdds::mtm::element_integer:
+ case mdds::mtm::element_string:
+ case mdds::mtm::element_empty:
+ default:
+diff --git a/svl/source/misc/gridprinter.cxx b/svl/source/misc/gridprinter.cxx
+index 4044b3e..70e7439 100644
+--- a/svl/source/misc/gridprinter.cxx
++++ b/svl/source/misc/gridprinter.cxx
+@@ -26,12 +26,10 @@ const mdds::mtv::element_t element_type_string = mdds::mtv::element_type_user_st
+ // String block
+ typedef mdds::mtv::default_element_block<element_type_string, OUString> string_block;
+
+-struct custom_string_trait
++struct matrix_trait
+ {
+- typedef OUString string_type;
+ typedef string_block string_element_block;
+-
+- static const mdds::mtv::element_t string_type_identifier = element_type_string;
++ typedef mdds::mtv::ushort_element_block integer_element_block;
+
+ typedef mdds::mtv::custom_block_func1<string_block> element_block_func;
+ };
+@@ -48,7 +46,7 @@ MDDS_MTV_DEFINE_ELEMENT_CALLBACKS(OUString, svl::element_type_string, OUString()
+
+ namespace svl {
+
+-typedef mdds::multi_type_matrix<custom_string_trait> MatrixImplType;
++typedef mdds::multi_type_matrix<matrix_trait> MatrixImplType;
+
+ struct GridPrinter::Impl
+ {
+--
+cgit v0.10.2
+
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/libreoffice.git/commitdiff/343e4b00eb099109cca0ffff0212dc8c9b87d900
More information about the pld-cvs-commit
mailing list