linux: allow specification of a custom Git repository as a source
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Mon, 11 Jul 2011 20:46:11 +0000 (22:46 +0200)
committerPeter Korsgaard <jacmet@sunsite.dk>
Mon, 11 Jul 2011 21:40:49 +0000 (23:40 +0200)
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
linux/Config.in
linux/linux.mk

index bf16ddf2b7915c48399d00858b2c616c2c288caa..8d3b0ba849180fa64f4ce15ba31413cb12f7a005 100644 (file)
@@ -47,6 +47,12 @@ config BR2_LINUX_KERNEL_CUSTOM_TARBALL
          This option allows to specify the http or ftp location of a
          specific kernel source tarball
 
+config BR2_LINUX_KERNEL_CUSTOM_GIT
+       bool "Custom Git tree"
+       help
+         This option allows Buildroot to get the Linux kernel source
+         code from a Git repository.
+
 endchoice
 
 config BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE
@@ -58,12 +64,21 @@ config BR2_LINUX_KERNEL_CUSTOM_TARBALL_LOCATION
        string "URL of custom kernel tarball"
        depends on BR2_LINUX_KERNEL_CUSTOM_TARBALL
 
+config BR2_LINUX_KERNEL_CUSTOM_GIT_REPO_URL
+       string "URL of custom Git repository"
+       depends on BR2_LINUX_KERNEL_CUSTOM_GIT
+
+config BR2_LINUX_KERNEL_CUSTOM_GIT_VERSION
+       string "Custom Git version"
+       depends on BR2_LINUX_KERNEL_CUSTOM_GIT
+
 config BR2_LINUX_KERNEL_VERSION
        string
        default "2.6.39.3" if BR2_LINUX_KERNEL_2_6_39
        default BR2_DEFAULT_KERNEL_HEADERS if BR2_LINUX_KERNEL_SAME_AS_HEADERS
        default BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE if BR2_LINUX_KERNEL_CUSTOM_VERSION
        default "custom" if BR2_LINUX_KERNEL_CUSTOM_TARBALL
+       default $BR2_LINUX_KERNEL_CUSTOM_GIT_VERSION if BR2_LINUX_KERNEL_CUSTOM_GIT
 
 #
 # Patch selection
index 25db1f5ea53db29fe85bd1540bd89588647ebded..bba49216c7e1b093deb41a691ad50db322aed769 100644 (file)
@@ -10,6 +10,9 @@ ifeq ($(LINUX_VERSION),custom)
 LINUX_TARBALL = $(call qstrip,$(BR2_LINUX_KERNEL_CUSTOM_TARBALL_LOCATION))
 LINUX_SITE = $(dir $(LINUX_TARBALL))
 LINUX_SOURCE = $(notdir $(LINUX_TARBALL))
+else ifeq ($(BR2_LINUX_KERNEL_CUSTOM_GIT),y)
+LINUX_SITE = $(call qstrip,$(BR2_LINUX_KERNEL_CUSTOM_GIT_REPO_URL))
+LINUX_SITE_METHOD = git
 else
 LINUX_SOURCE = linux-$(LINUX_VERSION).tar.bz2
 LINUX_SITE = $(BR2_KERNEL_MIRROR)/linux/kernel/v2.6/