Source: u-boot Severity: wishlist Tags: patch This tool automatically sets -jN according to DEB_BUILD_OPTIONS.
>From 4395f754d464dae94d19794bfbac50d04bac5575 Mon Sep 17 00:00:00 2001 From: Nicolas Boulenguez <nico...@debian.org> Date: Sat, 9 Jan 2021 19:22:22 +0100 Subject: Prefer dh_auto_build to explicit recursive $(MAKE)
This tool automatically sets -jN according to DEB_BUILD_OPTIONS. diff --git a/debian/rules b/debian/rules index 19a61e3cb7..a3d5971126 100755 --- a/debian/rules +++ b/debian/rules @@ -9,11 +9,6 @@ export CROSS_COMPILE ?= $(DEB_HOST_GNU_TYPE)- cross_build_tools ?= y endif -# support parallel build using DEB_BUILD_OPTIONS=parallel=N -ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) - DEB_UBOOT_FLAGS += -j$(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) -endif - # Enable verbose build by default, disable when terse is specified. ifneq (,$(filter terse,$(DEB_BUILD_OPTIONS))) VERBOSE=0 @@ -98,9 +93,9 @@ build-targets: configs/novena-rawsd_defconfig configs/am335x_boneblack_defconfig *) unset SCP ;;\ esac;\ mkdir -p $$builddir; \ - $(MAKE) V=$(VERBOSE) O=$$builddir $${platform}_defconfig; \ + dh_auto_build -- V=$(VERBOSE) O=$$builddir $${platform}_defconfig; \ sed -i -e 's,CONFIG_FIT_SIGNATURE=y,# CONFIG_FIT_SIGNATURE is not set,g' $$builddir/.config; \ - $(MAKE) V=$(VERBOSE) $(DEB_UBOOT_FLAGS) O=$$builddir $${maketargets}; \ + dh_auto_build -- V=$(VERBOSE) O=$$builddir $${maketargets}; \ case "$$targets" in \ *uboot.elf*) \ install -m 644 $$builddir/u-boot $$builddir/uboot.elf; \ @@ -121,10 +116,10 @@ build-targets: configs/novena-rawsd_defconfig configs/am335x_boneblack_defconfig done build-tools: - $(MAKE) V=$(VERBOSE) O=$(TOOLSDIR) CROSS_COMPILE=$(CROSS_COMPILE) tools-only_defconfig + dh_auto_build -- V=$(VERBOSE) O=$(TOOLSDIR) CROSS_COMPILE=$(CROSS_COMPILE) tools-only_defconfig cp $(TOOLSDIR)/.config $(TOOLSDIR)/config # board-independent tools - $(MAKE) V=$(VERBOSE) O=$(TOOLSDIR) $(DEB_UBOOT_FLAGS) \ + dh_auto_build -- V=$(VERBOSE) O=$(TOOLSDIR) \ CROSS_COMPILE=$(CROSS_COMPILE) \ CROSS_BUILD_TOOLS=$(cross_build_tools) \ NO_SDL=1 \