Bug 1305677 - Remove requirement of libffi on aarch64 as default. r=chmanchester

To support android/aarch64, I want to remove the requirement of system's libffi.

MozReview-Commit-ID: Lc3POx09Cks

--HG--
extra : rebase_source : 384852e7b9e61d0d7a950159535e3ddc8457e889
This commit is contained in:
Makoto Kato 2016-09-27 19:16:03 +09:00
parent 347d2f4b09
commit d78efa6ffb
2 changed files with 7 additions and 2 deletions

View File

@ -7,7 +7,7 @@
@depends(target)
def force_system_ffi(target):
# Pre-emptively move to system ffi for non-tier one platforms.
if target.cpu not in ('x86', 'x86_64', 'arm'):
if target.cpu not in ('x86', 'x86_64', 'arm', 'aarch64'):
return True
imply_option('--with-system-ffi', force_system_ffi, "target")
@ -28,7 +28,7 @@ add_old_configure_assignment('MOZ_SYSTEM_FFI', system_ffi)
# Target selection, based on ffi/configure.ac.
@depends_when(target, when=building_ffi)
def ffi_target(target):
if target.cpu not in ('x86', 'x86_64', 'arm'):
if target.cpu not in ('x86', 'x86_64', 'arm', 'aarch64'):
die('Building libffi from the tree is not supported on this platform. '
'Use --with-system-ffi instead.')
@ -44,6 +44,9 @@ def ffi_target(target):
elif target.cpu == 'arm':
target_dir = 'arm'
target_name = 'ARM'
elif target.cpu == 'aarch64':
target_dir = 'aarch64'
target_name = 'AARCH64'
else:
target_dir = 'x86'
target_name = target.cpu.upper()

View File

@ -78,6 +78,8 @@ else:
ffi_srcs = ('sysv.S', 'ffi.c')
if CONFIG['CLANG_CXX']:
ASFLAGS += ['-no-integrated-as']
elif CONFIG['FFI_TARGET'] == 'AARCH64':
ffi_srcs = ('sysv.S', 'ffi.c')
elif CONFIG['FFI_TARGET'] == 'X86':
ffi_srcs = ('ffi.c', 'sysv.S', 'win32.S')
elif CONFIG['FFI_TARGET'] == 'X86_64':