diff options
Diffstat (limited to 'librewolf/debian/dh')
-rwxr-xr-x | librewolf/debian/dh | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/librewolf/debian/dh b/librewolf/debian/dh new file mode 100755 index 0000000..5b43536 --- /dev/null +++ b/librewolf/debian/dh @@ -0,0 +1,25 @@ +#!/bin/sh + +# Wrapper around dh to enable parallelism in debian/rules if not already +# enabled. + +case "$MAKEFLAGS" in +*-j*) + # Already enabled, do nothing. + ;; +*) + parallel= + for opt in "$DEB_BUILD_OPTIONS"; do + case "$opt" in + parallel=*) + parallel=${opt#parallel=} + ;; + esac + done + if [ -n "$parallel" ]; then + export MAKEFLAGS="-j$parallel${MAKEFLAGS:+ $MAKEFLAGS}" + fi + ;; +esac + +exec dh "$@" |