: Allow cloning a git branch of uClibc
RFC PATCH 1/1 : Allow cloning a git branch of uClibc
This patch allows to clone a branch of uClibc git repository (instead of a release or snapshot source).
Signed-off-by Abdoulaye Walsimou Gaye <[email protected]>
--- toolchain/uClibc/Config.in | 10 ++ toolchain/uClibc/uClibc-git.config | 229 ++++++++++++++++++++++++++++++++++++ toolchain/uClibc/uclibc.mk | 27 ++++- 3 files changed, 265 insertions(+), 1 deletions(-) create mode 100644 toolchain/uClibc/uClibc-git.config
toolchain/uClibc/Config.in +10 -0
@@ -31,6 +31,9 @@ choice config BR2_UCLIBC_VERSION_SNAPSHOT bool "daily snapshot" + config BR2_UCLIBC_VERSION_GIT + bool "branch you wish" + endchoice
@@ -48,6 +51,12 @@ config BR2_UCLIBC_VERSION_STRING default 0.9.30 if BR2_UCLIBC_VERSION_0_9_30 default 0.9.30.1 if BR2_UCLIBC_VERSION_0_9_30_1 default $BR2_USE_UCLIBC_SNAPSHOT if BR2_UCLIBC_VERSION_SNAPSHOT + default git if BR2_UCLIBC_VERSION_GIT + +config BR2_UCLIBC_GIT_BRANCH + depends on BR2_UCLIBC_VERSION_GIT + string "which branch of uClibc to checkout" + default "master" config BR2_UCLIBC_CONFIG string "uClibc configuration file to use?"
@@ -56,6 +65,7 @@ config BR2_UCLIBC_CONFIG default "toolchain/uClibc/uClibc-0.9.30.config" if BR2_UCLIBC_VERSION_0_9_30 default "toolchain/uClibc/uClibc-0.9.30.config" if BR2_UCLIBC_VERSION_0_9_30_1 default "toolchain/uClibc/uClibc-snapshot.config" if BR2_UCLIBC_VERSION_SNAPSHOT + default "toolchain/uClibc/uClibc-git.config" if BR2_UCLIBC_VERSION_GIT help Some people may wish to use their own modified uClibc configuration file and will specify their config file location with this option.
toolchain/uClibc/uClibc-git.config new file +229 -0
229 lines not on this page · raw message
toolchain/uClibc/uclibc.mk +26 -1
@@ -21,6 +21,10 @@ UCLIBC_OFFICIAL_VERSION:=$(UCLIBC_VER)$(VENDOR_SUFFIX)$(VENDOR_UCLIBC_RELEASE) ifeq ($(BR2_UCLIBC_VERSION_SNAPSHOT),y) UCLIBC_SITE:=http://www.uclibc.org/downloads/snapshots UCLIBC_DIR:=$(TOOL_BUILD_DIR)/uClibc +else ifeq ($(BR2_UCLIBC_VERSION_GIT),y) +UCLIBC_GIT_BRANCH:=$(strip $(subst ",, $(BR2_UCLIBC_GIT_BRANCH))) +UCLIBC_SITE:=git://git.busybox.net/uClibc.git +UCLIBC_DIR:=$(TOOL_BUILD_DIR)/uClibc-$(UCLIBC_GIT_BRANCH).git else UCLIBC_DIR:=$(TOOL_BUILD_DIR)/uClibc-$(UCLIBC_OFFICIAL_VERSION) UCLIBC_SITE:=http://www.uclibc.org/downloads
@@ -35,7 +39,11 @@ else UCLIBC_PATCH_DIR:=toolchain/uClibc/ext_source/$(VENDOR_PATCH_DIR)/$(UCLIBC_OFFICIAL_VERSION) endif +ifeq ($(BR2_UCLIBC_VERSION_GIT),y) +UCLIBC_SOURCE:=uClibc-$(UCLIBC_GIT_BRANCH).git.tar.bz2 +else UCLIBC_SOURCE:=uClibc-$(UCLIBC_OFFICIAL_VERSION).tar.bz2 +endif UCLIBC_CAT:=$(BZCAT)
@@ -80,8 +88,25 @@ UCLIBC_ARM_TYPE:=CONFIG_$(strip $(subst ",, $(BR2_ARM_TYPE))) UCLIBC_SPARC_TYPE:=CONFIG_SPARC_$(strip $(subst ",, $(BR2_SPARC_TYPE))) #")) + +ifeq ($(BR2_UCLIBC_VERSION_GIT),y) +UCLIBC_GIT_CMD:=$(strip $(subst ",, $(BR2_GIT))) +define UCLIBC_SOURCE_DOWNLOADER + $(Q)test -e $(DL_DIR)/$(UCLIBC_SOURCE) || \ + $(UCLIBC_GIT_CMD) $(UCLIBC_SITE) uClibc-$(UCLIBC_GIT_BRANCH).git; \ + cd uClibc-$(UCLIBC_GIT_BRANCH).git; \ + git checkout -b uClibc-$(UCLIBC_GIT_BRANCH) origin/$(UCLIBC_GIT_BRANCH); \ + cd ..; \ + tar cjvf $(UCLIBC_SOURCE) uClibc-$(UCLIBC_GIT_BRANCH).git; \ + rm -rf uClibc-$(UCLIBC_GIT_BRANCH).git; \ + mv $(UCLIBC_SOURCE) $(DL_DIR) +endef +else +UCLIBC_SOURCE_DOWNLOADER=DOWNLOAD +endif + $(DL_DIR)/$(UCLIBC_SOURCE): - $(call DOWNLOAD,$(UCLIBC_SITE),$(UCLIBC_SOURCE)) + $(call UCLIBC_SOURCE_DOWNLOADER,$(UCLIBC_SITE),$(UCLIBC_SOURCE)) ifneq ($(BR2_ENABLE_LOCALE_PREGENERATED),) UCLIBC_SITE_LOCALE:=http://www.uclibc.org/downloads
Signature · 1 line
1.6.0.4
RFC PATCH 1/1 : Allow cloning a git branch of uClibc
Quoted 11 lines · Abdoulaye Walsimou Gaye
This patch allows to clone a branch of uClibc git repository (instead of a release or snapshot source).
Signed-off-by Abdoulaye Walsimou Gaye <[email protected]>--- toolchain/uClibc/Config.in | 10 ++ toolchain/uClibc/uClibc-git.config | 229 ++++++++++++++++++++++++++++++++++++ toolchain/uClibc/uclibc.mk | 27 ++++- 3 files changed, 265 insertions(+), 1 deletions(-) create mode 100644 toolchain/uClibc/uClibc-git.config
Hello there,
No comments ...? Nacked ...?
How guys do you do to try master branch of uClibc whithin buildtroot, or nptl branch (which was what I wanted to try)?
Cheers