@@ -19,6 +19,7 @@
#include <unistd.h>
#include "lkc.h"
+#include "internal.h"
/* return true if 'path' exists, false otherwise */
static bool is_present(const char *path)
@@ -1,4 +1,8 @@
/* SPDX-License-Identifier: GPL-2.0-only */
+/*
+ * Declarations necessary for the kconfig core, but not for
+ * conf, mconf, nconf, gconf, or xconf variants.
+ */
#ifndef INTERNAL_H
#define INTERNAL_H
@@ -6,4 +10,17 @@ struct menu;
extern struct menu *current_menu, *current_entry;
+/* preprocess.c */
+enum variable_flavor {
+ VAR_SIMPLE,
+ VAR_RECURSIVE,
+ VAR_APPEND,
+};
+void env_write_dep(FILE *f, const char *auto_conf_name);
+void variable_add(const char *name, const char *value,
+ enum variable_flavor flavor);
+void variable_all_del(void);
+char *expand_dollar(const char **str);
+char *expand_one_token(const char **str);
+
#endif /* INTERNAL_H */
@@ -14,6 +14,7 @@
#include <string.h>
#include "lkc.h"
+#include "internal.h"
#include "parser.tab.h"
#define YY_DECL static int yylex1(void)
@@ -35,18 +35,5 @@ const char * sym_get_string_value(struct symbol *sym);
const char * prop_get_type_name(enum prop_type type);
-/* preprocess.c */
-enum variable_flavor {
- VAR_SIMPLE,
- VAR_RECURSIVE,
- VAR_APPEND,
-};
-void env_write_dep(FILE *f, const char *auto_conf_name);
-void variable_add(const char *name, const char *value,
- enum variable_flavor flavor);
-void variable_all_del(void);
-char *expand_dollar(const char **str);
-char *expand_one_token(const char **str);
-
/* expr.c */
void expr_print(struct expr *e, void (*fn)(void *, struct symbol *, const char *), void *data, int prevtoken);
@@ -11,6 +11,7 @@
#include "list.h"
#include "lkc.h"
+#include "internal.h"
#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
These are used by the kconfig core part. The user interface part (conf, mconf, nconf, gconf, or xconf variants) does not need them. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> --- scripts/kconfig/confdata.c | 1 + scripts/kconfig/internal.h | 17 +++++++++++++++++ scripts/kconfig/lexer.l | 1 + scripts/kconfig/lkc_proto.h | 13 ------------- scripts/kconfig/preprocess.c | 1 + 5 files changed, 20 insertions(+), 13 deletions(-)