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

make -j in Debian packages


It has come to my attention that the gem package is currently built
using 'make -j 4', to have four compiler processes running at the same
time. This is a bit troublesome for the poor m68k buildd, which is now
suffering under High Load And Constant Swapping (HLACS).

I was going to file a flaming bug of severity 'serious', quoting the
relevant paragraph from Policy which forbids such behaviour, except it's
not there. Well, at least I can't find it...

So, my question is whether people think this sort of behaviour for a
package's debian/rules file is acceptable. Since most packages currently
do not do this, some of our infrastructure (in casu, buildd machines)
assume this is not being done. Doing it anyway then might upset those
machines -- not just on m68k; when there was talk of a 6-way SPARC
buildd machine being set up, I understand that the plan there was to run
multiple instances of the buildd software on that machine, rather than
having parallel builds run[1]. Having five or six build processes all do
'make -j 4' might grind even the most powerful of machines to a halt.

OTOH, I understand that maintainers with machines containing two
dual-core processors would prefer compiling their 300M worth of C++
files with the use of more than one of their processors. So there's a
bit of a dilemma here.

Personally, I understand the issue. In fact, in my upcoming version of
belpic, I have some code in debian/rules which checks whether the
hostname of the machine happens to be 'rock.grep.be' and if so, compiles
the build with '-j3', since rock is in fact an SMP system. However, this
type of approach is a bit brute-force, and not at all elegant.

In light of that, I'm thinking that it might be interesting if a rules
file were to check for the presence of a variable called
DEB_PARALLEL_MAX or so and, if set, use that as the value to the '-j'
option to make, but that it not specify any -j option (or similar) if
the variable is not set.


[1] I don't know whether it was eventually set up, and if so, indeed in
    this fashion, but this is besides the point.

Fun will now commence
  -- Seven Of Nine, "Ashes to Ashes", stardate 53679.4

Attachment: signature.asc
Description: Digital signature

Reply to: