Browse Source

Fix to avoid naming collisions between macros defined in AssertMacros.h on OSX and LuaType::check

David Wimsey 11 years ago
parent
commit
a431ca14ef
1 changed files with 11 additions and 0 deletions
  1. 11 0
      Build/CMakeLists.txt

+ 11 - 0
Build/CMakeLists.txt

@@ -63,6 +63,17 @@ if(NOT DEFINED ENV{LUA_DIR})
 	set(ENV{LUA_DIR} "${PROJECT_SOURCE_DIR}/../Dependencies")
 endif()
 
+#===================================
+# Plaform specific global hacks ====
+#===================================
+
+if(APPLE)
+	# Disables naked builtins from AssertMacros.h which
+	# This prevents naming collisions such as those from the check()
+	# function macro with LuaType::check
+	add_definitions(-D_ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES=0)
+endif(APPLE)
+
 #===================================
 # Build options ====================
 #===================================