Menu

#754 build fails on Mac OS X 10.9 Mavericks

svn version
closed-fixed
nobody
None
5
2014-08-16
2014-02-10
No

Build fails on Mac OS X 10.9. The default compiler is now clang on this OS, and it uses libc++ by default. The following patch fixes the build:

Index: library/tulip-core/include/tulip/tuliphash.h
===================================================================
--- library/tulip-core/include/tulip/tuliphash.h    (revision 9969)
+++ library/tulip-core/include/tulip/tuliphash.h    (working copy)
@@ -30,12 +30,17 @@
  * TLP_END_HASH_NAMESPACE is definde to close the namespace (only used when using std::tr1)
  * TLP_HASH_NAMESPACE allows to use a specific hasher class when declaring a hash set or a hash map.
  */
+ 
+// to search for _LIBCPP_VERSION
+#include <ciso646>

 //VS2010 and later can use C++0x's unordered_map; vs2008 uses boost's tr1 implementation
 #if defined(_MSC_VER) && (_MSC_VER > 1500)
 #  define TLP_USE_UNORDERED_MAP
 #elif defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L
 #  define TLP_USE_UNORDERED_MAP
+#elif defined(_LIBCPP_VERSION)
+#  define TLP_USE_UNORDERED_MAP
 #endif

 #ifdef TLP_USE_UNORDERED_MAP

Discussion

  • Patrick Mary

    Patrick Mary - 2014-02-10
    • status: open --> closed-fixed
     
  • Patrick Mary

    Patrick Mary - 2014-02-10

    Thank you very much for your report, your patch has been integrated.
    This bug is now fixed in the current svn code line (revision #9970).

     

Log in to post a comment.