From 8a6ed11da938f1bea0b36eff1a9c1d68246ebf06 Mon Sep 17 00:00:00 2001 From: Brian Jensen Date: Sat, 26 Oct 2013 21:48:48 +0200 Subject: [PATCH] fix compilation issue on OS X 10.9 --- ext/sparsehash/google/sparsehash/sparseconfig.h | 9 +++++++++ 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/ext/sparsehash/google/sparsehash/sparseconfig.h b/ext/sparsehash/google/sparsehash/sparseconfig.h index 44a4dda..8cf2f1c 100644 --- a/ext/sparsehash/google/sparsehash/sparseconfig.h +++ b/ext/sparsehash/google/sparsehash/sparseconfig.h @@ -13,6 +13,15 @@ #define HASH_NAMESPACE stdext /* The system-provided hash function including the namespace. */ #define SPARSEHASH_HASH HASH_NAMESPACE::hash_compare +/* libc++ does not implement the tr1 namespce so use the c++11 + * definitions for systems that use it (OS X 10.9) */ +#elif __clang__ && __has_include() + /* the location of the header defining hash functions */ + #define HASH_FUN_H + /* the namespace of the hash<> function */ + #define HASH_NAMESPACE std + /* The system-provided hash function including the namespace. */ + #define SPARSEHASH_HASH HASH_NAMESPACE::hash #else /* the location of the header defining hash functions */ #define HASH_FUN_H -- 1.7.1