kconfig: split util.c out of parser.y
authorMasahiro Yamada <yamada.masahiro@socionext.com>
Sun, 25 Aug 2019 17:28:33 +0000 (02:28 +0900)
committerChristian Lamparter <chunkeey@gmail.com>
Sat, 1 Feb 2020 18:06:23 +0000 (19:06 +0100)
util.c exists both in scripts/kconfig/ and scripts/kconfig/lxdialog.

Prior to commit 54b8ae66ae1a ("kbuild: change *FLAGS_<basetarget>.o
to take the path relative to $(obj)"), Kbuild could not pass different
flags to source files with the same basename. Now that this issue
was solved, you can split util.c out of parser.y and compile them
independently of each other.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
config/CMakeLists.txt
config/parser.y

index e13cc885a4ea58f291636fc180ac61bcfc015894..5b341fcd213d2235f700d6e1189807e17a3c7119 100644 (file)
@@ -18,6 +18,6 @@ SET(parser_deps ${FLEX_lexer_OUTPUTS})
 SET_SOURCE_FILES_PROPERTIES(${BISON_parser_OUTPUTS}
       PROPERTIES OBJECT_DEPENDS "${parser_deps}")
 
 SET_SOURCE_FILES_PROPERTIES(${BISON_parser_OUTPUTS}
       PROPERTIES OBJECT_DEPENDS "${parser_deps}")
 
-set(conf_src conf.c symbol.c confdata.c expr.c preprocess.c ${BISON_parser_OUTPUTS} ${FLEX_lexer_OUTPUTS})
+set(conf_src conf.c util.c symbol.c confdata.c expr.c preprocess.c ${BISON_parser_OUTPUTS} ${FLEX_lexer_OUTPUTS})
 
 add_executable(conf ${conf_src})
 
 add_executable(conf ${conf_src})
index 60936c76865bfb07e6fb1f2767bc1514e69a6169..b3eff9613cf8e7d46be5449db5e7b8ece6343645 100644 (file)
@@ -727,5 +727,4 @@ void zconfdump(FILE *out)
        }
 }
 
        }
 }
 
-#include "util.c"
 #include "menu.c"
 #include "menu.c"