diff options
author | Fridrich Štrba <fridrich.strba@bluewin.ch> | 2011-06-23 19:26:17 +0200 |
---|---|---|
committer | Fridrich Štrba <fridrich.strba@bluewin.ch> | 2011-06-23 19:29:03 +0200 |
commit | fc6086c720fff5a6397f7146df545226012fd6dc (patch) | |
tree | 86e7bcde86c01feab89970381e39666704a7c14b /libvisio | |
parent | ade88aaba235ba7eb4463fa3a4429650a2898f70 (diff) |
Upload alpha1 version of libvisio
Diffstat (limited to 'libvisio')
-rw-r--r-- | libvisio/libvisio-0.0.1-warnings.patch | 217 | ||||
-rw-r--r-- | libvisio/libvisio-0.0.1.patch | 20 | ||||
-rw-r--r-- | libvisio/libvisio-android.patch | 4 | ||||
-rw-r--r-- | libvisio/libvisio-mingw-cross.patch | 4 | ||||
-rw-r--r-- | libvisio/makefile.mk | 13 |
5 files changed, 249 insertions, 9 deletions
diff --git a/libvisio/libvisio-0.0.1-warnings.patch b/libvisio/libvisio-0.0.1-warnings.patch new file mode 100644 index 000000000000..baa7a911a793 --- /dev/null +++ b/libvisio/libvisio-0.0.1-warnings.patch @@ -0,0 +1,217 @@ +--- misc/libvisio-0.0.1/src/lib/VSD11Parser.cpp 2011-06-23 16:38:31.000000000 +0200 ++++ misc/build/libvisio-0.0.1/src/lib/VSD11Parser.cpp 2011-06-23 19:21:13.365713910 +0200 +@@ -46,11 +46,10 @@ + return sColour; + } + +-const struct libvisio::VSD11Parser::StreamHandler libvisio::VSD11Parser::streamHandlers[] = +-{ ++const libvisio::VSD11Parser::StreamHandler libvisio::VSD11Parser::streamHandlers[] = { + {0xa, "Name", 0}, + {0xb, "Name Idx", 0}, +- {0x14, "Trailer, 0"}, ++ {0x14, "Trailer", 0}, + {0x15, "Page", &libvisio::VSD11Parser::handlePage}, + {0x16, "Colors", &libvisio::VSD11Parser::handleColours}, + {0x17, "??? seems to have no data", 0}, +@@ -58,7 +57,7 @@ + {0x1a, "Styles", 0}, + {0x1b, "??? saw 'Acrobat PDFWriter' string here", 0}, + {0x1c, "??? saw 'winspool.Acrobat PDFWriter.LPT1' string here", 0}, +- {0x1d, "Stencils"}, ++ {0x1d, "Stencils", 0}, + {0x1e, "Stencil Page (collection of Shapes, one collection per each stencil item)", 0}, + {0x20, "??? seems to have no data", 0}, + {0x21, "??? seems to have no data", 0}, +@@ -141,10 +140,10 @@ + ptrFormat = readU16(&trailerStream); + + int index = -1; +- for (int i = 0; (index < 0) && streamHandlers[i].type; i++) ++ for (int j = 0; (index < 0) && streamHandlers[j].type; j++) + { +- if (streamHandlers[i].type == ptrType) +- index = i; ++ if (streamHandlers[j].type == ptrType) ++ index = j; + } + + if (index < 0) +@@ -199,10 +198,10 @@ + ptrFormat = readU16(&stream); + + int index = -1; +- for (int i = 0; (index < 0) && streamHandlers[i].type; i++) ++ for (int j = 0; (index < 0) && streamHandlers[j].type; j++) + { +- if (streamHandlers[i].type == ptrType) +- index = i; ++ if (streamHandlers[j].type == ptrType) ++ index = j; + } + + if (index < 0) +@@ -225,8 +224,8 @@ + + bool compressed = ((ptrFormat & 2) == 2); + m_input->seek(ptrOffset, WPX_SEEK_SET); +- VSDInternalStream stream(m_input, ptrLength, compressed); +- (this->*streamHandler)(stream, painter); ++ VSDInternalStream tmpStream(m_input, ptrLength, compressed); ++ (this->*streamHandler)(tmpStream, painter); + } + } + } +@@ -234,7 +233,7 @@ + + void libvisio::VSD11Parser::handlePage(VSDInternalStream &stream, libwpg::WPGPaintInterface *painter) + { +- ChunkHeader header = {0}; ++ ChunkHeader header; + m_groupXForms.clear(); + + while (!stream.atEOS()) +@@ -294,11 +293,11 @@ + } + } + +-void libvisio::VSD11Parser::handleColours(VSDInternalStream &stream, libwpg::WPGPaintInterface *painter) ++void libvisio::VSD11Parser::handleColours(VSDInternalStream &stream, libwpg::WPGPaintInterface * /*painter*/) + { + stream.seek(6, WPX_SEEK_SET); + unsigned int numColours = readU8(&stream); +- Colour tmpColour = {0}; ++ Colour tmpColour; + + stream.seek(1, WPX_SEEK_CUR); + +@@ -318,10 +317,10 @@ + WPXPropertyListVector path; + WPXPropertyList styleProps; + WPXPropertyListVector gradientProps; +- XForm xform = {0}; // Shape xform data ++ XForm xform; // Shape xform data + unsigned int foreignType = 0; // Tracks current foreign data type + unsigned int foreignFormat = 0; // Tracks foreign data format +- ChunkHeader header = {0}; ++ ChunkHeader header; + unsigned long tmpBytesRead = 0; + unsigned long streamPos = 0; + +@@ -378,7 +377,7 @@ + stream.seek(1, WPX_SEEK_CUR); + styleProps.insert("svg:stroke-width", m_scale*readDouble(&stream)); + stream.seek(1, WPX_SEEK_CUR); +- Colour c = {0}; ++ Colour c; + c.r = readU8(&stream); + c.g = readU8(&stream); + c.b = readU8(&stream); +--- misc/libvisio-0.0.1/src/lib/VSD11Parser.h 2011-06-23 16:38:31.000000000 +0200 ++++ misc/build/libvisio-0.0.1/src/lib/VSD11Parser.h 2011-06-23 18:34:24.733064592 +0200 +@@ -41,7 +41,7 @@ + + typedef void (VSD11Parser::*StreamMethod)(VSDInternalStream&, libwpg::WPGPaintInterface*); + struct StreamHandler { unsigned int type; const char *name; StreamMethod handler;}; +- static const struct StreamHandler streamHandlers[32]; ++ static const StreamHandler streamHandlers[]; + + typedef void (VSD11Parser::*ChunkMethod)(VSDInternalStream&, libwpg::WPGPaintInterface*); + struct ChunkHandler { unsigned int type; const char *name; ChunkMethod handler;}; +--- misc/libvisio-0.0.1/src/lib/VSD6Parser.cpp 2011-06-23 16:38:31.000000000 +0200 ++++ misc/build/libvisio-0.0.1/src/lib/VSD6Parser.cpp 2011-06-23 19:22:14.762503528 +0200 +@@ -26,19 +26,18 @@ + #include "VSD6Parser.h" + #include "VSDInternalStream.h" + +-const struct libvisio::VSD6Parser::StreamHandler libvisio::VSD6Parser::handlers[] = +-{ ++const libvisio::VSD6Parser::StreamHandler libvisio::VSD6Parser::handlers[] = { + {0xa, "Name", 0}, + {0xb, "Name Idx", 0}, +- {0x14, "Trailer, 0"}, ++ {0x14, "Trailer", 0}, + {0x15, "Page", &libvisio::VSD6Parser::handlePage}, +- {0x16, "Colors"}, ++ {0x16, "Colors", 0}, + {0x17, "??? seems to have no data", 0}, + {0x18, "FontFaces (ver.11)", 0}, + {0x1a, "Styles", 0}, + {0x1b, "??? saw 'Acrobat PDFWriter' string here", 0}, + {0x1c, "??? saw 'winspool.Acrobat PDFWriter.LPT1' string here", 0}, +- {0x1d, "Stencils"}, ++ {0x1d, "Stencils", 0}, + {0x1e, "Stencil Page (collection of Shapes, one collection per each stencil item)", 0}, + {0x20, "??? seems to have no data", 0}, + {0x21, "??? seems to have no data", 0}, +@@ -113,10 +112,10 @@ + ptrFormat = readU16(&trailerStream); + + int index = -1; +- for (int i = 0; (index < 0) && handlers[i].type; i++) ++ for (int j = 0; (index < 0) && handlers[j].type; i++) + { +- if (handlers[i].type == ptrType) +- index = i; ++ if (handlers[j].type == ptrType) ++ index = j; + } + + if (index < 0) +@@ -171,10 +170,10 @@ + ptrFormat = readU16(&stream); + + int index = -1; +- for (int i = 0; (index < 0) && handlers[i].type; i++) ++ for (int j = 0; (index < 0) && handlers[j].type; j++) + { +- if (handlers[i].type == ptrType) +- index = i; ++ if (handlers[j].type == ptrType) ++ index = j; + } + + if (index < 0) +@@ -197,8 +196,8 @@ + + bool compressed = ((ptrFormat & 2) == 2); + m_input->seek(ptrOffset, WPX_SEEK_SET); +- VSDInternalStream stream(m_input, ptrLength, compressed); +- (this->*streamHandler)(stream, painter); ++ VSDInternalStream tmpStream(m_input, ptrLength, compressed); ++ (this->*streamHandler)(tmpStream, painter); + } + } + } +@@ -207,7 +206,7 @@ + void libvisio::VSD6Parser::handlePage(VSDInternalStream &stream, libwpg::WPGPaintInterface *painter) + { + WPXPropertyList pageProps; +- XForm xform = {0}; // Tracks current xform data ++ XForm xform; // Tracks current xform data + unsigned int foreignType = 0; // Tracks current foreign data type + unsigned int foreignFormat = 0; // Tracks foreign data format + unsigned long tmpBytesRead = 0; +--- misc/libvisio-0.0.1/src/lib/VSD6Parser.h 2011-06-23 16:38:31.000000000 +0200 ++++ misc/build/libvisio-0.0.1/src/lib/VSD6Parser.h 2011-06-23 18:35:03.491206892 +0200 +@@ -41,7 +41,7 @@ + + typedef void (VSD6Parser::*Method)(VSDInternalStream&, libwpg::WPGPaintInterface*); + struct StreamHandler { unsigned int type; const char *name; Method handler;}; +- static const struct StreamHandler handlers[32]; ++ static const StreamHandler handlers[]; + void handlePages(VSDInternalStream &stream, libwpg::WPGPaintInterface *painter); + void handlePage(VSDInternalStream &stream, libwpg::WPGPaintInterface *painter); + }; +--- misc/libvisio-0.0.1/src/lib/VSDXParser.h 2011-06-23 16:38:31.000000000 +0200 ++++ misc/build/libvisio-0.0.1/src/lib/VSDXParser.h 2011-06-23 19:18:51.492069602 +0200 +@@ -53,6 +53,9 @@ + bool flipY; + double x; + double y; ++ XForm() : pinX(0.0), pinY(0.0), height(0.0), width(0.0), ++ pinLocX(0.0), pinLocY(0.0), angle(0.0), ++ flipX(false), flipY(false), x(0.0), y(0.0) {} + }; + + bool m_isPageStarted; diff --git a/libvisio/libvisio-0.0.1.patch b/libvisio/libvisio-0.0.1.patch new file mode 100644 index 000000000000..b00f54fa065c --- /dev/null +++ b/libvisio/libvisio-0.0.1.patch @@ -0,0 +1,20 @@ +--- misc/libvisio-0.0.1/src/lib/libvisio_utils.h 2011-06-23 16:38:31.000000000 +0200 ++++ misc/build/libvisio-0.0.1/src/lib/libvisio_utils.h 2011-06-23 17:41:15.259239694 +0200 +@@ -31,17 +31,8 @@ + + #else + +-#ifdef HAVE_CONFIG_H +-#include <config.h> +-#endif +- +-#ifdef HAVE_STDINT_H + #include <stdint.h> +-#endif +- +-#ifdef HAVE_INTTYPES_H + #include <inttypes.h> +-#endif + + #endif + diff --git a/libvisio/libvisio-android.patch b/libvisio/libvisio-android.patch index b547913757d0..74ff767041dd 100644 --- a/libvisio/libvisio-android.patch +++ b/libvisio/libvisio-android.patch @@ -1,5 +1,5 @@ ---- misc/build/libvisio-0.0.0/src/lib/VSDSVGGenerator.cpp -+++ misc/build/libvisio-0.0.0/src/lib/VSDSVGGenerator.cpp +--- misc/build/libvisio-0.0.1/src/lib/VSDSVGGenerator.cpp ++++ misc/build/libvisio-0.0.1/src/lib/VSDSVGGenerator.cpp @@ -33,7 +33,11 @@ { std::ostringstream tempStream; diff --git a/libvisio/libvisio-mingw-cross.patch b/libvisio/libvisio-mingw-cross.patch index 0a29ff1bc4f9..957d5058ed13 100644 --- a/libvisio/libvisio-mingw-cross.patch +++ b/libvisio/libvisio-mingw-cross.patch @@ -1,5 +1,5 @@ ---- misc/build/libvisio-0.0.0/src/lib/makefile.mk -+++ misc/build/libvisio-0.0.0/src/lib/makefile.mk +--- misc/build/libvisio-0.0.1/src/lib/makefile.mk ++++ misc/build/libvisio-0.0.1/src/lib/makefile.mk @@ -9,7 +9,7 @@ .INCLUDE : settings.mk diff --git a/libvisio/makefile.mk b/libvisio/makefile.mk index 7f2cbf3c01a4..d3bcfe678bf7 100644 --- a/libvisio/makefile.mk +++ b/libvisio/makefile.mk @@ -32,7 +32,7 @@ TARGET=visio # --- Settings ----------------------------------------------------- -.INCLUDE : settings.mk +.INCLUDE : settings.mk # --- Files -------------------------------------------------------- @@ -54,18 +54,21 @@ INCPRE+=$(LIBWPG_CFLAGS) INCPRE+=$(SOLARVER)$/$(UPD)$/$(INPATH)$/inc$/libwpg .ENDIF -TARFILE_NAME=libvisio-0.0.0 -TARFILE_MD5=763bb9b14eec5ba9a533d7a9279301db +TARFILE_NAME=libvisio-0.0.1 +TARFILE_MD5=4bb835ea2225c8f5f6c2b2e63d25993c PATCH_FILES=\ + libvisio-0.0.1.patch \ + libvisio-0.0.1-warnings.patch \ libvisio-mingw-cross.patch \ libvisio-android.patch + BUILD_ACTION=dmake $(MFLAGS) $(CALLMACROS) BUILD_DIR=src$/lib # --- Targets ------------------------------------------------------ .INCLUDE : set_ext.mk -.INCLUDE : target.mk -.INCLUDE : tg_ext.mk +.INCLUDE : target.mk +.INCLUDE : tg_ext.mk |