From c7613d5402ab4d15b9bedc1df26e6026a9f5875b Mon Sep 17 00:00:00 2001 From: reed Date: Thu, 9 Oct 2003 18:38:34 +0000 Subject: Added five patches so koffice would build with newer gcc 3.3.1. The first four patches come directly from KDE's cvs for KOFFICE_1_2_BRANCH. The patch-ae comes from a KDE bug report. I did not bump the revision, because no features changed -- this just makes it build on some platforms that couldn't build before. It is said that these fixes use a non-standard C++ header and maybe may not work with some compilers. --- misc/koffice/distinfo | 7 ++++- misc/koffice/patches/patch-aa | 35 ++++++++++++++++++++++ misc/koffice/patches/patch-ab | 49 ++++++++++++++++++++++++++++++ misc/koffice/patches/patch-ac | 22 ++++++++++++++ misc/koffice/patches/patch-ad | 13 ++++++++ misc/koffice/patches/patch-ae | 70 +++++++++++++++++++++++++++++++++++++++++++ 6 files changed, 195 insertions(+), 1 deletion(-) create mode 100644 misc/koffice/patches/patch-aa create mode 100644 misc/koffice/patches/patch-ab create mode 100644 misc/koffice/patches/patch-ac create mode 100644 misc/koffice/patches/patch-ad create mode 100644 misc/koffice/patches/patch-ae diff --git a/misc/koffice/distinfo b/misc/koffice/distinfo index ab62ef9a64d..826d9d68f36 100644 --- a/misc/koffice/distinfo +++ b/misc/koffice/distinfo @@ -1,6 +1,11 @@ -$NetBSD: distinfo,v 1.9 2003/04/09 13:57:14 markd Exp $ +$NetBSD: distinfo,v 1.10 2003/10/09 18:38:34 reed Exp $ SHA1 (koffice-1.2.1.tar.bz2) = f3fd98d081205f2cd7be3fba76e4cf5b053b8e53 Size (koffice-1.2.1.tar.bz2) = 9275595 bytes SHA1 (1.2.1_kword_crashes.diff) = 13b6a4843ec918371e6de1622be1154d984aa76b Size (1.2.1_kword_crashes.diff) = 3816 bytes +SHA1 (patch-aa) = c711cd21da907908c606d2adea39f512431ba113 +SHA1 (patch-ab) = 8eacc52e66341c58075f5ba1e9a26fe8998c7a81 +SHA1 (patch-ac) = e3f2b1f00d98750835907ff6812eef1ed5160d57 +SHA1 (patch-ad) = 32cebc69bc5ba2cad7ddab97a81beb92836802f1 +SHA1 (patch-ae) = aa9f553f4c908ba85cedf8adb6ad7385677029eb diff --git a/misc/koffice/patches/patch-aa b/misc/koffice/patches/patch-aa new file mode 100644 index 00000000000..7a4d3c108fe --- /dev/null +++ b/misc/koffice/patches/patch-aa @@ -0,0 +1,35 @@ +$NetBSD: patch-aa,v 1.6 2003/10/09 18:38:34 reed Exp $ + +formula.cc:4:23: strstream.h: No such file or directory +formula.cc:477: error: `ostrstream' undeclared (first use this function) + +--- filters/kspread/qpro/libqpro/src/formula.cc.orig 2003-09-29 16:37:17.000000000 +0000 ++++ filters/kspread/qpro/libqpro/src/formula.cc 2003-09-29 16:37:41.000000000 +0000 +@@ -1,7 +1,7 @@ + #include + +-#include +-#include ++#include ++#include + + #include + +@@ -474,7 +474,7 @@ + QpFormula::floatFuncReal(const char*) + { + QP_INT64 lFloat; +- ostrstream lNum; ++ std::ostrstream lNum; + + cFormula >> lFloat; + +@@ -489,7 +489,7 @@ + QpFormula::intFuncReal(const char*) + { + QP_INT16 lInt; +- ostrstream lNum; ++ std::ostrstream lNum; + + cFormula >> lInt; + diff --git a/misc/koffice/patches/patch-ab b/misc/koffice/patches/patch-ab new file mode 100644 index 00000000000..78b33ef1f33 --- /dev/null +++ b/misc/koffice/patches/patch-ab @@ -0,0 +1,49 @@ +$NetBSD: patch-ab,v 1.4 2003/10/09 18:38:34 reed Exp $ + +--- filters/kspread/qpro/libqpro/src/record.cc.orig 2003-09-29 16:45:05.000000000 +0000 ++++ filters/kspread/qpro/libqpro/src/record.cc 2003-09-29 16:46:18.000000000 +0000 +@@ -2,7 +2,7 @@ + + #include + +-#include ++#include + + #include + #include +@@ -10,7 +10,7 @@ + // ----------------------------------------------------------------------- + + #include +-#include ++#include + + void + Charout(ostream& pOut, unsigned char pChar) +@@ -32,7 +32,7 @@ + int + Hexout(char* pChar, int pLen) + { +- ostrstream* lOStr = new ostrstream; ++ std::ostrstream* lOStr = new std::ostrstream; + + while( pLen ) + { +@@ -57,7 +57,7 @@ + cerr << lOStr->rdbuf() << endl; + + delete lOStr; +- lOStr = new ostrstream; ++ lOStr = new std::ostrstream; + } + + delete lOStr; +@@ -200,7 +200,7 @@ + { + //??? cope with relative/absolute references + +- strstream lOut(pText, 20, ios::out); // ??? ard coded len ++ std::strstream lOut(pText, 20, ios::out); // ??? ard coded len + int lPageRelative = pRow & 0x8000; + int lColRelative = pRow & 0x4000; + int lRowRelative = pRow & 0x2000; diff --git a/misc/koffice/patches/patch-ac b/misc/koffice/patches/patch-ac new file mode 100644 index 00000000000..965bad8d579 --- /dev/null +++ b/misc/koffice/patches/patch-ac @@ -0,0 +1,22 @@ +$NetBSD: patch-ac,v 1.4 2003/10/09 18:38:34 reed Exp $ + +--- filters/kspread/qpro/libqpro/src/stream.cc.orig 2003-09-29 16:48:06.000000000 +0000 ++++ filters/kspread/qpro/libqpro/src/stream.cc 2003-09-29 16:48:38.000000000 +0000 +@@ -31,7 +31,7 @@ + #else + #include + #include +-#include ++#include + + // For IRIX + namespace std {} +@@ -60,7 +60,7 @@ + , cOffset(0L) + , cStreamBuf(0) + { +- cStreamBuf = new strstreambuf (pBuffer, pLen); ++ cStreamBuf = new std::strstreambuf (pBuffer, pLen); + + cIn = new istream(cStreamBuf); + } diff --git a/misc/koffice/patches/patch-ad b/misc/koffice/patches/patch-ad new file mode 100644 index 00000000000..a93804509d3 --- /dev/null +++ b/misc/koffice/patches/patch-ad @@ -0,0 +1,13 @@ +$NetBSD: patch-ad,v 1.5 2003/10/09 18:38:34 reed Exp $ + +--- filters/kspread/qpro/qproimport.cc.orig 2003-09-29 16:51:50.000000000 +0000 ++++ filters/kspread/qpro/qproimport.cc 2003-09-29 16:51:57.000000000 +0000 +@@ -18,7 +18,7 @@ + Boston, MA 02111-1307, USA. + */ + +-#include ++#include + + #include + #include diff --git a/misc/koffice/patches/patch-ae b/misc/koffice/patches/patch-ae new file mode 100644 index 00000000000..ed7c229c590 --- /dev/null +++ b/misc/koffice/patches/patch-ae @@ -0,0 +1,70 @@ +$NetBSD: patch-ae,v 1.4 2003/10/09 18:38:34 reed Exp $ + +table.cc:171: error: ISO C++ forbids variable-size array `border' +http://bugs.kde.org/show_bug.cgi?id=62906 + +--- filters/kword/latex/export/table.cc~ 2002-05-25 03:16:02.000000000 -0700 ++++ filters/kword/latex/export/table.cc 2003-08-19 14:03:48.000000000 -0700 +@@ -20,6 +20,7 @@ + */ + + #include /* for kdDebug stream */ ++#include + #include "listtable.h" + #include "texte.h" + +@@ -168,7 +169,7 @@ + void Table::generateTopLineBorder(QTextStream& out, int row) + { + Element* elt = 0; +- bool border[getMaxCol()]; ++ QBitArray border(getMaxCol()); + bool fullLine = true; + for(int index = 0; index <= getMaxCol(); index++) + { +@@ -179,11 +180,11 @@ + /* If the element has a border display it here */ + if(elt->hasTopBorder()) + { +- border[index] = true; ++ border[index] = 1; + } + else + { +- border[index] = false; ++ border[index] = 0; + fullLine = false; + } + } +@@ -221,7 +222,7 @@ + void Table::generateBottomLineBorder(QTextStream& out, int row) + { + Element* elt = 0; +- bool border[getMaxCol()]; ++ QBitArray border(getMaxCol()); + bool fullLine = true; + + for(int index = 0; index <= getMaxCol(); index++) +@@ -232,11 +233,11 @@ + /* If the element has a border display it here */ + if(elt->hasBottomBorder()) + { +- border[index] = true; ++ border[index] = 1; + } + else + { +- border[index] = false; ++ border[index] = 0; + fullLine = false; + } + } +@@ -256,7 +257,7 @@ + { + int begin = index; + int end = index; +- while(border[index] == true && index <= getMaxCol()) ++ while(border[index] && index <= getMaxCol()) + { + index = index + 1; + } -- cgit v1.2.3