Source: u-boot Version: 2014.10~rc2+dfsg1-2~exp1 Severity: minor Tags: patch
This is a fairly minor annoyance but it's easy to fix, e.g. the attached patch. Cheers, Ian. -- System Information: Debian Release: jessie/sid APT prefers testing APT policy: (990, 'testing'), (500, 'unstable'), (500, 'stable') Architecture: amd64 (x86_64) Foreign Architectures: i386 armhf armel Kernel: Linux 3.14-2-amd64 (SMP w/4 CPU cores) Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash -- no debconf information
>From 91b0ef3db5f75c6b08451e92d7487feb5dab5361 Mon Sep 17 00:00:00 2001 From: Ian Campbell <i...@debian.org> Date: Sat, 27 Sep 2014 09:49:43 +0100 Subject: [PATCH] Build tools out-of-tree too so as not to dirty the source used for the actual platforms. This is a fairly minor annoyance when doing incremental builds for dev. With this it is no longer required to remove include/config/auto.conf on clean. --- debian/changelog | 7 +++++++ debian/rules | 25 +++++++++++++++---------- debian/u-boot-tools.install | 11 +++++++---- 3 files changed, 29 insertions(+), 14 deletions(-) diff --git a/debian/changelog b/debian/changelog index 2d14e23..9252c5b 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +u-boot (2014.10~rc2+dfsg1-2~exp2) UNRELEASED; urgency=medium + + * Build tools out-of-tree too so as not to dirty the source used for the + actual platforms. + + -- Ian Campbell <i...@debian.org> Sat, 27 Sep 2014 09:48:00 +0100 + u-boot (2014.10~rc2+dfsg1-2~exp1) experimental; urgency=medium * Split u-boot package into u-boot-imx, u-boot-omap and u-boot-sunxi diff --git a/debian/rules b/debian/rules index 49d2cdb..1dd2bd4 100755 --- a/debian/rules +++ b/debian/rules @@ -22,6 +22,7 @@ LDFLAGS := $(patsubst -Wl$(comma)%,%,$(LDFLAGS)) %: dh $@ --parallel +override_dh_auto_build: TOOLSDIR := `pwd`/debian/build/tools override_dh_auto_build: set -e; sed -n 's/^$(DEB_HOST_ARCH)[[:space:]]\+//p' debian/targets \ | while read subarch platform targets; do \ @@ -38,23 +39,27 @@ override_dh_auto_build: done # Avoid requirement for .config - mkdir -p include/config - touch include/config/auto.conf + mkdir -p $(TOOLSDIR)/include/config + touch $(TOOLSDIR)/include/config/auto.conf # Load dummy config - make sandbox_defconfig + make O=$(TOOLSDIR) sandbox_defconfig # board-independent tools - $(MAKE) $(DEB_UBOOT_FLAGS) HOSTCC=$(CROSS_COMPILE)gcc HOSTSTRIP=$(CROSS_COMPILE)strip \ + $(MAKE) O=$(TOOLSDIR) $(DEB_UBOOT_FLAGS) \ + HOSTCC=$(CROSS_COMPILE)gcc \ + HOSTSTRIP=$(CROSS_COMPILE)strip \ tools-only - $(MAKE) $(DEB_UBOOT_FLAGS) HOSTCC=$(CROSS_COMPILE)gcc HOSTSTRIP=$(CROSS_COMPILE)strip env - $(CROSS_COMPILE)strip --remove-section=.comment tools/env/fw_printenv - $(CROSS_COMPILE)strip --remove-section=.comment tools/mkimage - $(CROSS_COMPILE)strip --remove-section=.comment tools/kwboot - $(CROSS_COMPILE)strip --remove-section=.comment tools/mksunxiboot + $(MAKE) O=$(TOOLSDIR) $(DEB_UBOOT_FLAGS) \ + HOSTCC=$(CROSS_COMPILE)gcc \ + HOSTSTRIP=$(CROSS_COMPILE)strip \ + env + $(CROSS_COMPILE)strip --remove-section=.comment $(TOOLSDIR)/tools/env/fw_printenv + $(CROSS_COMPILE)strip --remove-section=.comment $(TOOLSDIR)/tools/mkimage + $(CROSS_COMPILE)strip --remove-section=.comment $(TOOLSDIR)/tools/kwboot + $(CROSS_COMPILE)strip --remove-section=.comment $(TOOLSDIR)/tools/mksunxiboot override_dh_auto_test: # skip tests. override_dh_clean: rm -rf debian/build/ - rm -f include/config/auto.conf dh_clean diff --git a/debian/u-boot-tools.install b/debian/u-boot-tools.install index 11a34c3..5cd1662 100755 --- a/debian/u-boot-tools.install +++ b/debian/u-boot-tools.install @@ -1,8 +1,11 @@ #!/bin/sh -echo tools/mkimage /usr/bin/ -echo tools/mksunxiboot /usr/bin/ -echo tools/kwboot /usr/bin/ -echo tools/env/fw_printenv /usr/bin/ + +builddir=debian/build/tools + +echo ${builddir}/tools/mkimage /usr/bin/ +echo ${builddir}/tools/mksunxiboot /usr/bin/ +echo ${builddir}/tools/kwboot /usr/bin/ +echo ${builddir}/tools/env/fw_printenv /usr/bin/ echo doc/mkimage.1 /usr/share/man/man1/ # manpages -- 2.1.0