# (i.e. before the tests would pass on the main NaCl buildbots/trybots).
# If you are adding a test that depends on a toolchain change, you can
# increment this version number manually.
-FEATURE_VERSION = 5
+FEATURE_VERSION = 7
# For backward compatibility, these key names match the directory names
# previously used with gclient
'nacl-newlib': 'nacl-newlib.git',
'llvm-test-suite': 'pnacl-llvm-testsuite.git',
'compiler-rt': 'pnacl-compiler-rt.git',
+ 'subzero': 'pnacl-subzero.git',
}
GIT_BASE_URL = 'https://chromium.googlesource.com/native_client/'
GIT_PUSH_URL = 'ssh://gerrit.chromium.org/native_client/'
GIT_DEPS_FILE = os.path.join(NACL_DIR, 'pnacl', 'COMPONENT_REVISIONS')
+ALT_GIT_BASE_URL = 'https://chromium.googlesource.com/a/native_client/'
+
KNOWN_MIRRORS = [('http://git.chromium.org/native_client/', GIT_BASE_URL)]
PUSH_MIRRORS = [('http://git.chromium.org/native_client/', GIT_PUSH_URL),
+ (ALT_GIT_BASE_URL, GIT_PUSH_URL),
(GIT_BASE_URL, GIT_PUSH_URL)]
# TODO(dschuff): Some of this mingw logic duplicates stuff in command.py
# that we don't want to have to distribute alongside our binaries.
# So just disable it, and compiler messages will always be in US English.
configure_args.append('--disable-nls')
- configure_args.extend(['LDFLAGS=-L%(abs_libdl)s',
+ configure_args.extend(['LDFLAGS=-L%(abs_libdl)s -ldl',
'CFLAGS=-isystem %(abs_libdl)s',
'CXXFLAGS=-isystem %(abs_libdl)s'])
return configure_args
return cmake_flags
+def LLVMConfigureAssertionsFlags(options):
+ if options.enable_llvm_assertions:
+ return []
+ else:
+ return ['--disable-debug', '--disable-assertions']
+
+
def MakeCommand(host):
make_command = ['make']
if not pynacl.platform.IsWindows() or pynacl.platform.IsCygWin():
'output_dirname': 'llvm',
'commands': GetGitSyncCmds('llvm'),
},
+ 'subzero_src': {
+ 'type': 'source',
+ 'output_dirname': 'subzero',
+ 'commands': GetGitSyncCmds('subzero'),
+ },
}
return sources
'inputs' : { 'src' : os.path.join(NACL_DIR, '..', 'third_party',
'dlfcn-win32') },
'commands': [
- command.CopyTree('%(src)s', '.'),
+ command.CopyTree('%(src)s', 'src'),
command.Command(['i686-w64-mingw32-gcc',
- '-o', 'dlfcn.o', '-c', 'dlfcn.c',
+ '-o', 'dlfcn.o', '-c',
+ os.path.join('src', 'dlfcn.c'),
'-Wall', '-O3', '-fomit-frame-pointer']),
command.Command([ar, 'cru',
'libdl.a', 'dlfcn.o']),
command.Copy('libdl.a',
os.path.join('%(output)s', 'libdl.a')),
- command.Copy('dlfcn.h',
+ command.Copy(os.path.join('src', 'dlfcn.h'),
os.path.join('%(output)s', 'dlfcn.h')),
],
},
}
llvm_autoconf = {
H('llvm'): {
- 'dependencies': ['clang_src', 'llvm_src', 'binutils_pnacl_src'],
+ 'dependencies': ['clang_src', 'llvm_src', 'binutils_pnacl_src',
+ 'subzero_src'],
'type': 'build',
'output_subdir': HostSubdir(host),
'commands': [
'sh',
'%(llvm_src)s/configure'] +
ConfigureHostArchFlags(host) +
+ LLVMConfigureAssertionsFlags(options) +
['--prefix=/',
'--enable-shared',
'--disable-zlib',
command.Command(MakeCommand(host) + [
'VERBOSE=1',
'NACL_SANDBOX=0',
+ 'SUBZERO_SRC_ROOT=%(abs_subzero_src)s',
'all']),
command.Command(MAKE_DESTDIR_CMD + ['install']),
command.Remove(*[os.path.join('%(output)s', 'lib', f) for f in
# Host components
host_packages = {}
- for os_name, arch in (('cygwin', 'x86-32'),
+ for os_name, arch in (('win', 'x86-32'),
('mac', 'x86-64'),
('linux', 'x86-32'),
('linux', 'x86-64')):
parser.add_argument('--build-64bit-host', action='store_true',
dest='build_64bit_host', default=False,
help='Build 64-bit Linux host binaries in addition to 32')
+ parser.add_argument('--disable-llvm-assertions', action='store_false',
+ dest='enable_llvm_assertions', default=True)
parser.add_argument('--cmake', action='store_true', default=False,
help="Use LLVM's cmake ninja build instead of autoconf")
parser.add_argument('--clang', action='store_true', default=False,