+2012-02-22 Gabor Rapcsanyi <rgabor@webkit.org>
+
+ build-webkit should use environment variable at number of CPU
+ detection on all platform
+ https://bugs.webkit.org/show_bug.cgi?id=79227
+
+ Reviewed by Martin Robinson.
+
+ * Scripts/webkitdirs.pm:
+ (determineNumberOfCPUs):
+
2012-02-22 Mihnea Ovidenie <mihnea@adobe.com>
[Qt] REGRESSION(r108108): It made 3 fast/repaint tests fail
sub determineNumberOfCPUs
{
return if defined $numberOfCPUs;
- if (isLinux()) {
+ if (defined($ENV{NUMBER_OF_PROCESSORS})) {
+ $numberOfCPUs = $ENV{NUMBER_OF_PROCESSORS};
+ } elsif (isLinux()) {
# First try the nproc utility, if it exists. If we get no
# results fall back to just interpretting /proc directly.
chomp($numberOfCPUs = `nproc 2> /dev/null`);
$numberOfCPUs = (grep /processor/, `cat /proc/cpuinfo`);
}
} elsif (isWindows() || isCygwin()) {
- if (defined($ENV{NUMBER_OF_PROCESSORS})) {
- $numberOfCPUs = $ENV{NUMBER_OF_PROCESSORS};
- } else {
- # Assumes cygwin
- $numberOfCPUs = `ls /proc/registry/HKEY_LOCAL_MACHINE/HARDWARE/DESCRIPTION/System/CentralProcessor | wc -w`;
- }
+ # Assumes cygwin
+ $numberOfCPUs = `ls /proc/registry/HKEY_LOCAL_MACHINE/HARDWARE/DESCRIPTION/System/CentralProcessor | wc -w`;
} elsif (isDarwin()) {
chomp($numberOfCPUs = `sysctl -n hw.ncpu`);
}