[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#760519: qtwebkit: Uses unbound parallelism on unknown platforms



Source: qtwebkit
Version: 2.3.2.dfsg-2
Severity: important
User: debian-hurd@lists.debian.org
Usertags: hurd
Tags: patch

Hello,

qtwebkit currently puts hurd buildds on their knees because its
build systems uses "make -j", i.e. without specifying the requested
parallelism level, which means unbound parallelism, which when building
c++ code basically means filling dozens of gigabytes of memory.

This apparently comes from ./Tools/Scripts/webkitdirs.pm which for
unknown platforms makes numberOfCPUs() return an empty string, which
thus ends up with "make -j".

The attached patch makes qtwebkit default to 1 instead of defaulting to
unbound parallelism.

Perhaps upstream will also prefer to try to use the portable way,
sysconf(_SC_NPROCESSORS_ONLN) (I don't know the perl equivalent).

Samuel

-- System Information:
Debian Release: jessie/sid
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'unstable'), (500, 'stable'), (500, 'oldstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.16.0 (SMP w/8 CPU cores)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

-- 
Samuel
AUTHOR
     FvwmM4 is the result of a random  bit  mutation  on  a  hard
     disk,  presumably  a  result  of  a  cosmic-ray or some such
     thing.
(extrait de la page de man de FvwmM4)
--- ./Tools/Scripts/webkitdirs.pm.original	2014-09-05 00:09:09.000000000 +0200
+++ ./Tools/Scripts/webkitdirs.pm	2014-09-05 00:10:34.000000000 +0200
@@ -362,6 +362,10 @@
     } elsif (isDarwin() || isFreeBSD()) {
         chomp($numberOfCPUs = `sysctl -n hw.ncpu`);
     }
+    if (!defined($numberOfCPUs) or $numberOfCPUs eq "")
+    {
+      $numberOfCPUs = "1";
+    }
 }
 
 sub jscPath($)

Reply to: