Merge pull request #990 from joankaradimov/parallel-build

Build the webkit server executable in parallel
This commit is contained in:
Thomas Walpole 2017-11-07 05:40:27 -08:00 committed by GitHub
commit 0fa9b513fa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -1,3 +1,4 @@
require 'etc'
require "fileutils"
require "rbconfig"
require "shellwords"
@ -90,7 +91,8 @@ module CapybaraWebkitBuilder
end
def make(target = "")
env_hide("CDPATH") { sh("#{make_bin} #{target}") }
job_count = Etc.respond_to?(:nprocessors) ? Etc.nprocessors : 1
env_hide('CDPATH') { sh("#{make_bin} #{target} --jobs=#{job_count}") }
end
def env_hide(name)