From 9fbc1cbfc7917f26a4a48bcef844478dea8ebafd Mon Sep 17 00:00:00 2001 From: rude Date: Sun, 29 Sep 2013 16:20:57 +0200 Subject: [PATCH] Add MEGA_ARCH. --- CMakeLists.txt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8c74bea1..63ecba97 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,6 +7,14 @@ cmake_minimum_required(VERSION 2.8) project(megasource) +if(CMAKE_SIZEOF_VOID_P EQUAL 8) + set(MEGA_X64 TRUE) + set(MEGA_ARCH x64) +else() + set(MEGA_X86 TRUE) + set(MEGA_ARCH x86) +endif() + if(MSVC) set(CMAKE_SUPPRESS_REGENERATION TRUE) endif()