Commit 3e98d9ef authored by Andoni Morales Alastruey's avatar Andoni Morales Alastruey Committed by Matthew Waters
Browse files

macos: add support for targetting ARM64

Part-of: <!661>
parent 459e09c9
......@@ -15,14 +15,25 @@ allow_system_libs=False
# Enable introspection by default
variants.override('gi')
if arch == Architecture.X86_64:
build = 'x86_64-apple-darwin12'
elif arch == Architecture.X86:
build = 'i386-apple-darwin12'
elif arch == Architecture.ARM64:
build = 'aarch64-apple-darwin12'
elif arch == Architecture.UNIVERSAL:
build = 'universal-apple-darwin12'
if target_arch == Architecture.X86_64:
build='x86_64-apple-darwin12'
host = 'x86_64-apple-darwin12'
elif target_arch == Architecture.X86:
build='i386-apple-darwin12'
host = 'i386-apple-darwin12'
elif target_arch == Architecture.ARM64:
host = 'aarch64-apple-darwin12'
elif target_arch == Architecture.UNIVERSAL:
build='universal-apple-darwin12'
host = 'universal-apple-darwin12'
# By default we ask for the 'latest' SDK. This can be overriden by
# By default we ask for the 'latest' SDK. This can be overriden by
# configure using 'osx_target_sdk_version' (e.g. set to '10.10')
sdk_requested_version = '' # Empty == latest
if osx_target_sdk_version is not None:
......@@ -55,6 +66,9 @@ elif target_arch == Architecture.X86:
arch_cflags += ' -arch i386 -m32'
arch_ldflags += ' -arch i386 -m32 -Wl,-arch,i386'
env['VERSIONER_PYTHON_PREFER_32_BIT'] = 'yes'
elif target_arch == Architecture.ARM64:
arch_cflags += ' -arch arm64 -m64'
arch_ldflags += ' -arch arm64 -m64 -Wl,-arch,arm64'
arch_cflags += ' -Wno-error=format-nonliteral '
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment