From 5379be4045e788d9fd7de7840e7070ba9d8e6bc1 Mon Sep 17 00:00:00 2001 From: Micha Gorelick Date: Tue, 26 Feb 2013 14:08:03 -0500 Subject: [PATCH 1/2] Improved portability of murmurhash3.cpp --- MurmurHash3.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/MurmurHash3.cpp b/MurmurHash3.cpp index 302e974..8efa0f4 100644 --- a/MurmurHash3.cpp +++ b/MurmurHash3.cpp @@ -29,7 +29,12 @@ #else // defined(_MSC_VER) -#define FORCE_INLINE __attribute__((always_inline)) +#if defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4 && GNUC_MINOR >= 4)) +/* gcc version >= 4.4 4.1 = RHEL 5, 4.4 = RHEL 6. Don't inline for RHEL 5 gcc which is 4.1*/ +#define FORCE_INLINE attribute((always_inline)) +#else +#define FORCE_INLINE +#endif inline uint32_t rotl32 ( uint32_t x, int8_t r ) { From fdb0a3020403cf6317e4925c734694a1794074ef Mon Sep 17 00:00:00 2001 From: Micha Gorelick Date: Tue, 26 Feb 2013 14:11:46 -0500 Subject: [PATCH 2/2] Bumped version 2.1 -> 2.2 --- PKG-INFO | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/PKG-INFO b/PKG-INFO index a8b02e9..b36a981 100644 --- a/PKG-INFO +++ b/PKG-INFO @@ -1,6 +1,6 @@ Metadata-Version: 1.0 Name: mmh3 -Version: 2.1 +Version: 2.2 Summary: Python library for MurmurHash3, a set of fast and robust hash functions. Home-page: http://packages.python.org/mmh3 Author: Hajime Senuma diff --git a/setup.py b/setup.py index dbffa78..55ccd1f 100644 --- a/setup.py +++ b/setup.py @@ -8,7 +8,7 @@ sources = ['mmh3module.cpp', 'MurmurHash3.cpp']) setup(name = 'mmh3', - version = '2.1', + version = '2.2', description = 'Python library for MurmurHash (MurmurHash3), a set of fast and robust hash functions.', license = 'Public Domain', author = 'Hajime Senuma',