Parallel bootstrap for cmake.

This commit is contained in:
Todd Gamblin 2013-02-21 20:05:11 -08:00
parent bd59689fdc
commit 5899308ad3
2 changed files with 5 additions and 1 deletions

View file

@ -131,6 +131,9 @@ def add_commands_to_module(self):
self.module.make = MakeExecutable('make', self.parallel) self.module.make = MakeExecutable('make', self.parallel)
self.module.gmake = MakeExecutable('gmake', self.parallel) self.module.gmake = MakeExecutable('gmake', self.parallel)
# number of jobs spack prefers to build with.
self.module.make_jobs = multiprocessing.cpu_count()
# Find the configure script in the archive path # Find the configure script in the archive path
# Don't use which for this; we want to find it in the current dir. # Don't use which for this; we want to find it in the current dir.
self.module.configure = Executable('./configure') self.module.configure = Executable('./configure')

View file

@ -6,6 +6,7 @@ class Cmake(Package):
md5 = '097278785da7182ec0aea8769d06860c' md5 = '097278785da7182ec0aea8769d06860c'
def install(self, prefix): def install(self, prefix):
configure('--prefix=%s' % prefix) configure('--prefix=%s' % prefix,
'--parallel=%s' % make_jobs)
make() make()
make('install') make('install')