aboutsummaryrefslogtreecommitdiffstats
path: root/support/kconfig/patches
diff options
context:
space:
mode:
authorPeter Korsgaard <jacmet@sunsite.dk>2012-01-13 12:48:28 +0100
committerPeter Korsgaard <jacmet@sunsite.dk>2012-01-15 20:48:04 +0100
commit21f540be4e247b4468d0e8adbf9e3a7575f8a085 (patch)
tree8c572a31fbc5cbeecb015a3b15ce00debf03a074 /support/kconfig/patches
parent8f8d414b61bf3b27a77ad38dfc493ae412b65471 (diff)
downloadbuildroot-novena-21f540be4e247b4468d0e8adbf9e3a7575f8a085.tar.gz
buildroot-novena-21f540be4e247b4468d0e8adbf9e3a7575f8a085.zip
kconfig: sync with linux-3.0
And drop unused make-write-deps patch. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Diffstat (limited to 'support/kconfig/patches')
-rw-r--r--support/kconfig/patches/03-change-config-option-prefix.patch22
-rw-r--r--support/kconfig/patches/05-really-clean-everything.patch29
-rw-r--r--support/kconfig/patches/06-br-build-system-integration.patch47
-rw-r--r--support/kconfig/patches/08-make-write-deps.patch139
-rw-r--r--support/kconfig/patches/09-implement-kconfig-probability.patch10
-rw-r--r--support/kconfig/patches/12-fix-glade-file-path.patch2
-rw-r--r--support/kconfig/patches/14-support-out-of-tree-config.patch42
-rw-r--r--support/kconfig/patches/series2
8 files changed, 59 insertions, 234 deletions
diff --git a/support/kconfig/patches/03-change-config-option-prefix.patch b/support/kconfig/patches/03-change-config-option-prefix.patch
index d387236e7..4c51eaa9b 100644
--- a/support/kconfig/patches/03-change-config-option-prefix.patch
+++ b/support/kconfig/patches/03-change-config-option-prefix.patch
@@ -4,10 +4,10 @@
menu.c | 2 +-
3 files changed, 31 insertions(+), 30 deletions(-)
-Index: config/confdata.c
+Index: kconfig/confdata.c
===================================================================
---- config.orig/confdata.c
-+++ config/confdata.c
+--- kconfig.orig/confdata.c
++++ kconfig/confdata.c
@@ -12,6 +12,7 @@
#include <string.h>
#include <time.h>
@@ -125,7 +125,7 @@ Index: config/confdata.c
break;
case S_OTHER:
case S_UNKNOWN:
-@@ -844,17 +845,17 @@
+@@ -830,17 +831,17 @@
case no:
break;
case mod:
@@ -151,7 +151,7 @@ Index: config/confdata.c
break;
}
break;
-@@ -864,14 +865,14 @@
+@@ -850,14 +851,14 @@
case S_HEX:
str = sym_get_string_value(sym);
if (str[0] != '0' || (str[1] != 'x' && str[1] != 'X')) {
@@ -170,10 +170,10 @@ Index: config/confdata.c
break;
default:
break;
-Index: config/lkc.h
+Index: kconfig/lkc.h
===================================================================
---- config.orig/lkc.h
-+++ config/lkc.h
+--- kconfig.orig/lkc.h
++++ kconfig/lkc.h
@@ -42,7 +42,7 @@
#define N_(text) (text)
@@ -183,10 +183,10 @@ Index: config/lkc.h
#endif
#define TF_COMMAND 0x0001
-Index: config/menu.c
+Index: kconfig/menu.c
===================================================================
---- config.orig/menu.c
-+++ config/menu.c
+--- kconfig.orig/menu.c
++++ kconfig/menu.c
@@ -597,7 +597,7 @@
if (menu_has_help(menu)) {
diff --git a/support/kconfig/patches/05-really-clean-everything.patch b/support/kconfig/patches/05-really-clean-everything.patch
deleted file mode 100644
index a1517542e..000000000
--- a/support/kconfig/patches/05-really-clean-everything.patch
+++ /dev/null
@@ -1,29 +0,0 @@
----
- Makefile | 14 ++++++++++----
- 1 file changed, 10 insertions(+), 4 deletions(-)
-
-Index: config/Makefile
-===================================================================
---- config.orig/Makefile
-+++ config/Makefile
-@@ -196,10 +196,16 @@
- gconf-objs := gconf.o kconfig_load.o zconf.tab.o
- endif
-
--clean-files := lkc_defs.h qconf.moc .tmp_qtcheck \
-- .tmp_gtkcheck zconf.tab.c lex.zconf.c zconf.hash.c gconf.glade.h
--clean-files += mconf qconf gconf nconf
--clean-files += config.pot linux.pot
-+clean-files := lkc_defs.h qconf.moc .tmp_qtcheck \
-+ .tmp_gtkcheck zconf.tab.c lex.zconf.c zconf.hash.c gconf.glade.h
-+clean-files += config.pot linux.pot
-+clean-files += conf $(conf-objs)
-+clean-files += mconf $(mconf-objs)
-+clean-files += nconf $(nconf-objs)
-+clean-files += qconf qconf.o
-+clean-files += gconf gconf.o
-+clean-files += kconfig_load.o zconf.tab.o
-+clean-files += $(kxgettext-objs)
-
- # Check that we have the required ncurses stuff installed for lxdialog (menuconfig)
- PHONY += $(obj)/dochecklxdialog
diff --git a/support/kconfig/patches/06-br-build-system-integration.patch b/support/kconfig/patches/06-br-build-system-integration.patch
index 8a27e251e..feb166d36 100644
--- a/support/kconfig/patches/06-br-build-system-integration.patch
+++ b/support/kconfig/patches/06-br-build-system-integration.patch
@@ -1,40 +1,35 @@
---
- Makefile | 14 +++++++++++++-
- 1 file changed, 13 insertions(+), 1 deletion(-)
+ Makefile | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
-Index: config/Makefile
+Index: kconfig/Makefile
===================================================================
---- config.orig/Makefile
-+++ config/Makefile
-@@ -174,18 +174,30 @@
- ifeq ($(MAKECMDGOALS),nconfig)
+--- kconfig.orig/Makefile
++++ kconfig/Makefile
+@@ -175,11 +175,11 @@
+
+ hostprogs-y := conf
+
+-ifeq ($(MAKECMDGOALS),nconfig)
++ifeq ($(MAKECMDGOALS),nconf)
hostprogs-y += nconf
endif
-+ifeq ($(findstring nconf,$(MAKECMDGOALS)),nconf)
-+ hostprogs-y += nconf
-+endif
- ifeq ($(MAKECMDGOALS),menuconfig)
+-ifeq ($(MAKECMDGOALS),menuconfig)
++ifeq ($(MAKECMDGOALS),mconf)
hostprogs-y += mconf
endif
-+ifeq ($(findstring mconf,$(MAKECMDGOALS)),mconf)
-+ hostprogs-y += mconf
-+endif
- ifeq ($(MAKECMDGOALS),xconfig)
+@@ -187,10 +187,10 @@
+ hostprogs-y += kxgettext
+ endif
+
+-ifeq ($(MAKECMDGOALS),xconfig)
++ifeq ($(MAKECMDGOALS),qconf)
qconf-target := 1
endif
-+ifeq ($(findstring qconf,$(MAKECMDGOALS)),qconf)
-+ qconf-target := 1
-+endif
-+
- ifeq ($(MAKECMDGOALS),gconfig)
+-ifeq ($(MAKECMDGOALS),gconfig)
++ifeq ($(MAKECMDGOALS),gconf)
gconf-target := 1
endif
--
-+ifeq ($(findstring gconf,$(MAKECMDGOALS)),gconf)
-+ gconf-target := 1
-+endif
- ifeq ($(qconf-target),1)
- qconf-cxxobjs := qconf.o
diff --git a/support/kconfig/patches/08-make-write-deps.patch b/support/kconfig/patches/08-make-write-deps.patch
deleted file mode 100644
index e5a21c386..000000000
--- a/support/kconfig/patches/08-make-write-deps.patch
+++ /dev/null
@@ -1,139 +0,0 @@
----
- util.c | 117 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
- 1 file changed, 116 insertions(+), 1 deletion(-)
-
-Index: kconfig/util.c
-===================================================================
---- kconfig.orig/util.c
-+++ kconfig/util.c
-@@ -29,6 +29,121 @@
- return file;
- }
-
-+static char* br2_symbol_printer(const char * const in)
-+{
-+ ssize_t i, j, len = strlen(in);
-+ char *ret;
-+ if (len < 1)
-+ return NULL;
-+ ret = malloc(len+1);
-+ if (!ret) {
-+ printf("Out of memory!");
-+ exit(1);
-+ }
-+ memset(ret, 0, len+1);
-+ i = j = 0;
-+ if (strncmp("BR2_", in, 4) == 0)
-+ i += 4;
-+ if (strncmp("PACKAGE_", in + i, 8) == 0)
-+ i += 8;
-+ else if (strncmp("TARGET_", in + i, 7) == 0)
-+ i += 7;
-+ while (i <= len)
-+ ret[j++] = tolower(in[i++]);
-+ return ret;
-+}
-+
-+/* write dependencies of the individual config-symbols */
-+static int write_make_deps(const char *name)
-+{
-+ char *str;
-+ char dir[PATH_MAX+1], buf[PATH_MAX+1], buf2[PATH_MAX+1];
-+ struct menu *menu;
-+ struct symbol *sym;
-+ struct property *prop, *p;
-+ unsigned done;
-+ const char * const name_tmp = "..make.deps.tmp";
-+ FILE *out;
-+ if (!name)
-+ name = ".auto.deps";
-+
-+ strcpy(dir, conf_get_configname());
-+ str = strrchr(dir, '/');
-+ if (str)
-+ str[1] = 0;
-+ else
-+ dir[0] = 0;
-+
-+ sprintf(buf, "%s%s", dir, name_tmp);
-+ out = fopen(buf, "w");
-+ if (!out)
-+ return 1;
-+ fprintf(out, "# ATTENTION! This does not handle 'depends', just 'select'! \n"
-+ "# See support/kconfig/util.c write_make_deps()\n#\n");
-+ menu = &rootmenu;//rootmenu.list;
-+ while (menu) {
-+ sym = menu->sym;
-+ if (!sym) {
-+ if (!menu_is_visible(menu))
-+ goto next;
-+ } else if (!(sym->flags & SYMBOL_CHOICE)) {
-+ sym_calc_value(sym);
-+ if (sym->type == S_BOOLEAN
-+ && sym_get_tristate_value(sym) != no) {
-+ done = 0;
-+ for_all_prompts(sym, prop) {
-+ struct expr *e;
-+//printf("\nname=%s\n", sym->name);
-+ for_all_properties(sym, p, P_SELECT) {
-+ e = p->expr;
-+ if (e && e->left.sym->name) {
-+ if (!done) {
-+ fprintf(out, "%s: $(BASE_TARGETS)", br2_symbol_printer(sym->name));
-+ done = 1;
-+ }
-+//printf("SELECTS %s\n",e->left.sym->name);
-+ fprintf(out, " %s",br2_symbol_printer(e->left.sym->name));
-+ }
-+ }
-+ if (done)
-+ fprintf(out, "\n");
-+#if 0
-+ e = sym->rev_dep.expr;
-+ if (e && e->type == E_SYMBOL
-+ && e->left.sym->name) {
-+ fprintf(out, "%s: %s", br2_symbol_printer(e->left.sym->name),
-+ br2_symbol_printer(sym->name));
-+printf("%s is Selected BY: %s", sym->name, e->left.sym->name);
-+ }
-+#endif
-+ }
-+ }
-+ }
-+next:
-+ if (menu->list) {
-+ menu = menu->list;
-+ continue;
-+ }
-+ if (menu->next)
-+ menu = menu->next;
-+ else while ((menu = menu->parent)) {
-+ if (menu->next) {
-+ menu = menu->next;
-+ break;
-+ }
-+ }
-+ }
-+ fclose(out);
-+ sprintf(buf2, "%s%s", dir, name);
-+ rename(buf, buf2);
-+ printf(_("#\n"
-+ "# make dependencies written to %s\n"
-+ "# ATTENTION buildroot devels!\n"
-+ "# See top of this file before playing with this auto-preprequisites!\n"
-+ "#\n"), name);
-+ return 0;
-+}
-+
- /* write a dependency file as used by kbuild to track dependencies */
- int file_write_dep(const char *name)
- {
-@@ -71,7 +186,7 @@
- fprintf(out, "\n$(deps_config): ;\n");
- fclose(out);
- rename("..config.tmp", name);
-- return 0;
-+ return write_make_deps(NULL);
- }
-
-
diff --git a/support/kconfig/patches/09-implement-kconfig-probability.patch b/support/kconfig/patches/09-implement-kconfig-probability.patch
index 3f09673b8..3b6eb898f 100644
--- a/support/kconfig/patches/09-implement-kconfig-probability.patch
+++ b/support/kconfig/patches/09-implement-kconfig-probability.patch
@@ -2,11 +2,11 @@
confdata.c | 22 +++++++++++++++++++---
1 file changed, 19 insertions(+), 3 deletions(-)
-Index: config/confdata.c
+Index: kconfig/confdata.c
===================================================================
---- config.orig/confdata.c
-+++ config/confdata.c
-@@ -996,7 +996,16 @@
+--- kconfig.orig/confdata.c
++++ kconfig/confdata.c
+@@ -982,7 +982,16 @@
void conf_set_all_new_symbols(enum conf_def_mode mode)
{
struct symbol *sym, *csym;
@@ -24,7 +24,7 @@ Index: config/confdata.c
for_all_symbols(i, sym) {
if (sym_has_value(sym))
-@@ -1015,8 +1024,15 @@
+@@ -1001,8 +1010,15 @@
sym->def[S_DEF_USER].tri = no;
break;
case def_random:
diff --git a/support/kconfig/patches/12-fix-glade-file-path.patch b/support/kconfig/patches/12-fix-glade-file-path.patch
index 681dce160..badfc91d8 100644
--- a/support/kconfig/patches/12-fix-glade-file-path.patch
+++ b/support/kconfig/patches/12-fix-glade-file-path.patch
@@ -6,7 +6,7 @@ Index: kconfig/gconf.c
===================================================================
--- kconfig.orig/gconf.c
+++ kconfig/gconf.c
-@@ -1521,7 +1521,7 @@
+@@ -1525,7 +1525,7 @@
/* Determine GUI path */
env = getenv(SRCTREE);
if (env)
diff --git a/support/kconfig/patches/14-support-out-of-tree-config.patch b/support/kconfig/patches/14-support-out-of-tree-config.patch
index 9fa6384d3..8d76df2e6 100644
--- a/support/kconfig/patches/14-support-out-of-tree-config.patch
+++ b/support/kconfig/patches/14-support-out-of-tree-config.patch
@@ -4,10 +4,10 @@
util.c | 16 +++++++++++++--
3 files changed, 61 insertions(+), 18 deletions(-)
-Index: config/conf.c
+Index: kconfig/conf.c
===================================================================
---- config.orig/conf.c
-+++ config/conf.c
+--- kconfig.orig/conf.c
++++ kconfig/conf.c
@@ -503,7 +503,6 @@
}
name = av[optind];
@@ -16,10 +16,10 @@ Index: config/conf.c
if (sync_kconfig) {
name = conf_get_configname();
if (stat(name, &tmpstat)) {
-Index: config/confdata.c
+Index: kconfig/confdata.c
===================================================================
---- config.orig/confdata.c
-+++ config/confdata.c
+--- kconfig.orig/confdata.c
++++ kconfig/confdata.c
@@ -71,9 +71,7 @@
const char *conf_get_autoconfig_name(void)
@@ -31,8 +31,8 @@ Index: config/confdata.c
}
static char *conf_expand_value(const char *in)
-@@ -565,6 +563,9 @@
- int use_timestamp = 1;
+@@ -563,6 +561,9 @@
+ char dirname[PATH_MAX+1], tmpname[PATH_MAX+1], newname[PATH_MAX+1];
char *env;
+ if (!name)
@@ -41,7 +41,7 @@ Index: config/confdata.c
dirname[0] = 0;
if (name && name[0]) {
struct stat st;
-@@ -671,6 +672,7 @@
+@@ -661,6 +662,7 @@
{
const char *name;
char path[PATH_MAX+1];
@@ -49,7 +49,7 @@ Index: config/confdata.c
char *s, *d, c;
struct symbol *sym;
struct stat sb;
-@@ -679,8 +681,20 @@
+@@ -669,8 +671,20 @@
name = conf_get_autoconfig_name();
conf_read_simple(name, S_DEF_AUTO);
@@ -72,7 +72,7 @@ Index: config/confdata.c
res = 0;
for_all_symbols(i, sym) {
-@@ -773,9 +787,11 @@
+@@ -763,9 +777,11 @@
close(fd);
}
out:
@@ -87,9 +87,9 @@ Index: config/confdata.c
return res;
}
-@@ -787,25 +803,38 @@
+@@ -776,25 +792,38 @@
+ const char *name;
FILE *out, *tristate, *out_h;
- time_t now;
int i;
+ char dir[PATH_MAX+1], buf[PATH_MAX+1];
+ char *s;
@@ -130,7 +130,7 @@ Index: config/confdata.c
if (!out_h) {
fclose(out);
fclose(tristate);
-@@ -885,19 +914,22 @@
+@@ -871,19 +900,22 @@
name = getenv("KCONFIG_AUTOHEADER");
if (!name)
name = "include/generated/autoconf.h";
@@ -156,11 +156,11 @@ Index: config/confdata.c
return 1;
return 0;
-Index: config/util.c
+Index: kconfig/util.c
===================================================================
---- config.orig/util.c
-+++ config/util.c
-@@ -147,6 +147,8 @@
+--- kconfig.orig/util.c
++++ kconfig/util.c
+@@ -32,6 +32,8 @@
/* write a dependency file as used by kbuild to track dependencies */
int file_write_dep(const char *name)
{
@@ -169,7 +169,7 @@ Index: config/util.c
struct symbol *sym, *env_sym;
struct expr *e;
struct file *file;
-@@ -154,7 +156,16 @@
+@@ -39,7 +41,16 @@
if (!name)
name = ".kconfig.d";
@@ -187,13 +187,13 @@ Index: config/util.c
if (!out)
return 1;
fprintf(out, "deps_config := \\\n");
-@@ -185,7 +196,8 @@
+@@ -70,7 +81,8 @@
fprintf(out, "\n$(deps_config): ;\n");
fclose(out);
- rename("..config.tmp", name);
+ sprintf(buf2, "%s%s", dir, name);
+ rename(buf, buf2);
- return write_make_deps(NULL);
+ return 0;
}
diff --git a/support/kconfig/patches/series b/support/kconfig/patches/series
index defdf5899..573911bdd 100644
--- a/support/kconfig/patches/series
+++ b/support/kconfig/patches/series
@@ -1,9 +1,7 @@
01-kconfig-kernel-to-buildroot.patch
02-cpp-comments-to-c-comments.patch
03-change-config-option-prefix.patch
-05-really-clean-everything.patch
06-br-build-system-integration.patch
-08-make-write-deps.patch
09-implement-kconfig-probability.patch
10-br-build-system.patch
11-use-mktemp-for-lxdialog.patch