pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/devel/ogre Replace size_t overloads with long long ove...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/d988365dcf82
branches:  trunk
changeset: 650341:d988365dcf82
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Tue Apr 21 17:04:25 2015 +0000

description:
Replace size_t overloads with long long overloads to help ILP32
platforms.

diffstat:

 devel/ogre/distinfo                                             |   4 +-
 devel/ogre/patches/patch-OgreMain_include_OgreStringConverter.h |  46 ++++++
 devel/ogre/patches/patch-OgreMain_src_OgreStringConverter.cpp   |  69 ++++++++++
 3 files changed, 118 insertions(+), 1 deletions(-)

diffs (136 lines):

diff -r bd8ee777dc38 -r d988365dcf82 devel/ogre/distinfo
--- a/devel/ogre/distinfo       Tue Apr 21 17:02:51 2015 +0000
+++ b/devel/ogre/distinfo       Tue Apr 21 17:04:25 2015 +0000
@@ -1,6 +1,8 @@
-$NetBSD: distinfo,v 1.7 2010/08/30 20:30:28 wiz Exp $
+$NetBSD: distinfo,v 1.8 2015/04/21 17:04:25 joerg Exp $
 
 SHA1 (ogre-v1-6-3.tar.bz2) = 0bde8f8d982151c561e9e6c9ccb51e0d19b5eab6
 RMD160 (ogre-v1-6-3.tar.bz2) = e1e16c152d5cb3141e306e4886092b5675695e9a
 Size (ogre-v1-6-3.tar.bz2) = 41790055 bytes
+SHA1 (patch-OgreMain_include_OgreStringConverter.h) = 8ef476c0056fdf69b4f158e5e8c85bb3b0c0c386
+SHA1 (patch-OgreMain_src_OgreStringConverter.cpp) = 6c1cc7f6f5c23c68ebc0cee33d661ba199d836e9
 SHA1 (patch-aa) = 414c2f02124352cf89d2ebaa2a5c10c71b2be095
