]> git.sur5r.net Git - kconfig-frontends/commitdiff
Synchronise from kernel
authorYann E. MORIN" <yann.morin.1998@free.fr>
Tue, 17 Apr 2012 22:52:15 +0000 (00:52 +0200)
committerYann E. MORIN" <yann.morin.1998@free.fr>
Tue, 17 Apr 2012 22:52:15 +0000 (00:52 +0200)
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
.version
libs/parser/confdata.c

index 503a95260e3fc69dddbe55e3562468090728214a..a27163aac5710c1bee6ee981a98cf3b6d400f726 100644 (file)
--- a/.version
+++ b/.version
@@ -1,2 +1,2 @@
-3.4.0-rc2 0034102808e0dbbf3a2394b82b1bb40b5778de9e Saber-toothed Squirrel
+3.4.0-rc3 e816b57a337ea3b755de72bec38c10c864f23015 Saber-toothed Squirrel
 hg
index 0586085136d1304eebaa43142be468e4a7f40c8c..52577f052bc12d06503aa9d6459eaa578fb0fd4b 100644 (file)
@@ -539,35 +539,6 @@ static struct conf_printer header_printer_cb =
        .print_comment = header_print_comment,
 };
 
-/*
- * Generate the __enabled_CONFIG_* and __enabled_CONFIG_*_MODULE macros for
- * use by the IS_{ENABLED,BUILTIN,MODULE} macros. The _MODULE variant is
- * generated even for booleans so that the IS_ENABLED() macro works.
- */
-static void
-header_print__enabled_symbol(FILE *fp, struct symbol *sym, const char *value, void *arg)
-{
-
-       switch (sym->type) {
-       case S_BOOLEAN:
-       case S_TRISTATE: {
-               fprintf(fp, "#define __enabled_" CONFIG_ "%s %d\n",
-                   sym->name, (*value == 'y'));
-               fprintf(fp, "#define __enabled_" CONFIG_ "%s_MODULE %d\n",
-                   sym->name, (*value == 'm'));
-               break;
-       }
-       default:
-               break;
-       }
-}
-
-static struct conf_printer header__enabled_printer_cb =
-{
-       .print_symbol = header_print__enabled_symbol,
-       .print_comment = header_print_comment,
-};
-
 /*
  * Tristate printer
  *
@@ -949,16 +920,11 @@ int conf_write_autoconf(void)
        conf_write_heading(out_h, &header_printer_cb, NULL);
 
        for_all_symbols(i, sym) {
-               if (!sym->name)
-                       continue;
-
                sym_calc_value(sym);
-
-               conf_write_symbol(out_h, sym, &header__enabled_printer_cb, NULL);
-
-               if (!(sym->flags & SYMBOL_WRITE))
+               if (!(sym->flags & SYMBOL_WRITE) || !sym->name)
                        continue;
 
+               /* write symbol to auto.conf, tristate and header files */
                conf_write_symbol(out, sym, &kconfig_printer_cb, (void *)1);
 
                conf_write_symbol(tristate, sym, &tristate_printer_cb, (void *)1);