From e764334c26dea7bd3cb85c1e5e3ff14324d629c8 Mon Sep 17 00:00:00 2001 From: David Tardon Date: Mon, 4 May 2015 17:30:59 +0200 Subject: [PATCH] include some upstream fixes --- 0001-add-missing-breaks.patch | 49 ++++++++++++++++++++++++ 0001-define-more-needed-namespaces.patch | 27 +++++++++++++ libvisio.spec | 5 ++- 3 files changed, 80 insertions(+), 1 deletion(-) create mode 100644 0001-add-missing-breaks.patch create mode 100644 0001-define-more-needed-namespaces.patch diff --git a/0001-add-missing-breaks.patch b/0001-add-missing-breaks.patch new file mode 100644 index 0000000..81cc687 --- /dev/null +++ b/0001-add-missing-breaks.patch @@ -0,0 +1,49 @@ +From e39b9f080b9cd7ed0e64a43a4c6a053c1dd67718 Mon Sep 17 00:00:00 2001 +From: David Tardon +Date: Mon, 4 May 2015 17:16:50 +0200 +Subject: [PATCH] add missing breaks + +Change-Id: I200b80dca1db001d49fb97326345539c02c66b90 +--- + src/lib/VSDXParser.cpp | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/src/lib/VSDXParser.cpp b/src/lib/VSDXParser.cpp +index f11d778..b8669dd 100644 +--- a/src/lib/VSDXParser.cpp ++++ b/src/lib/VSDXParser.cpp +@@ -1047,6 +1047,7 @@ void libvisio::VSDXParser::readShapeProperties(xmlTextReaderPtr reader) + m_shape.m_txtxform = new XForm(); + ret = readDoubleData(m_shape.m_txtxform->angle, reader); + } ++ break; + case XML_BEGINX: + if (XML_READER_TYPE_ELEMENT == tokenType) + { +@@ -1054,6 +1055,7 @@ void libvisio::VSDXParser::readShapeProperties(xmlTextReaderPtr reader) + m_shape.m_xform1d = new XForm1D(); + ret = readDoubleData(m_shape.m_xform1d->beginX, reader); + } ++ break; + case XML_BEGINY: + if (XML_READER_TYPE_ELEMENT == tokenType) + { +@@ -1061,6 +1063,7 @@ void libvisio::VSDXParser::readShapeProperties(xmlTextReaderPtr reader) + m_shape.m_xform1d = new XForm1D(); + ret = readDoubleData(m_shape.m_xform1d->beginY, reader); + } ++ break; + case XML_ENDX: + if (XML_READER_TYPE_ELEMENT == tokenType) + { +@@ -1068,6 +1071,7 @@ void libvisio::VSDXParser::readShapeProperties(xmlTextReaderPtr reader) + m_shape.m_xform1d = new XForm1D(); + ret = readDoubleData(m_shape.m_xform1d->endX, reader); + } ++ break; + case XML_ENDY: + if (XML_READER_TYPE_ELEMENT == tokenType) + { +-- +2.3.5 + diff --git a/0001-define-more-needed-namespaces.patch b/0001-define-more-needed-namespaces.patch new file mode 100644 index 0000000..d4c8b23 --- /dev/null +++ b/0001-define-more-needed-namespaces.patch @@ -0,0 +1,27 @@ +From 886221dccacd69d7dc7155fa42d3dd902286b846 Mon Sep 17 00:00:00 2001 +From: David Tardon +Date: Fri, 2 Jan 2015 22:21:41 +0100 +Subject: [PATCH] define more needed namespaces + +Change-Id: I83ada29e6bc89d8f045cfbe7c099ca5ec6553645 +--- + src/test/xmldrawinggenerator.cpp | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/src/test/xmldrawinggenerator.cpp b/src/test/xmldrawinggenerator.cpp +index 78484e0..771caff 100644 +--- a/src/test/xmldrawinggenerator.cpp ++++ b/src/test/xmldrawinggenerator.cpp +@@ -33,6 +33,9 @@ void XmlDrawingGenerator::startDocument(const librevenge::RVNGPropertyList &prop + + xmlTextWriterWriteAttribute(m_writer, BAD_CAST("xmlns:dc"), BAD_CAST("urn:oasis:names:tc:opendocument:xmlns:meta:1.0")); + xmlTextWriterWriteAttribute(m_writer, BAD_CAST("xmlns:draw"), BAD_CAST("urn:oasis:names:tc:opendocument:xmlns:drawing:1.0")); ++ xmlTextWriterWriteAttribute(m_writer, BAD_CAST("xmlns:fo"), BAD_CAST("urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0")); ++ xmlTextWriterWriteAttribute(m_writer, BAD_CAST("xmlns:librevenge"), BAD_CAST("urn:x-documentliberation:xmlns:librevenge:0.0")); ++ xmlTextWriterWriteAttribute(m_writer, BAD_CAST("xmlns:style"), BAD_CAST("urn:oasis:names:tc:opendocument:xmlns:style:1.0")); + xmlTextWriterWriteAttribute(m_writer, BAD_CAST("xmlns:svg"), BAD_CAST("urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0")); + xmlTextWriterWriteAttribute(m_writer, BAD_CAST("xmlns:meta"), BAD_CAST("urn:oasis:names:tc:opendocument:xmlns:meta:1.0")); + +-- +2.3.5 + diff --git a/libvisio.spec b/libvisio.spec index a25fc54..990e02b 100644 --- a/libvisio.spec +++ b/libvisio.spec @@ -20,6 +20,9 @@ BuildRequires: pkgconfig(librevenge-0.0) BuildRequires: pkgconfig(libxml-2.0) BuildRequires: pkgconfig(zlib) +Patch0: 0001-add-missing-breaks.patch +Patch1: 0001-define-more-needed-namespaces.patch + %description %{name} is library providing ability to interpret and import Microsoft Visio diagrams into various applications. You can find it @@ -49,7 +52,7 @@ Tools to transform Microsoft Visio diagrams into other formats. Currently supported: XHTML, raw, plain text. %prep -%setup -q +%autosetup -p1 %build %configure --disable-static --disable-silent-rules