summaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2013-07-16 19:09:54 +0200
committerSergei Golubchik <sergii@pisem.net>2013-07-16 19:09:54 +0200
commit005c7e54214546584c8dc67a746e215f8dbe4b58 (patch)
treedea50cd7b32808413e058d43d20cf230d1cc7477 /cmake
parentb9f220b45afaae9b61af29129a8c8ec5f9a7759b (diff)
parent4f5c10e6b565bc2761b9d083e25c6a36141552a0 (diff)
downloadmariadb-git-005c7e54214546584c8dc67a746e215f8dbe4b58.tar.gz
mysql-5.5.32 merge
Diffstat (limited to 'cmake')
-rw-r--r--cmake/package_name.cmake25
1 files changed, 14 insertions, 11 deletions
diff --git a/cmake/package_name.cmake b/cmake/package_name.cmake
index 2d0b689dc7a..4ba8fc18e3f 100644
--- a/cmake/package_name.cmake
+++ b/cmake/package_name.cmake
@@ -1,4 +1,4 @@
-# Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -83,19 +83,22 @@ IF(NOT VERSION)
MATH(EXPR VER "${VER} -4")
SET(DEFAULT_PLATFORM "osx10.${VER}")
ENDIF()
- LIST(LENGTH CMAKE_OSX_ARCHITECTURES LEN)
- IF(LEN GREATER 1)
- SET(DEFAULT_MACHINE "universal")
+
+ IF(CMAKE_OSX_ARCHITECTURES)
+ LIST(LENGTH CMAKE_OSX_ARCHITECTURES LEN)
+ IF(LEN GREATER 1)
+ SET(DEFAULT_MACHINE "universal")
+ ELSE()
+ SET(DEFAULT_MACHINE "${CMAKE_OSX_ARCHITECTURES}")
+ ENDIF()
ELSE()
- SET(DEFAULT_MACHINE "${CMAKE_OSX_ARCHITECTURES}")
- IF(NOT DEFAULT_MACHINE)
- IF(CMAKE_SIZEOF_VOIPD EQUAL 4)
- SET(DEFAULT_MACHINE "i386")
- ELSE()
- SET(DEFAULT_MACHINE "x86_64")
- ENDIF()
+ IF(64BIT)
+ SET(DEFAULT_MACHINE "x86_64")
+ ELSE()
+ SET(DEFAULT_MACHINE "i386")
ENDIF()
ENDIF()
+
IF(DEFAULT_MACHINE MATCHES "i386")
SET(DEFAULT_MACHINE "x86")
ENDIF()