Bug 6320 - Fix kernel compile issue if BR2_LINUX_KERNEL_CUSTOM_GIT_VERSION/BR2_LINUX_KERNEL_SOURCE_DIR and BR2_LINUX_KERNEL_INTREE_DTS_NAME are defined
Summary: Fix kernel compile issue if BR2_LINUX_KERNEL_CUSTOM_GIT_VERSION/BR2_LINUX_KER...
Status: RESOLVED FIXED
Alias: None
Product: buildroot
Classification: Unclassified
Component: Other (show other bugs)
Version: unspecified
Hardware: All Linux
: P5 minor
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-17 18:12 UTC by Aron Rosenberg
Modified: 2013-11-14 00:16 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:


Attachments
Patch to fix issue (1.27 KB, patch)
2013-06-17 18:12 UTC, Aron Rosenberg
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Aron Rosenberg 2013-06-17 18:12:49 UTC
Created attachment 4946 [details]
Patch to fix issue

If you use BR2_LINUX_KERNEL_SOURCE_DIR and/or BR2_LINUX_KERNEL_CUSTOM_GIT_VERSION along with BR2_LINUX_KERNEL_INTREE_DTS_NAME the kernel will fail to build.

1. BR2_LINUX_KERNEL_SOURCE_DIR is not properly added when LINUX_BUILD_DTB is defined so the make command fails.

2. BR2_LINUX_KERNEL_CUSTOM_GIT_VERSION and BR2_LINUX_KERNEL_SOURCE_DIR are quoted strings and the "wildcard" call can't handle if a double-quote is contained within it (which happens if BR2_LINUX_KERNEL_INTREE_DTS_NAME or BR2_LINUX_KERNEL_CUSTOM_GIT_VERSION are defined). So if you are using a kernel newer than 3.8, it will fail the new test and look for the dtb without the dts/ sub-directory.

linux/linux.mk:
		$(KERNEL_ARCH_PATH)/boot/$(if $(wildcard \
		$(addprefix $(KERNEL_ARCH_PATH)/boot/dts/,$(KERNEL_DTBS))),dts/),$(KERNEL_DTBS)) \
		$(BINARIES_DIR)/

The attached patch fixes both issues.
Comment 1 Thomas Petazzoni 2013-11-14 00:10:04 UTC
Where is BR2_LINUX_KERNEL_SOURCE_DIR coming from? We don't have this configuration option in mainline Buildroot, it seems.
Comment 2 Aron Rosenberg 2013-11-14 00:16:26 UTC
Now that I look at our history, it was a change we made a while ago and never pushed upstream. You can close this bug report.