Browse Source

Improved compiler detection

Christophe Riccio 14 years ago
parent
commit
b9a2087281
3 changed files with 5 additions and 4 deletions
  1. 1 1
      CMakeLists.txt
  2. 3 3
      glm/core/_detail.hpp
  3. 1 0
      test/gtc/gtc_matrix_access.cpp

+ 1 - 1
CMakeLists.txt

@@ -5,7 +5,7 @@ project(glm)
 enable_testing()
 
 add_definitions(-D_CRT_SECURE_NO_WARNINGS)
-add_definitions(/Za)
+#add_definitions(/Za)
 #add_definitions(-pedantic)
 #add_definitions(-S)
 #add_definitions(-s)

+ 3 - 3
glm/core/_detail.hpp

@@ -24,15 +24,15 @@ namespace detail
 #elif(GLM_COMPILER & GLM_COMPILER_VC)
 	typedef signed __int64						sint64;
 	typedef unsigned __int64					uint64;
-#elif(GLM_COMPILER & GLM_COMPILER_GCC)
+#elif(GLM_COMPILER & (GLM_COMPILER_GCC | GLM_COMPILER_LLVM_GCC | GLM_COMPILER_CLANG))
 	__extension__ typedef signed long long		sint64;
 	__extension__ typedef unsigned long long	uint64;
 #elif(GLM_COMPILER & GLM_COMPILER_BC)
 	typedef Int64								sint64;
 	typedef Uint64								uint64;
 #else//unknown compiler
-	typedef signed long							sint64;
-	typedef unsigned long						uint64;
+	typedef signed long	long					sint64;
+	typedef unsigned long long					uint64;
 #endif//GLM_COMPILER
 
 	template<bool C>

+ 1 - 0
test/gtc/gtc_matrix_access.cpp

@@ -7,6 +7,7 @@
 // File    : test/gtc/matrix_access.cpp
 ///////////////////////////////////////////////////////////////////////////////////////////////////
 
+#define GLM_MESSAGES
 #include <glm/glm.hpp>
 #include <glm/gtc/matrix_access.hpp>