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

Re: [RFC] include DTB in linux-image files on armel



On Fri, 2012-04-20 at 14:25 +0100, Ian Campbell wrote:
> On Fri, 2012-04-20 at 13:35 +0200, Bastian Blank wrote:
> > On Fri, Apr 20, 2012 at 11:11:27AM +0100, Ian Campbell wrote:
> > > -install-image_armel_$(FEATURESET)_$(FLAVOUR)_plain_image \
> > > +ifneq ($(filter armel,$(ARCH)),)
> > > +install-image_$(ARCH)_$(FEATURESET)_$(FLAVOUR)_plain_image:
> > 
> > What is this supposed to do?
> 
> I'm not sure. I copied the pattern from the similar powerpc case.
> s390/s390x does the same.
> 
> Oh, I see, those cases both cover multiple arches and use $(ARCH), hence
> need gating appropriately. As it stands my patch only support armel so
> could use armel explicitly. Except I think we need to add armhf support
> for this too and that would require this pattern.

Here is an updated patch, supports armhf as well. There's not actually
any users in armhf AFAIK, actually until dreamplug support goes in there
is none in armel either...

It now uses /usr/lib/linux-image-VERSION/foo.dtb which is consistent
with the attached flash-kernel-install-dtb.patch which is under
discussion in #667681.

Ian.

diff --git a/linux-2.6/debian/rules.real b/linux-2.6/debian/rules.real
index a7f56c3..2fbcdc8 100644
--- a/linux-2.6/debian/rules.real
+++ b/linux-2.6/debian/rules.real
@@ -356,8 +356,16 @@ endif
 	  PACKAGE_DIR='$(PACKAGE_DIR)' PACKAGE_NAME='$(PACKAGE_NAME)' REAL_VERSION='$(REAL_VERSION)'
 	+$(MAKE_SELF) install-base
 
-install-image_armel_$(FEATURESET)_$(FLAVOUR)_plain_image \
-install-image_armhf_$(FEATURESET)_$(FLAVOUR)_plain_image \
+ifneq ($(filter armel armhf,$(ARCH)),)
+install-image_$(ARCH)_$(FEATURESET)_$(FLAVOUR)_plain_image: DTB_INSTALL_DIR = /usr/lib/linux-image-$(REAL_VERSION)
+install-image_$(ARCH)_$(FEATURESET)_$(FLAVOUR)_plain_image:
+	install -m644 '$(DIR)/arch/$(KERNEL_ARCH)/boot/zImage' $(INSTALL_DIR)/vmlinuz-$(REAL_VERSION)
+	+$(MAKE_CLEAN) -C $(DIR) dtbs
+	shopt -s nullglob ; for i in $(DIR)/arch/arm/boot/*.dtb ; do \
+	    install -D -m644 $$i '$(PACKAGE_DIR)'/'$(DTB_INSTALL_DIR)'/$$(basename $$i) ; \
+	done
+endif
+
 install-image_sparc_$(FEATURESET)_$(FLAVOUR)_plain_image \
 install-image_sparc64_$(FEATURESET)_$(FLAVOUR)_plain_image \
 install-image_sh4_$(FEATURESET)_$(FLAVOUR)_plain_image:



-- 
Ian Campbell


Vitamin C deficiency is apauling.


Reply to: