diff options
author | Robin Dunn <robin@alldunn.com> | 2013-07-20 17:15:38 -0700 |
---|---|---|
committer | Robin Dunn <robin@alldunn.com> | 2013-07-20 17:15:38 -0700 |
commit | f981508fe80668efc61654f2692779dfcdc3933c (patch) | |
tree | bc167b917ed1ed9e5115d75258c4051b62fb7cd8 /setup.py | |
parent | 932e272c0d60c1be3b08b2f9ef709da24e2f75c3 (diff) |
Add --osx-arch option so the desired build architecture can be specified
Diffstat (limited to 'setup.py')
-rw-r--r-- | setup.py | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -106,6 +106,7 @@ OPTION_NOEXAMPLES = has_option("no-examples") # don't include pyside-example OPTION_JOBS = option_value('jobs') # number of parallel build jobs OPTION_JOM = has_option('jom') # use jom instead of nmake with msvc OPTION_BUILDTESTS = has_option("build-tests") +OPTION_OSXARCH = option_value("osx-arch") if OPTION_QMAKE is None: OPTION_QMAKE = find_executable("qmake") @@ -589,9 +590,9 @@ class pyside_build(_build): # https://groups.google.com/forum/#!msg/pyside/xciZZ4Hm2j8/CUmqfJptOwoJ cmake_cmd.append('-DALTERNATIVE_QT_INCLUDE_DIR=/Library/Frameworks') - # also tell cmake which architecture to use TODO: make this optional? Allow both? - arch = 'i386' if platform.architecture()[0] == '32' else 'x86_64' - cmake_cmd.append("-DCMAKE_OSX_ARCHITECTURES:STRING={}".format(arch)) + if OPTION_OSXARCH: + # also tell cmake which architecture to use + cmake_cmd.append("-DCMAKE_OSX_ARCHITECTURES:STRING={}".format(OPTION_OSXARCH)) log.info("Configuring module %s (%s)..." % (extension, module_src_dir)) if run_process(cmake_cmd, log) != 0: |