diff options
author | joerg <joerg@pkgsrc.org> | 2015-04-21 17:04:25 +0000 |
---|---|---|
committer | joerg <joerg@pkgsrc.org> | 2015-04-21 17:04:25 +0000 |
commit | 30f4af55ba80179664f244718f98364066e84b03 (patch) | |
tree | 18bf1e7ef7fc019ea68459a2579786dec54d3b45 /devel | |
parent | 78aa43d8a4e2425a0970503c1fda740063ec463a (diff) | |
download | pkgsrc-30f4af55ba80179664f244718f98364066e84b03.tar.gz |
Replace size_t overloads with long long overloads to help ILP32
platforms.
Diffstat (limited to 'devel')
-rw-r--r-- | devel/ogre/distinfo | 4 | ||||
-rw-r--r-- | devel/ogre/patches/patch-OgreMain_include_OgreStringConverter.h | 46 | ||||
-rw-r--r-- | devel/ogre/patches/patch-OgreMain_src_OgreStringConverter.cpp | 69 |
3 files changed, 118 insertions, 1 deletions
diff --git a/devel/ogre/distinfo b/devel/ogre/distinfo index 1f11954f26f..234d10d1989 100644 --- a/devel/ogre/distinfo +++ b/devel/ogre/distinfo @@ -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 --git a/devel/ogre/patches/patch-OgreMain_include_OgreStringConverter.h b/devel/ogre/patches/patch-OgreMain_include_OgreStringConverter.h new file mode 100644 index 00000000000..67d2c955ae3 --- /dev/null +++ b/devel/ogre/patches/patch-OgreMain_include_OgreStringConverter.h @@ -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 --git a/devel/ogre/patches/patch-OgreMain_src_OgreStringConverter.cpp b/devel/ogre/patches/patch-OgreMain_src_OgreStringConverter.cpp new file mode 100644 index 00000000000..ea34e3383e4 --- /dev/null +++ b/devel/ogre/patches/patch-OgreMain_src_OgreStringConverter.cpp @@ -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; |