Building a package is disk intensive and running make -j8 on a machine
with a spinner can actually be slower than make. NPROC=1 make-deb.sh
overrides the default value of make -jX.
Signed-off-by: Loic Dachary <ldachary@redhat.com>
# b) do not sign the packages
# c) use half of the available processors
#
-PATH=/usr/lib/ccache:$PATH dpkg-buildpackage -j$(($(nproc) / 2)) -uc -us
+: ${NPROC:=$(($(nproc) / 2))}
+if test $NPROC -gt 1 ; then
+ j=-j${NPROC}
+fi
+PATH=/usr/lib/ccache:$PATH dpkg-buildpackage $j -uc -us
cd ../..
mkdir -p $codename/conf
cat > $codename/conf/distributions <<EOF