feat(build): add module_group and comment out arch_cflags
Signed-off-by: Caoruihong <crh.cao@huawei.com> Change-Id: I83a248d313ec64a5bca6eb860fb84385aac446a0
This commit is contained in:
parent
942c614995
commit
e5636f7aca
2
BUILD.gn
2
BUILD.gn
|
@ -207,7 +207,7 @@ config("misc_config") {
|
||||||
|
|
||||||
config("los_config") {
|
config("los_config") {
|
||||||
configs = [
|
configs = [
|
||||||
":arch_config",
|
#":arch_config",
|
||||||
":kconfig_config",
|
":kconfig_config",
|
||||||
|
|
||||||
#":stdinc_config",
|
#":stdinc_config",
|
||||||
|
|
25
liteos.gni
25
liteos.gni
|
@ -114,6 +114,28 @@ template("config") {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template("module_group") {
|
||||||
|
assert(defined(invoker.modules), "modules are must")
|
||||||
|
group(target_name) {
|
||||||
|
deps = []
|
||||||
|
foreach(m, invoker.modules) {
|
||||||
|
deps += [ m ]
|
||||||
|
}
|
||||||
|
if (defined(invoker.deps)) {
|
||||||
|
deps += invoker.deps
|
||||||
|
}
|
||||||
|
}
|
||||||
|
config("public") {
|
||||||
|
configs = []
|
||||||
|
foreach(m, invoker.modules) {
|
||||||
|
configs += [ "$m:public" ]
|
||||||
|
}
|
||||||
|
if (defined(invoker.configs)) {
|
||||||
|
configs += invoker.configs
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
set_defaults("kernel_module") {
|
set_defaults("kernel_module") {
|
||||||
configs = [
|
configs = [
|
||||||
"$LITEOSTOPDIR:public",
|
"$LITEOSTOPDIR:public",
|
||||||
|
@ -121,6 +143,7 @@ set_defaults("kernel_module") {
|
||||||
]
|
]
|
||||||
visibility = [
|
visibility = [
|
||||||
"$LITEOSTOPDIR/*",
|
"$LITEOSTOPDIR/*",
|
||||||
"../*",
|
"..:*",
|
||||||
|
":*",
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue