Add support for VC++11 (2012)

This commit is contained in:
David Capello 2012-10-30 21:08:33 -03:00
parent 7595227166
commit 7a062b61a8
5 changed files with 16 additions and 3 deletions

View File

@ -123,6 +123,13 @@ if(ENABLE_MEMLEAK)
add_definitions(-DMEMLEAK)
endif()
# Fix to compile gtest with VC11 (2012)
if(NOT USE_SHARED_GTEST)
if (MSVC_VERSION EQUAL 1700)
add_definitions(-D_VARIADIC_MAX=10)
endif()
endif()
######################################################################
# Platform specific stuff

View File

@ -44,7 +44,7 @@ set(FRAMEWORK_INSTALL_PREFIX "/Library/Frameworks" CACHE STRING
#-----------------------------------------------------------------------------#
#
# Unix platform checks
# Platform checks
#
include(CheckIncludeFiles)
@ -71,7 +71,6 @@ if(UNIX)
check_include_files(linux/soundcard.h ALLEGRO_HAVE_LINUX_SOUNDCARD_H)
check_include_files(machine/soundcard.h ALLEGRO_HAVE_MACHINE_SOUNDCARD_H)
check_include_files(soundcard.h ALLEGRO_HAVE_SOUNDCARD_H)
check_include_files(stdint.h ALLEGRO_HAVE_STDINT_H)
check_include_files(sys/io.h ALLEGRO_HAVE_SYS_IO_H)
check_include_files(sys/stat.h ALLEGRO_HAVE_SYS_STAT_H)
check_include_files(sys/time.h ALLEGRO_HAVE_SYS_TIME_H)
@ -148,6 +147,8 @@ if(UNIX)
# XXX size_t
endif(UNIX)
check_include_files(stdint.h ALLEGRO_HAVE_STDINT_H)
#-----------------------------------------------------------------------------#
#
# Compiler and platform setup

View File

@ -77,9 +77,13 @@
#define INLINE __inline
#if _MSC_VER < 1700
#define LONG_LONG __int64
#define int64_t signed __int64
#define uint64_t unsigned __int64
#else
#define LONG_LONG long long
#endif
#define AL_CONST const

View File

@ -12,6 +12,8 @@
#cmakedefine ALLEGRO_UNIX
#cmakedefine ALLEGRO_WATCOM
#cmakedefine ALLEGRO_HAVE_STDINT_H
/* These are always defined now. */
#define ALLEGRO_NO_ASM
#define ALLEGRO_USE_C

View File

@ -21,7 +21,6 @@
#cmakedefine ALLEGRO_HAVE_LINUX_SOUNDCARD_H
#cmakedefine ALLEGRO_HAVE_MACHINE_SOUNDCARD_H
#cmakedefine ALLEGRO_HAVE_SOUNDCARD_H
#cmakedefine ALLEGRO_HAVE_STDINT_H
#cmakedefine ALLEGRO_HAVE_SV_PROCFS_H
#cmakedefine ALLEGRO_HAVE_SYS_IO_H
#cmakedefine ALLEGRO_HAVE_SYS_SOUNDCARD_H