[Buildroot] linux: why is vmlinux only available for mips?

Thomas Petazzoni thomas.petazzoni at free-electrons.com
Mon Jul 25 07:05:12 UTC 2011


Hello,

Le Sun, 24 Jul 2011 13:46:40 +0200,
Thomas De Schampheleire <patrickdepinguin+buildroot at gmail.com> a écrit :

> > Which vmlinux are you using ? The one at the top directory of the
> > kernel source tree, or the one in arch/<ARCH>/boot ?
> 
> I am using vmlinux from the kernel top directory. In fact, this is
> also where the linux.mk rules take it from:
> 
> ifeq ($(BR2_LINUX_KERNEL_VMLINUX),y)
> LINUX26_IMAGE_PATH=$(LINUX26_DIR)/$(LINUX26_IMAGE_NAME)
> else
> ifeq ($(KERNEL_ARCH),avr32)
> LINUX26_IMAGE_PATH=$(KERNEL_ARCH_PATH)/boot/images/$(LINUX26_IMAGE_NAME)
> else
> LINUX26_IMAGE_PATH=$(KERNEL_ARCH_PATH)/boot/$(LINUX26_IMAGE_NAME)
> endif
> endif # BR2_LINUX_KERNEL_VMLINUX
> 
> If one would want to use vmlinux from arch/<arch>/boot, then he or she
> could use BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM and
> BR2_LINUX_KERNEL_IMAGE_TARGET_NAME without a problem.
> 
> As you mentioned, arch/<arch>/boot doesn't contain vmlinux for all
> architectures, while the top kernel directory does. Since buildroot
> already has a rule to get to this package, I simply wanted to remove
> the architecture dependency from it.

Ok, but typically, the vmlinux in the top directory isn't a bootable
image, as it is a pure ELF binary image. Are there
architectures/bootloaders combinations for which this format makes
sense ?

> >> >> * I need to get to the dtc (device tree compiler) which resides in
> >> >> <linux>/scripts/dtc/dtc
> >> >
> >> > This tool looks like a useful host tool built by the kernel. Maybe we
> >> > should install it in $(HOST_DIR)/usr/bin ?
> >>
> >> Yes, I agree. How do you do that?
> >
> > You can hijack any of the installation steps of the kernel to install
> > this tool to $(HOST_DIR)/usr/bin. But technically speaking, this
> > wouldn't respect the convention of the package infrastructure: the
> > "linux" package is a target package, and it is therefore not supposed
> > to install anything in $(HOST_DIR).
> 
> What about making a separate dtc package? The official sources are
> here, I think:
> http://jdl.com/software/

Ok, would indeed be nice to have a separate tarball for this. Is this
kept in sync with the version inside the kernel ?

Regards,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com



More information about the buildroot mailing list