forked from pool/libvisio
Accepting request 184376 from home:fstrba
- Performance regression fix * Add patch to unconditionally use WPX_SEEK_END * Depend on libwpd-devel >= 0.9.5 that has WPX_SEEK_END OBS-URL: https://build.opensuse.org/request/show/184376 OBS-URL: https://build.opensuse.org/package/show/LibreOffice:Factory/libvisio?expand=0&rev=14
This commit is contained in:
parent
fb02d9b502
commit
1bf09bf503
19
libvisio-0.0.30-iterator_range.patch
Normal file
19
libvisio-0.0.30-iterator_range.patch
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
--- a/src/lib/libvisio_utils.cpp
|
||||||
|
+++ b/src/lib/libvisio_utils.cpp
|
||||||
|
@@ -35,6 +35,7 @@
|
||||||
|
#include <boost/archive/iterators/binary_from_base64.hpp>
|
||||||
|
#include <boost/archive/iterators/remove_whitespace.hpp>
|
||||||
|
#include <boost/archive/iterators/transform_width.hpp>
|
||||||
|
+#include <boost/range/iterator_range.hpp>
|
||||||
|
|
||||||
|
uint8_t libvisio::readU8(WPXInputStream *input)
|
||||||
|
{
|
||||||
|
@@ -125,7 +126,7 @@ double libvisio::readDouble(WPXInputStream *input)
|
||||||
|
|
||||||
|
void libvisio::appendFromBase64(WPXBinaryData &data, const unsigned char *base64Data, size_t base64DataLength)
|
||||||
|
{
|
||||||
|
- std::string base64String((const char *)base64Data, base64DataLength);
|
||||||
|
+ boost::iterator_range<const char *> base64String((const char *)base64Data, (const char *)base64Data + base64DataLength);
|
||||||
|
typedef boost::archive::iterators::transform_width<
|
||||||
|
boost::archive::iterators::binary_from_base64<
|
||||||
|
boost::archive::iterators::remove_whitespace< std::string::const_iterator > >, 8, 6 > base64_decoder;
|
14
libvisio-0.0.30-wpx_seek_end.patch
Normal file
14
libvisio-0.0.30-wpx_seek_end.patch
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
--- a/src/lib/VSDZipStream.cpp
|
||||||
|
+++ b/src/lib/VSDZipStream.cpp
|
||||||
|
@@ -161,11 +161,7 @@ WPXInputStream *libvisio::VSDZipStream::getDocumentOLEStream(const char *name)
|
||||||
|
|
||||||
|
bool libvisio::VSDZipStreamImpl::findCentralDirectoryEnd()
|
||||||
|
{
|
||||||
|
-#if defined(LIBWPD_STREAM_VERSION_MAJOR) && defined(LIBWPD_STREAM_VERSION_MINOR) && defined(LIBWPD_STREAM_VERSION_REVISION) \
|
||||||
|
- && (LIBWPD_STREAM_VERSION_MAJOR > 0 || (LIBWPD_STREAM_VERSION_MAJOR == 0 && (LIBWPD_STREAM_VERSION_MINOR > 9 \
|
||||||
|
- || (LIBWPD_STREAM_VERSION_MINOR == 9 && LIBWPD_STREAM_VERSION_REVISION >= 5))))
|
||||||
|
if (m_cdir_offset || m_input->seek(-1024, WPX_SEEK_END))
|
||||||
|
-#endif
|
||||||
|
m_input->seek(m_cdir_offset, WPX_SEEK_SET);
|
||||||
|
try
|
||||||
|
{
|
@ -1,3 +1,10 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Jul 26 06:58:30 UTC 2013 - fridrich.strba@suse.com
|
||||||
|
|
||||||
|
- Performance regression fix
|
||||||
|
* Add patch to unconditionally use WPX_SEEK_END
|
||||||
|
* Depend on libwpd-devel >= 0.9.5 that has WPX_SEEK_END
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Jul 10 16:54:11 UTC 2013 - fridrich.strba@suse.com
|
Wed Jul 10 16:54:11 UTC 2013 - fridrich.strba@suse.com
|
||||||
|
|
||||||
|
@ -26,6 +26,8 @@ Summary: Library for parsing the MS Visio file format structure
|
|||||||
Url: http://www.freedesktop.org/wiki/Software/libvisio
|
Url: http://www.freedesktop.org/wiki/Software/libvisio
|
||||||
Group: Productivity/Publishing/Word
|
Group: Productivity/Publishing/Word
|
||||||
Source0: http://dev-www.libreoffice.org/src/%{name}-%{version}.tar.xz
|
Source0: http://dev-www.libreoffice.org/src/%{name}-%{version}.tar.xz
|
||||||
|
Patch0: libvisio-0.0.30-iterator_range.patch
|
||||||
|
Patch1: libvisio-0.0.30-wpx_seek_end.patch
|
||||||
BuildRequires: boost-devel
|
BuildRequires: boost-devel
|
||||||
%if 0%{?suse_version} > 1020
|
%if 0%{?suse_version} > 1020
|
||||||
%define build_doc 1
|
%define build_doc 1
|
||||||
@ -36,7 +38,7 @@ BuildRequires: doxygen
|
|||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: gcc-c++
|
BuildRequires: gcc-c++
|
||||||
BuildRequires: libicu-devel
|
BuildRequires: libicu-devel
|
||||||
BuildRequires: libwpd-devel >= 0.9.0
|
BuildRequires: libwpd-devel >= 0.9.5
|
||||||
BuildRequires: libwpg-devel >= 0.2.0
|
BuildRequires: libwpg-devel >= 0.2.0
|
||||||
BuildRequires: libxml2-devel
|
BuildRequires: libxml2-devel
|
||||||
BuildRequires: zlib-devel
|
BuildRequires: zlib-devel
|
||||||
@ -88,6 +90,8 @@ This package contains tools to work with documents in MS Visio file-format.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
|
%patch0 -p1 -b .iterator_range
|
||||||
|
%patch1 -p1 -b .wpx_seek_end
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%configure \
|
%configure \
|
||||||
|
Loading…
Reference in New Issue
Block a user