Skip to content

Commit

Permalink
Bug 1477048 - part 1 - remove '86' in CONFIG['OS_TEST'] stanzas fro…
Browse files Browse the repository at this point in the history
…m moz.build files; r=gps

The current code is somewhat non-obvious to a first-time reader, and
OS_TEST is a bizarre thing anyway, since it's actually the name of the
CPU we're running on.  We'd do well to minimize the use of OS_TEST.

Note that the complete nuking of the xptcall/md/unix/moz.build lines are
because we don't support OS X/x86 anymore.
  • Loading branch information
froydnj committed Jul 24, 2018
1 parent 32d63fd commit 5158597
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 10 deletions.
2 changes: 1 addition & 1 deletion gfx/cairo/libpixman/src/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ use_sse2 = False
use_vmx = False
use_arm_simd_gcc = False
use_arm_neon_gcc = False
if '86' in CONFIG['OS_TEST']:
if CONFIG['INTEL_ARCHITECTURE']:
use_sse2 = True
if '64' not in CONFIG['OS_TEST']:
if CONFIG['CC_TYPE'] in ('msvc', 'clang-cl'):
Expand Down
2 changes: 1 addition & 1 deletion gfx/qcms/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ if CONFIG['CC_TYPE'] in ('clang', 'gcc'):
use_sse1 = False
use_sse2 = False
use_altivec = False
if '86' in CONFIG['OS_TEST']:
if CONFIG['INTEL_ARCHITECTURE']:
use_sse2 = True
if CONFIG['CC_TYPE'] in ('msvc', 'clang-cl'):
if CONFIG['OS_ARCH'] != 'WINNT' or CONFIG['OS_TEST'] != 'x86_64':
Expand Down
2 changes: 1 addition & 1 deletion ipc/chromium/atomics/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Library('chromium_atomics')

# This test is copied from ../moz.build for atomicops_internals_mutex.cc
ost = CONFIG['OS_TEST']
if '86' not in ost and 'arm' not in ost and 'aarch64' != ost and 'mips' not in ost and 'powerpc' not in ost:
if not CONFIG['INTEL_ARCHITECTURE'] and 'arm' not in ost and 'aarch64' != ost and 'mips' not in ost and 'powerpc' not in ost:
SOURCES += [
'../src/base/atomicops_internals_mutex.cc',
'../src/base/lock_impl_posix.cc',
Expand Down
2 changes: 1 addition & 1 deletion ipc/chromium/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ if os_solaris:
]

ost = CONFIG['OS_TEST']
if '86' not in ost and 'arm' not in ost and 'aarch64' != ost and 'mips' not in ost and 'powerpc' not in ost:
if not CONFIG['INTEL_ARCHITECTURE'] and 'arm' not in ost and 'aarch64' != ost and 'mips' not in ost and 'powerpc' not in ost:
SOURCES += [
'src/base/atomicops_internals_mutex.cc',
]
Expand Down
2 changes: 1 addition & 1 deletion media/libtheora/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ UNIFIED_SOURCES += [

LOCAL_INCLUDES += ['include']

if '86' in CONFIG['OS_TEST']:
if CONFIG['INTEL_ARCHITECTURE']:
if CONFIG['OS_ARCH'] != 'SunOS':
if CONFIG['CC_TYPE'] == 'clang-cl':
# clang-cl can't handle libtheora's inline asm.
Expand Down
2 changes: 1 addition & 1 deletion modules/xz-embedded/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ if CONFIG['TARGET_CPU'].startswith('arm'):
DEFINES['XZ_DEC_ARMTHUMB'] = 1
else:
DEFINES['XZ_DEC_ARM'] = 1
elif '86' in CONFIG['TARGET_CPU']:
elif CONFIG['INTEL_ARCHITECTURE']:
# Accept x86, x86_64, i386, i686, etc.
DEFINES['XZ_DEC_X86'] = 1

Expand Down
6 changes: 2 additions & 4 deletions xpcom/reflect/xptcall/md/unix/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ if CONFIG['OS_ARCH'] == 'Darwin':
SOURCES += [
'xptcinvoke_asm_x86_64_unix.S',
]
if '86' in CONFIG['OS_TEST'] and CONFIG['OS_TEST'] != 'x86_64':
DEFINES['MOZ_NEED_LEADING_UNDERSCORE'] = True

if CONFIG['OS_ARCH'] == 'GNU':
if CONFIG['CPU_ARCH'] == 'x86':
Expand Down Expand Up @@ -51,7 +49,7 @@ if CONFIG['OS_ARCH'] in ('Linux', 'FreeBSD'):
'xptcstubs_ipf64.cpp'
]

if CONFIG['OS_ARCH'] == 'SunOS' and '86' in CONFIG['OS_TEST']:
if CONFIG['OS_ARCH'] == 'SunOS' and CONFIG['INTEL_ARCHITECTURE']:
if CONFIG['OS_TEST'] == 'x86_64':
if CONFIG['CC_TYPE'] in ('clang', 'gcc'):
SOURCES += [
Expand Down Expand Up @@ -273,7 +271,7 @@ if CONFIG['OS_ARCH'] in ('OpenBSD', 'FreeBSD', 'Linux') and CONFIG['OS_TEST'] ==
'xptcstubs_sparc64_openbsd.cpp',
]

if CONFIG['OS_ARCH'] == 'SunOS' and '86' not in CONFIG['OS_TEST']:
if CONFIG['OS_ARCH'] == 'SunOS' and not CONFIG['INTEL_ARCHITECTURE']:
if CONFIG['HAVE_64BIT_BUILD']:
ASFLAGS += ['-xarch=v9']
SOURCES += [
Expand Down

0 comments on commit 5158597

Please sign in to comment.