diff -r bd8ee777dc38 -r d988365dcf82 devel/ogre/patches/patch-OgreMain_include_OgreStringConverter.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/ogre/patches/patch-OgreMain_include_OgreStringConverter.h   Tue Apr 21 17:04:25 2015 +0000
@@ -0,0 +1,46 @@
+$NetBSD: patch-OgreMain_include_OgreStringConverter.h,v 1.1 2015/04/21 17:04:25 joerg Exp $
+
+--- OgreMain/include/OgreStringConverter.h.orig        2015-04-17 11:25:21.000000000 +0000
++++ OgreMain/include/OgreStringConverter.h
+@@ -80,34 +80,24 @@ namespace Ogre {
+         static String toString(int val, unsigned short width = 0, 
+             char fill = ' ', 
+             std::ios::fmtflags flags = std::ios::fmtflags(0) );
+-#if OGRE_ARCH_TYPE == OGRE_ARCHITECTURE_64 || OGRE_PLATFORM == OGRE_PLATFORM_APPLE
+         /** Converts an unsigned int to a String. */
+         static String toString(unsigned int val, 
+             unsigned short width = 0, char fill = ' ', 
+             std::ios::fmtflags flags = std::ios::fmtflags(0) );
+-        /** Converts a size_t to a String. */
+-        static String toString(size_t val, 
+-            unsigned short width = 0, char fill = ' ', 
+-            std::ios::fmtflags flags = std::ios::fmtflags(0) );
+-        #if OGRE_COMPILER == OGRE_COMPILER_MSVC
+-                /** Converts an unsigned long to a String. */
+-                static String toString(unsigned long val, 
+-                    unsigned short width = 0, char fill = ' ', 
+-                    std::ios::fmtflags flags = std::ios::fmtflags(0) );
+-
+-        #endif
+-#else
+-        /** Converts a size_t to a String. */
+-        static String toString(size_t val, 
++        /** Converts a long to a String. */
++        static String toString(long val, 
+             unsigned short width = 0, char fill = ' ', 
+             std::ios::fmtflags flags = std::ios::fmtflags(0) );
+         /** Converts an unsigned long to a String. */
+         static String toString(unsigned long val, 
+             unsigned short width = 0, char fill = ' ', 
+             std::ios::fmtflags flags = std::ios::fmtflags(0) );
+-#endif
+         /** Converts a long to a String. */
+-        static String toString(long val, 
++        static String toString(long long val, 
++            unsigned short width = 0, char fill = ' ', 
++            std::ios::fmtflags flags = std::ios::fmtflags(0) );
++        /** Converts an unsigned long to a String. */
++        static String toString(unsigned long long val, 
+             unsigned short width = 0, char fill = ' ', 
+             std::ios::fmtflags flags = std::ios::fmtflags(0) );
+         /** Converts a boolean to a String. 
diff -r bd8ee777dc38 -r d988365dcf82 devel/ogre/patches/patch-OgreMain_src_OgreStringConverter.cpp
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/devel/ogre/patches/patch-OgreMain_src_OgreStringConverter.cpp     Tue Apr 21 17:04:25 2015 +0000
@@ -0,0 +1,69 @@
+$NetBSD: patch-OgreMain_src_OgreStringConverter.cpp,v 1.1 2015/04/21 17:04:25 joerg Exp $
+
+--- OgreMain/src/OgreStringConverter.cpp.orig  2015-04-17 11:32:19.000000000 +0000
++++ OgreMain/src/OgreStringConverter.cpp
+@@ -64,7 +64,6 @@ namespace Ogre {
+         return stream.str();
+     }
+     //-----------------------------------------------------------------------
+-#if OGRE_ARCH_TYPE == OGRE_ARCHITECTURE_64 || OGRE_PLATFORM == OGRE_PLATFORM_APPLE    
+     String StringConverter::toString(unsigned int val, 
+         unsigned short width, char fill, std::ios::fmtflags flags)
+     {
+@@ -77,19 +76,6 @@ namespace Ogre {
+         return stream.str();
+     }
+     //-----------------------------------------------------------------------
+-    String StringConverter::toString(size_t val, 
+-        unsigned short width, char fill, std::ios::fmtflags flags)
+-    {
+-        StringUtil::StrStreamType stream;
+-        stream.width(width);
+-        stream.fill(fill);
+-        if (flags)
+-            stream.setf(flags);
+-        stream << val;
+-        return stream.str();
+-    }
+-#if OGRE_COMPILER == OGRE_COMPILER_MSVC
+-    //-----------------------------------------------------------------------
+     String StringConverter::toString(unsigned long val, 
+         unsigned short width, char fill, std::ios::fmtflags flags)
+     {
+@@ -101,11 +87,7 @@ namespace Ogre {
+         stream << val;
+         return stream.str();
+     }
+-
+-#endif
+-    //-----------------------------------------------------------------------
+-#else
+-    String StringConverter::toString(size_t val, 
++    String StringConverter::toString(long val, 
+         unsigned short width, char fill, std::ios::fmtflags flags)
+     {
+         StringUtil::StrStreamType stream;
+@@ -117,20 +99,18 @@ namespace Ogre {
+         return stream.str();
+     }
+     //-----------------------------------------------------------------------
+-    String StringConverter::toString(unsigned long val, 
++    String StringConverter::toString(unsigned long long val, 
+         unsigned short width, char fill, std::ios::fmtflags flags)
+     {
+         StringUtil::StrStreamType stream;
+-              stream.width(width);
++        stream.width(width);
+         stream.fill(fill);
+         if (flags)
+             stream.setf(flags);
+         stream << val;
+         return stream.str();
+     }
+-    //-----------------------------------------------------------------------
+-#endif
+-    String StringConverter::toString(long val, 
++    String StringConverter::toString(long long val, 
+         unsigned short width, char fill, std::ios::fmtflags flags)
+     {
+         StringUtil::StrStreamType stream;



Home | Main Index | Thread Index | Old Index