summaryrefslogtreecommitdiff
path: root/indra/cmake/00-Common.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'indra/cmake/00-Common.cmake')
-rw-r--r--indra/cmake/00-Common.cmake8
1 files changed, 8 insertions, 0 deletions
diff --git a/indra/cmake/00-Common.cmake b/indra/cmake/00-Common.cmake
index 42f43f9d4e..ad7529ea0a 100644
--- a/indra/cmake/00-Common.cmake
+++ b/indra/cmake/00-Common.cmake
@@ -202,6 +202,14 @@ if (LINUX OR DARWIN)
set(CMAKE_C_FLAGS "${GCC_WARNINGS} ${CMAKE_C_FLAGS}")
set(CMAKE_CXX_FLAGS "${GCC_CXX_WARNINGS} ${CMAKE_CXX_FLAGS}")
+
+ if (WORD_SIZE EQUAL 32)
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m32")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m32")
+ elseif (WORD_SIZE EQUAL 64)
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m64")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m64")
+ endif (WORD_SIZE EQUAL 32)
endif (LINUX OR DARWIN)