提交 a8805a65 编写于 作者: C Caoruihong

feat: add support for gn build system

add BUILD.gn for all kernel modules
Signed-off-by: NCaoruihong <crh.cao@huawei.com>
Change-Id: I018446427bf64615f2596d47862b219659b58b34
上级 7b7d64cc
......@@ -28,47 +28,308 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//build/lite/config/component/lite_component.gni")
import("//build/lite/config/subsystem/lite_subsystem.gni")
declare_args() {
tee_enable = false
}
LITEOS_MENUCONFIG_H = rebase_path("$root_out_dir/config.h")
tee = ""
if (tee_enable) {
tee = "_tee"
}
productName = get_path_info(product_path, "file")
config_file = "${productName}_release.config"
if (ohos_build_compiler == "clang") {
if (ohos_build_type == "debug") {
config_file = "debug/${productName}_${ohos_build_compiler}${tee}.config"
} else {
config_file = "${productName}_${ohos_build_compiler}_release${tee}.config"
}
} else if (ohos_build_compiler == "gcc") {
if (ohos_build_type == "debug") {
config_file = "${productName}_debug_shell${tee}.config"
} else {
config_file = "${productName}_release${tee}.config"
}
}
liteos_config_file = rebase_path("tools/build/config/$config_file")
# we prefer use product specified config file
f = "$product_path/config/${ohos_build_type}${tee}.config"
if (exec_script("//build/lite/run_shell_cmd.py", [ "if [ -f $f ]; then echo true; else echo false; fi" ], "value")) {
liteos_config_file = f
}
print("liteos_config_file:", liteos_config_file)
exec_script("//build/lite/run_shell_cmd.py", [ "which genconfig || pip install --user kconfiglib" ])
exec_script("//build/lite/run_shell_cmd.py",
[
"env" +
" CONFIG_=LOSCFG_" +
" KCONFIG_CONFIG_HEADER='y=true'" +
" KCONFIG_CONFIG=$liteos_config_file" +
" DEVICE_PATH=$device_path" +
" srctree=" + rebase_path(".") +
" genconfig" +
" --header-path $LITEOS_MENUCONFIG_H" +
" --file-list kconfig_files.txt" +
" --env-list kconfig_env.txt" +
" --config-out config.gni",
])
import("liteos.gni")
generate_notice_file("kernel_notice_file") {
module_name = "kernel"
module_source_dir_list = [
"//third_party/FreeBSD",
"//third_party/musl",
"//third_party/zlib",
"//third_party/FatFs",
"//third_party/Linux_Kernel",
"//third_party/lwip",
"//third_party/NuttX",
"//third_party/mtd-utils",
"$LITEOSTHIRDPARTY/FreeBSD",
"$LITEOSTHIRDPARTY/musl",
"$LITEOSTHIRDPARTY/zlib",
"$LITEOSTHIRDPARTY/FatFs",
"$LITEOSTHIRDPARTY/Linux_Kernel",
"$LITEOSTHIRDPARTY/lwip",
"$LITEOSTHIRDPARTY/NuttX",
"$LITEOSTHIRDPARTY/mtd-utils",
]
}
declare_args() {
enable_ohos_kernel_liteos_a_ext_build = true
LOSCFG_TEST_APPS = false
tee_enable = ""
}
lite_subsystem("kernel") {
subsystem_components = []
if (enable_ohos_kernel_liteos_a_ext_build == false) {
subsystem_components += [
"//kernel/liteos_a/kernel",
"//kernel/liteos_a/net",
"//kernel/liteos_a/lib",
"//kernel/liteos_a/compat",
"//kernel/liteos_a/fs",
"//kernel/liteos_a/arch:platform_cpu",
liteos_arch_cflags = []
if (defined(LOSCFG_ARCH_ARM)) {
mcpu = LOSCFG_ARCH_CPU
if (defined(LOSCFG_ARCH_ARM_AARCH64) && defined(LOSCFG_ARCH_FPU_DISABLE)) {
mcpu += "+nofp"
}
liteos_arch_cflags += [ "-mcpu=$mcpu" ]
if (defined(LOSCFG_ARCH_ARM_AARCH32)) {
liteos_arch_cflags += [
"-mfloat-abi=softfp",
"-mfpu=$LOSCFG_ARCH_FPU",
]
}
}
cc = "$ohos_current_cc_command " + string_join(" ", liteos_arch_cflags)
if (ohos_build_compiler == "clang") {
cc += " --target=$target_triple"
}
config("arch_config") {
cflags = liteos_arch_cflags
asmflags = cflags
ldflags = cflags
}
config("as_objs_libc_flags") {
defines = [ "__ASSEMBLY__" ]
# linux style macros
if (defined(LOSCFG_ARCH_ARM_V7A) || defined(LOSCFG_ARCH_ARM_V7R) ||
defined(LOSCFG_ARCH_ARM_V7M)) {
defines += [ "__LINUX_ARM_ARCH__=7" ]
} else if (defined(LOSCFG_ARCH_ARM_V8A) || defined(LOSCFG_ARCH_ARM_V8R) ||
defined(LOSCFG_ARCH_ARM_V8M)) {
defines += [ "__LINUX_ARM_ARCH__=8" ]
}
}
config("std_include") {
std_include = exec_script("//build/lite/run_shell_cmd.py", [ "$cc -print-file-name=include" ], "trim string")
include_dirs = [ std_include ]
}
config("public") {
configs = [
"arch:public",
"platform:public",
"kernel:public",
"compat:public",
"bsd:public",
"fs:public",
"drivers:public",
"security:public",
"net:public",
"shell:public",
"lib:public",
":std_include",
]
}
config("los_config") {
cflags = [
"-imacros",
"$LITEOS_MENUCONFIG_H",
]
defines = [ "__LITEOS__" ]
configs = [ ":arch_config" ]
ldflags = [ "-nostdlib" ]
cflags_c = [ "-std=c99" ]
cflags += [
"-fno-pic",
"-fno-builtin",
"-nostdinc",
"-Wall",
"-Werror",
"-fms-extensions",
"-Wno-address-of-packed-member",
"-fno-strict-aliasing",
"-fno-common",
"-fsigned-char",
"-Wpointer-arith",
"-Wstrict-prototypes",
"-Winvalid-pch",
"-ffunction-sections",
"-fdata-sections",
"-fno-exceptions",
"-fno-omit-frame-pointer",
"-fno-short-enums",
]
if (defined(LOSCFG_QUICK_START)) {
cflags -= [ "-Werror" ]
}
if (defined(LOSCFG_COMPILE_DEBUG)) {
cflags += [
"-O0",
"-g",
"-gdwarf-2",
]
if (LOSCFG_SHELL) {
subsystem_components += [ "//kernel/liteos_a/shell" ]
} else {
if (defined(LOSCFG_COMPILER_CLANG_LLVM)) {
cflags += [
"-Oz",
"-flto",
]
} else {
cflags += [ "-O2" ]
}
}
if (defined(LOSCFG_CC_STACKPROTECTOR_ALL)) {
cflags += [ "-fstack-protector-all" ]
} else if (defined(LOSCFG_CC_STACKPROTECTOR_STRONG)) {
cflags += [ "-fstack-protector-strong" ]
} else if (defined(LOSCFG_CC_STACKPROTECTOR)) {
cflags += [
"-fstack-protector",
"--param",
"ssp-buffer-size=4",
]
} else {
deps = [ ":make" ]
deps += [ "//kernel/liteos_a/testsuites/unittest:unittest" ]
cflags += [ "-fno-stack-protector" ]
}
if (!defined(LOSCFG_COMPILER_CLANG_LLVM)) {
cflags += [ "-fno-aggressive-loop-optimizations" ]
if (!defined(LOSCFG_ARCH_ARM_AARCH64)) {
cflags += [
"-mno-unaligned-access",
"-mthumb-interwork",
]
}
}
if (defined(LOSCFG_THUMB)) {
cflags += [
"-mthumb",
"-Wa,-mimplicit-it=thumb",
]
}
asmflags = cflags
}
liteos_name = "liteos2"
liteos_out = rebase_path("$target_out_dir/$liteos_name")
executable(liteos_name) {
configs = [] # clear default configs
configs += [ ":los_config" ]
ldflags = [
"-static",
"-Wl,--gc-sections",
"-Wl,-Map=" + rebase_path("$liteos_out.map"),
"-Wl,--no-eh-frame-hdr",
"-Wl,--whole-archive",
]
libgcc = exec_script("//build/lite/run_shell_cmd.py", [ "$cc -print-libgcc-file-name" ], "trim string")
libs = [ libgcc ]
if (defined(LOSCFG_COMPILER_CLANG_LLVM)) {
libs += [ "tools/build/liteos_llvm.ld" ]
} else {
libs += [ "tools/build/liteos.ld" ]
ldflags += [ "-nostartfiles" ]
}
deps = [
":modules",
]
}
build_ext_component("build_liteos_bin") {
deps = [ ":$liteos_name" ]
exec_path = rebase_path(target_out_dir)
objcopy = "${compile_prefix}objcopy$toolchain_cmd_suffix"
objdump = "${compile_prefix}objdump$toolchain_cmd_suffix"
liteos = rebase_path("$root_out_dir/unstripped/bin/$liteos_name")
command = "$objcopy -O binary $liteos $liteos_out.bin"
command += " && sh -c '$objdump -t $liteos | sort >$liteos_out.sym.sorted'"
command += " && sh -c '$objdump -d $liteos >$liteos_out.asm'"
}
group("modules") {
deps = [
"arch",
"bsd",
"compat",
"drivers",
"fs",
"kernel",
"lib",
"net",
"platform",
"security",
"shell",
"syscall",
]
}
group("apps") {
deps = [ "apps" ]
}
group("tests") {
deps = [ "testsuites" ]
}
group("kernel") {
deps = [
":make",
":tests",
]
}
group("liteos_a") {
deps = [
":apps",
":kernel",
":tests",
]
}
build_ext_component("make") {
......
......@@ -58,7 +58,7 @@ source "platform/Kconfig"
source "arch/Kconfig"
######################### config options of rootfs #####################
source "kernel/common/Kconfig"
source "kernel/common/rootfs/Kconfig"
######################### config options of patchfs #####################
source "kernel/common/patchfs/Kconfig"
######################### config options of blackbox #####################
......@@ -93,6 +93,7 @@ source "fs/romfs/Kconfig"
source "fs/nfs/Kconfig"
source "fs/proc/Kconfig"
source "fs/jffs2/Kconfig"
source "fs/zpfs/Kconfig"
config ENABLE_READ_BUFFER
bool "Enable read buffer Option"
default n
......@@ -163,9 +164,16 @@ config ENABLE_MAGICKEY
config THUMB
bool "Enable Thumb"
default n
select INTERWORK_THUMB
help
Answer Y to build thumb version. This will make LiteOS smaller.
config INTERWORK_THUMB
bool "Enable interwork Thumb" if THUMB
default n
help
Answer Y to enable interwork thumb.
config PLATFORM_DVFS
bool "Enable Dvfs"
default n
......@@ -295,8 +303,7 @@ source "bsd/dev/usb/Kconfig"
source "../../drivers/adapter/khdf/liteos/Kconfig"
# Device driver Kconfig import
osource "$(DEVICE_PATH)/Kconfig"
osource "$(DEVICE_PATH)/config/Kconfig"
osource "$(DEVICE_PATH)/drivers/Kconfig"
source "drivers/char/mem/Kconfig"
source "drivers/char/quickstart/Kconfig"
......
......@@ -51,13 +51,25 @@ LITEOS_PLATFORM_BASE = $(LITEOSTOPDIR)/platform
export CONFIG_=LOSCFG_
ifeq ($(PRODUCT_PATH),)
export PRODUCT_PATH=$(LITEOSTOPDIR)/../../device/hisilicon/drivers
export PRODUCT_PATH=$(shell hb env|grep "product path:"|sed 's/.*: //g')
endif
ifeq ($(DEVICE_PATH),)
export DEVICE_PATH=$(shell hb env|grep "device path:"|sed 's/.*: //g')
endif
ifeq ($(TEE:1=y),y)
tee = _tee
endif
ifeq ($(RELEASE:1=y),y)
CONFIG ?= $(PRODUCT_PATH)/config/release$(tee).config
else
CONFIG ?= $(PRODUCT_PATH)/config/debug$(tee).config
endif
ifeq ($(shell which menuconfig),)
$(shell pip install --user kconfiglib >/dev/null)
endif
$(shell env CONFIG_=$(CONFIG_) PRODUCT_PATH=$(PRODUCT_PATH) olddefconfig >/dev/null)
$(shell env CONFIG_=$(CONFIG_) DEVICE_PATH=$(DEVICE_PATH) olddefconfig >/dev/null)
-include $(LITEOSTOPDIR)/tools/build/config.mk
......@@ -217,7 +229,7 @@ update_all_config:
done
update_config:
$(HIDE)test -f "$(CONFIG)" && cp "$(CONFIG)" .config && menuconfig && savedefconfig --out "$(CONFIG)"
$(HIDE)test -f "$(CONFIG)" && cp -v "$(CONFIG)" .config && menuconfig && savedefconfig --out "$(CONFIG)"
.PHONY: all lib clean cleanall $(LITEOS_TARGET) debug release help update_all_config update_config
.PHONY: prepare sysroot cleanrootfs $(ROOTFS) $(ROOTFSDIR) $(APPS) menuconfig $(LITEOS_LIBS_TARGET) $(__LIBS) $(OUT)
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
group("apps") {
deps = []
if (defined(LOSCFG_SHELL)) {
deps += [
"shell",
#"mksh",
#"toybox",
]
}
if (defined(LOSCFG_USER_INIT_DEBUG)) {
#deps += [ "init" ]
}
if (defined(LOSCFG_NET_LWIP_SACK_TFTP)) {
deps += [ "tftp" ]
}
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
executable("init") {
sources = [ "src/init.c" ]
cflags = [ "-fPIE" ]
if (defined(LOSCFG_COMPILER_CLANG_LLVM)) {
cflags += [
"-Wno-shift-op-parentheses",
"-Wno-bitwise-op-parentheses",
"-Wnonnull",
]
}
ldflags = [
"-pie",
"-s",
]
if (defined(LOSCFG_QUICK_START)) {
ldflags += [ "--static" ]
}
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//build/lite/config/component/lite_component.gni")
import("//kernel/liteos_a/liteos.gni")
group("mksh") {
deps = [ ":build_mksh" ]
}
build_ext_component("build_mksh") {
exec_path = rebase_path(target_out_dir)
command = "make -C $LITEOSTHIRDPARTY/mksh"
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
executable("shell") {
sources = [
"builtin/cd.c",
"src/main.c",
"src/shcmd.c",
"src/shcmdparse.c",
"src/shmsg.c",
]
deps = [ "$LITEOSTHIRDPARTY/bounds_checking_function:libsec_static" ]
include_dirs = [ "include" ]
cflags = [ "-fPIE" ]
if (defined(LOSCFG_COMPILER_CLANG_LLVM)) {
cflags += [
"-Wno-shift-op-parentheses",
"-Wno-bitwise-op-parentheses",
]
}
ldflags = [
"-pie",
"-s",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
executable("tftp") {
sources = [
"src/main.c",
"src/tftpc.c",
]
deps = [ "$LITEOSTHIRDPARTY/bounds_checking_function:libsec_static" ]
include_dirs = [ "include" ]
cflags = [ "-fPIE" ]
if (defined(LOSCFG_COMPILER_CLANG_LLVM)) {
cflags += [
"-Wno-shift-op-parentheses",
"-Wno-bitwise-op-parentheses",
]
}
ldflags = [
"-pie",
"-s",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//build/lite/config/component/lite_component.gni")
import("//kernel/liteos_a/liteos.gni")
group("toybox") {
deps = [ ":build_toybox" ]
}
build_ext_component("build_toybox") {
exec_path = rebase_path(target_out_dir)
command = "make -C $LITEOSTHIRDPARTY/toybox"
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
group("arch") {
deps = []
if (defined(LOSCFG_ARCH_ARM)) {
deps += [ "arm" ]
}
}
config("public") {
configs = []
if (defined(LOSCFG_ARCH_ARM)) {
configs += [ "arm:public" ]
}
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
group("arm") {
deps = [ "gic" ]
if (defined(LOSCFG_ARCH_ARM_AARCH32)) {
deps += [ "arm" ]
}
}
config("public") {
include_dirs = [ "include" ]
configs = []
if (defined(LOSCFG_ARCH_ARM_AARCH32)) {
configs += [ "arm:public" ]
} else if (defined(LOSCFG_ARCH_ARM_AARCH64)) {
configs += [ "aarch64:public" ]
}
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_name = LOSCFG_ARCH_CPU
kernel_module(module_name) {
sources = [
"src/arm_generic_timer.c",
"src/clear_user.S",
"src/hw_user_get.S",
"src/hw_user_put.S",
"src/jmp.S",
"src/los_arch_mmu.c",
"src/los_asid.c",
"src/los_dispatch.S",
"src/los_exc.c",
"src/los_hw.c",
"src/los_hw_exc.S",
"src/los_hw_runstop.S",
"src/los_hw_tick.c",
"src/los_hwi.c",
"src/strncpy_from_user.c",
"src/strnlen_user.c",
"src/user_copy.c",
]
if (LOSCFG_ARCH_ARM_VER == "armv7-a") {
sources += [ "src/armv7a/cache.S" ]
}
if (defined(LOSCFG_KERNEL_SMP)) {
sources += [ "src/startup/reset_vector_mp.S" ]
} else {
sources += [ "src/startup/reset_vector_up.S" ]
}
include_dirs = [ "src/include" ]
if (defined(LOSCFG_GDB)) {
configs += [ "$LITEOSTOPDIR:as_objs_libc_flags" ]
}
public_configs = [ ":public" ]
}
group("arm") {
public_deps = [ ":$module_name" ]
}
config("public") {
include_dirs = [
"include",
"src/include",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = []
if (defined(LOSCFG_ARCH_GIC_V2)) {
sources += [ "gic_v2.c" ]
} else if (defined(LOSCFG_ARCH_GIC_V3)) {
sources += [ "gic_v3.c" ]
}
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_COMPAT_BSD)
module_name = "libbsd"
kernel_module(module_name) {
sources = [
"kern/bus_if.c",
"kern/device_if.c",
"kern/kern_condvar.c",
"kern/kern_timeout.c",
"kern/subr_bus.c",
"kern/subr_kobj.c",
]
if (defined(LOSCFG_ARCH_ARM_AARCH32)) {
sources += [
"arm/autoconf.c",
"arm/hw_user_copy.S",
"arm/in_cksum.c",
"arm/in_cksum_arm.S",
"arm/nexus.c",
]
}
if (defined(LOSCFG_DRIVERS_RANDOM)) {
sources += [
"crypto/rijndael/rijndael-alg-fst.c",
"crypto/rijndael/rijndael-api-fst.c",
"crypto/sha2/sha256c.c",
"dev/random/hash.c",
"dev/random/yarrow.c",
"libkern/explicit_bzero.c",
]
}
public_configs = [ ":public" ]
}
group("bsd") {
public_deps = [ ":$module_name" ]
deps = [
"compat/linuxkpi",
"dev/usb",
]
}
config("public") {
include_dirs = [
".",
"kern",
]
configs = [
"compat/linuxkpi:public",
"dev/usb:public",
]
}
config COMPAT_BSD
bool "Enable FreeBSD"
default y
select COMPAT_LINUXKPI
help
Answer Y to enable LiteOS support FreeBSD.
config COMPAT_LINUXKPI
bool "Enable linuxkpi" if COMPAT_BSD
default y
help
Answer Y to enable LiteOS support compatible layer for linuxkpi.
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_COMPAT_BSD)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/adp.c",
"src/linux_completion.c",
"src/linux_interrupt.c",
"src/linux_sched.c",
"src/linux_semaphore.c",
"src/linux_timer.c",
"src/linux_wakelock.c",
"src/linux_workqueue.c",
"src/prctl.c",
"src/tzdst.c",
]
if (defined(LOSCFG_HRTIMER_ENABLE)) {
sources += [ "src/linux_hrtimer.c" ]
}
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_DRIVERS_USB)
module_name = "usb_base"
kernel_module(module_name) {
sources = [
"implementation/bsd_busspace.c",
"implementation/bsd_kernel.c",
"implementation/usb_btree.c",
"implementation/usb_busdma_loader.c",
"implementation/usb_init.c",
"implementation/usb_version.c",
"usb_debug.c",
]
if (defined(LOSCFG_DRIVERS_USB)) {
sources += [
"controller/usb_controller.c",
"quirk/usb_quirk.c",
"usb_dev.c",
"usb_device.c",
"usb_dynamic.c",
"usb_error.c",
"usb_generic.c",
"usb_handle_request.c",
"usb_hub.c",
"usb_if.c",
"usb_lookup.c",
"usb_mbuf.c",
"usb_parse.c",
"usb_process.c",
"usb_request.c",
"usb_transfer.c",
"usb_util.c",
]
}
if (defined(LOSCFG_DRIVERS_USB_4G_MODEM)) {
sources += [ "net/if_cdce.c" ]
}
if (defined(LOSCFG_DRIVERS_USB_ETHERNET)) {
sources += [
"net/if_axe.c",
"net/if_axge.c",
]
}
if (defined(LOSCFG_DRIVERS_USB_RNDIS_HOST)) {
sources += [ "net/if_urndis.c" ]
}
if (defined(LOSCFG_DRIVERS_USB_4G_MODEM) ||
defined(LOSCFG_DRIVERS_USB_ETHERNET) ||
defined(LOSCFG_DRIVERS_USB_RNDIS_HOST)) {
sources += [
"net/usb_eth_drv.c",
"net/usb_ethernet.c",
]
}
if (defined(LOSCFG_DRIVERS_USB_4G_MODEM) ||
defined(LOSCFG_DRIVERS_USB_SERIAL)) {
sources += [
"serial/u3g.c",
"serial/usb_serial.c",
]
}
if (defined(LOSCFG_DRIVERS_USB_HOST_EHCI)) {
sources += [
"controller/ehci.c",
"controller/ehci_pci.c",
]
}
if (defined(LOSCFG_DRIVERS_USB_HOST_XHCI) ||
defined(LOSCFG_DRIVERS_USB_HOST_XHCI_FOR_PORT2)) {
sources += [
"controller/xhci.c",
"controller/xhci_pci.c",
]
}
if (defined(LOSCFG_DRIVERS_USB_WIRELESS)) {
sources += [ "linux_usb.c" ]
}
if (defined(LOSCFG_DRIVERS_USB_MASS_STORAGE)) {
sources += [ "storage/umass.c" ]
}
if (defined(LOSCFG_DRIVERS_USB_HID_CLASS) &&
defined(LOSCFG_DRIVERS_HDF_INPUT)) {
sources += [
"input/uhid.c",
"usb_hid.c",
]
include_dirs = [
"//drivers/framework/model/input/driver",
"//drivers/framework/include/core",
"//drivers/framework/core/common/include/host",
"//drivers/framework/utils",
"//drivers/framework/osal",
"//drivers/framework/ability/sbuf/include",
"//drivers/framework/include/osal",
]
}
configs += [
"$HDFTOPDIR:hdf_config"
]
public_configs = [ ":public" ]
}
group("usb") {
public_deps = [ ":$module_name" ]
}
config("public") {
include_dirs = [ "." ]
include_dirs += [ "$LITEOSTHIRDPARTY/FreeBSD/sys/dev/evdev" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
group("compat") {
deps = [ "posix" ]
}
config("public") {
configs = [ "posix:public" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_COMPAT_POSIX)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/map_error.c",
"src/misc.c",
"src/mqueue.c",
"src/posix_memalign.c",
"src/pthread.c",
"src/pthread_attr.c",
"src/pthread_cond.c",
"src/pthread_mutex.c",
"src/sched.c",
"src/semaphore.c",
"src/socket.c",
"src/time.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
cmd = "if [ -f $device_path/drivers/BUILD.gn ]; then echo true; else echo false; fi"
HAVE_DEVICE_DRIVERS = exec_script("//build/lite/run_shell_cmd.py", [ cmd ], "value")
module_switch = defined(LOSCFG_DRIVERS)
group("drivers") {
if (module_switch) {
deps = [
"block/disk",
"char/bch",
"char/mem",
"char/quickstart",
"char/random",
"char/video",
"mtd/multi_partition",
"//drivers/adapter/khdf/liteos",
"//drivers/liteos",
]
if (HAVE_DEVICE_DRIVERS) {
deps += [ "$device_path/drivers" ]
}
}
}
config("public") {
configs = [
"block/disk:public",
"char/bch:public",
"char/mem:public",
"char/quickstart:public",
"char/random:public",
"char/video:public",
"mtd/multi_partition:public",
"//drivers/adapter/khdf/liteos:public",
"//drivers/liteos:public",
]
if (HAVE_DEVICE_DRIVERS) {
configs += [ "$device_path/drivers:public" ]
}
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_FAT_DISK)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/disk.c",
"src/disk_shellcmd.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_VFS_BLOCK_DEVICE)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"$LITEOSTHIRDPARTY/NuttX/drivers/bch/bchdev_driver.c",
"$LITEOSTHIRDPARTY/NuttX/drivers/bch/bchdev_register.c",
"$LITEOSTHIRDPARTY/NuttX/drivers/bch/bchdev_unregister.c",
"$LITEOSTHIRDPARTY/NuttX/drivers/bch/bchlib_cache.c",
"$LITEOSTHIRDPARTY/NuttX/drivers/bch/bchlib_read.c",
"$LITEOSTHIRDPARTY/NuttX/drivers/bch/bchlib_sem.c",
"$LITEOSTHIRDPARTY/NuttX/drivers/bch/bchlib_setup.c",
"$LITEOSTHIRDPARTY/NuttX/drivers/bch/bchlib_teardown.c",
"$LITEOSTHIRDPARTY/NuttX/drivers/bch/bchlib_write.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_DRIVERS_MEM)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "src/mem.c" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_DRIVERS_QUICKSTART)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "src/quickstart.c" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_DRIVERS_RANDOM)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "src/random.c" ]
if (defined(LOSCFG_HW_RANDOM_ENABLE)) {
sources += [ "src/random_hw.c" ]
}
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_DRIVERS_VIDEO)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "$LITEOSTHIRDPARTY/NuttX/drivers/video/fb.c" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "$LITEOSTHIRDPARTY/NuttX/include/nuttx/video" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_VFS)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/mtd_partition.c",
"src/mtd_shellcmd.c",
]
include_dirs = [
"$LITEOSTOPDIR/fs/jffs2/include",
"//device/hisilicon/drivers/include/mtd/common/include",
]
if (defined(LOSCFG_PLATFORM_QEMU_ARM_VIRT_CA7)) {
include_dirs += [ "//device/qemu/drivers/cfiflash" ]
}
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
group("fs") {
deps = [
"fat",
"fat/virpart",
"jffs2",
"nfs",
"proc",
"ramfs",
"romfs",
"vfs",
"vfs/bcache",
"zpfs",
]
}
config("public") {
include_dirs = [ "include" ]
configs = [
"vfs:public",
"vfs/bcache:public",
"fat:public",
"fat/virpart:public",
"proc:public",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_FAT)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"os_adapt/fat_shellcmd.c",
"os_adapt/fatfs.c",
"os_adapt/format.c",
]
sources += [
"$LITEOSTHIRDPARTY/FatFs/source/diskio.c",
"$LITEOSTHIRDPARTY/FatFs/source/ff.c",
"$LITEOSTHIRDPARTY/FatFs/source/ffsystem.c",
"$LITEOSTHIRDPARTY/FatFs/source/ffunicode.c",
]
include_dirs = [ "os_adapt" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "$LITEOSTHIRDPARTY/FatFs/source" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_FAT_VIRTUAL_PARTITION)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/virpart.c",
"src/virpartff.c",
]
include_dirs = [ "../os_adapt" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_JFFS)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/jffs2_hash.c",
"src/vfs_jffs2.c",
]
sources += [
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/background.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/build.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/compr.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/compr_rtime.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/compr_rubin.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/compr_zlib.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/debug.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/dir.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/erase.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/file.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/fs.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/gc.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/malloc.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/nodelist.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/nodemgmt.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/read.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/readinode.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/scan.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/summary.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/super.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/write.c",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2/writev.c",
]
include_dirs = [
"$LITEOSTHIRDPARTY/Linux_Kernel/fs/jffs2",
"$LITEOSTHIRDPARTY/Linux_Kernel/fs",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_NFS)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"$LITEOSTHIRDPARTY/NuttX/fs/nfs/nfs_adapter.c",
"$LITEOSTHIRDPARTY/NuttX/fs/nfs/nfs_util.c",
"$LITEOSTHIRDPARTY/NuttX/fs/nfs/rpc_clnt.c",
]
}
......@@ -25,23 +25,31 @@
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
static_library("fs_proc") {
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_PROC)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"os_adapt/fd_proc.c",
"os_adapt/fs_cache_proc.c",
"os_adapt/kernel_trace_proc.c",
"os_adapt/mounts_proc.c",
"os_adapt/power_proc.c",
"os_adapt/proc_init.c",
"os_adapt/vfs_proc.c",
"os_adapt/proc_vfs.c",
"os_adapt/process_proc.c",
"os_adapt/uptime_proc.c",
"os_adapt/vmm_proc.c",
"src/proc_file.c",
"src/proc_shellcmd.c",
"src/pseudofs.c",
"src/seq_file.c",
]
include_dirs = [ "include" ]
public_configs = [ ":public" ]
}
if (LOSCFG_LLTREPORT) {
cflags += [
"-fprofile-arcs",
"-ftest-coverage",
]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_RAMFS)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "$LITEOSTHIRDPARTY/NuttX/fs/tmpfs/fs_tmpfs.c" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_ROMFS)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"$LITEOSTHIRDPARTY/NuttX/fs/romfs/fs_romfs.c",
"$LITEOSTHIRDPARTY/NuttX/fs/romfs/fs_romfsutil.c",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_VFS)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"operation/fs_chattr.c",
"operation/fs_check.c",
"operation/fs_fallocate.c",
"operation/fs_fallocate64.c",
"operation/fs_file.c",
"operation/fs_file_mapping.c",
"operation/fs_init.c",
"operation/fs_other.c",
"operation/fs_preadv.c",
"operation/fs_pwritev.c",
"operation/fs_readv.c",
"operation/fs_utime.c",
"operation/fs_writev.c",
"operation/fullpath.c",
"vfs_cmd/vfs_shellcmd.c",
]
sources += [
"$LITEOSTHIRDPARTY/NuttX/fs/dirent/fs_closedir.c",
"$LITEOSTHIRDPARTY/NuttX/fs/dirent/fs_opendir.c",
"$LITEOSTHIRDPARTY/NuttX/fs/dirent/fs_readdir.c",
"$LITEOSTHIRDPARTY/NuttX/fs/dirent/fs_rewinddir.c",
"$LITEOSTHIRDPARTY/NuttX/fs/dirent/fs_seekdir.c",
"$LITEOSTHIRDPARTY/NuttX/fs/dirent/fs_telldir.c",
"$LITEOSTHIRDPARTY/NuttX/fs/driver/fs_blockproxy.c",
"$LITEOSTHIRDPARTY/NuttX/fs/driver/fs_closeblockdriver.c",
"$LITEOSTHIRDPARTY/NuttX/fs/driver/fs_findblockdriver.c",
"$LITEOSTHIRDPARTY/NuttX/fs/driver/fs_openblockdriver.c",
"$LITEOSTHIRDPARTY/NuttX/fs/driver/fs_registerblockdriver.c",
"$LITEOSTHIRDPARTY/NuttX/fs/driver/fs_registerdriver.c",
"$LITEOSTHIRDPARTY/NuttX/fs/driver/fs_unregisterblockdriver.c",
"$LITEOSTHIRDPARTY/NuttX/fs/driver/fs_unregisterdriver.c",
"$LITEOSTHIRDPARTY/NuttX/fs/inode/fs_files.c",
"$LITEOSTHIRDPARTY/NuttX/fs/mount/fs_foreachmountpoint.c",
"$LITEOSTHIRDPARTY/NuttX/fs/mount/fs_mount.c",
"$LITEOSTHIRDPARTY/NuttX/fs/mount/fs_umount.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_close.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_dup.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_dup2.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_dupfd.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_dupfd2.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_fcntl.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_fsync.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_getfilep.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_ioctl.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_link.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_lseek.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_lseek64.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_mkdir.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_open.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_poll.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_pread.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_pread64.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_pwrite.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_pwrite64.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_read.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_readlink.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_rename.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_rmdir.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_select.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_sendfile.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_stat.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_statfs.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_symlink.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_truncate.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_truncate64.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_unlink.c",
"$LITEOSTHIRDPARTY/NuttX/fs/vfs/fs_write.c",
"$LITEOSTOPDIR/fs/vfs/mount.c",
"$LITEOSTOPDIR/fs/vfs/path_cache.c",
"$LITEOSTOPDIR/fs/vfs/vnode.c",
"$LITEOSTOPDIR/fs/vfs/vnode_hash.c",
]
include_dirs = [ "$LITEOSTOPDIR/syscall" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_FAT_CACHE)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "src/bcache.c" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "../include/bcache" ]
}
......@@ -27,16 +27,13 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
static_library("fs_zpfs") {
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_FS_ZPFS)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"vfs_zpfs.c",
"zpfs.c",
]
if (LOSCFG_LLTREPORT) {
cflags += [
"-fprofile-arcs",
"-ftest-coverage",
]
}
}
......@@ -25,32 +25,24 @@
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//build/lite/config/component/lite_component.gni")
import("//kernel/liteos_a/liteos.gni")
lite_component("kernel") {
features = [
group("kernel") {
deps = [
"base",
"syscall",
"common",
"extended",
"user",
]
if (LOSCFG_KERNEL_CPUP) {
features += [ "extended/cpup" ]
}
if (LOSCFG_KERNEL_MPU) {
features += [ "extended/mpu" ]
}
if (LOSCFG_KERNEL_CPPSUPPORT) {
features += [ "extended/cppsupport" ]
}
if (LOSCFG_KERNEL_DYNLOAD) {
features += [ "extended/dynload" ]
}
if (LOSCFG_KERNEL_TRACE) {
features += [ "extended/trace" ]
}
if (LOSCFG_KERNEL_VDSO) {
features += [ "extended/vdso" ]
}
}
config("public") {
include_dirs = [ "include" ]
configs = [
"base:public",
"common:public",
"extended:public",
]
}
......@@ -25,9 +25,12 @@
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
static_library("base") {
import("//kernel/liteos_a/liteos.gni")
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"core/los_bitmap.c",
"core/los_process.c",
......@@ -36,22 +39,24 @@ static_library("base") {
"core/los_sys.c",
"core/los_task.c",
"core/los_tick.c",
"core/los_timeslice.c",
"ipc/los_event.c",
"ipc/los_futex.c",
"ipc/los_ipcdebug.c",
"ipc/los_mux.c",
"ipc/los_mux_debug.c",
"ipc/los_queue.c",
"ipc/los_queue_debug.c",
"ipc/los_rwlock.c",
"ipc/los_sem.c",
"ipc/los_sem_debug.c",
"mem/bestfit/los_memory.c",
"mem/bestfit/los_multipledlinkhead.c",
"ipc/los_signal.c",
"mem/common/los_memstat.c",
"mem/membox/los_membox.c",
"mem/tlsf/los_memory.c",
"misc/kill_shellcmd.c",
"misc/los_misc.c",
"misc/los_stackinfo.c",
"misc/mempt_shellcmd.c",
"misc/panic_shellcmd.c",
"misc/swtmr_shellcmd.c",
"misc/sysinfo_shellcmd.c",
"misc/task_shellcmd.c",
......@@ -59,22 +64,33 @@ static_library("base") {
"mp/los_lockdep.c",
"mp/los_mp.c",
"mp/los_percpu.c",
"mp/los_spinlock.c",
"mp/los_stat.c",
"om/los_err.c",
"sched/sched_sq/los_priqueue.c",
"sched/sched_sq/los_sched.c",
"vm/filemap.c",
"vm/pmm.c",
"vm/vm.c",
"vm/vmm.c",
"vm/los_vm_boot.c",
"vm/los_vm_dump.c",
"vm/los_vm_fault.c",
"vm/los_vm_filemap.c",
"vm/los_vm_iomap.c",
"vm/los_vm_map.c",
"vm/los_vm_page.c",
"vm/los_vm_phys.c",
"vm/los_vm_scan.c",
"vm/los_vm_syscall.c",
"vm/oom.c",
"vm/shm.c",
]
include_dirs = [
"include",
"../extended/include",
"../extended/vdso/include",
"../extended/dynload/include",
"../include",
"mem",
]
if (defined(LOSCFG_SHELL_CMD_DEBUG)) {
configs += [
"$HDFTOPDIR:hdf_config"
]
}
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
......@@ -35,7 +35,6 @@
#include "shell.h"
#endif
#include "los_swtmr_pri.h"
#include "watchdog_if.h"
#ifdef LOSCFG_SHELL_CMD_DEBUG
......@@ -46,6 +45,7 @@ LITE_OS_SEC_TEXT_MINOR BOOL OsSystemExcIsReset(VOID)
return systemExcReset;
}
#ifdef LOSCFG_DRIVERS_HDF_PLATFORM_WATCHDOG
#include "watchdog_if.h"
#define WATCHDOG_TIMER_INTERVAL 5 // 5 seconds
#define WATCHDOG_TIMER_INTERVAL_HALF (WATCHDOG_TIMER_INTERVAL / 2)
......
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
group("common") {
deps = [
"blackbox",
"hidumper",
"patchfs",
"rootfs",
]
}
config("public") {
configs = [
"blackbox:public",
"hidumper:public",
"patchfs:public",
"rootfs:public",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_BLACKBOX)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"los_blackbox_common.c",
"los_blackbox_core.c",
"los_blackbox_detector.c",
"los_blackbox_system_adapter.c",
]
include_dirs = [ "$LITEOSTOPDIR/syscall" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "." ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_HIDUMPER)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "los_hidumper.c" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "." ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_PLATFORM_PATCHFS)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"los_partition_utils.c",
"los_patchfs.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "." ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_PLATFORM_ROOTFS)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"los_bootargs.c",
"los_rootfs.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "." ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
group("extended") {
deps = [
"cppsupport",
"cpup",
"dynload",
"hilog",
"liteipc",
"pipes",
"power",
"trace",
"vdso",
]
}
config("public") {
configs = [
"cpup:public",
"dynload:public",
"vdso:public",
"trace:public",
"liteipc:public",
"pipes:public",
"hilog:public",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_KERNEL_CPPSUPPORT)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "los_cppsupport.c" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_KERNEL_CPUP)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"cpup_shellcmd.c",
"los_cpup.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "." ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_KERNEL_DYNLOAD)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/los_exec_elf.c",
"src/los_load_elf.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_BASE_CORE_HILOG)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "//base/hiviewdfx/hilog_lite/frameworks/featured/hiview_log.c" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [
"//base/hiviewdfx/hilog_lite/interfaces/native/kits",
"//base/hiviewdfx/hilog_lite/interfaces/native/kits/hilog",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_KERNEL_LITEIPC)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "hm_liteipc.c" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "." ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_KERNEL_PM)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [ "los_pm.c" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_KERNEL_TRACE)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"los_trace.c",
"los_trace_frame.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "." ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_KERNEL_VDSO)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/los_vdso.c",
"src/los_vdso_text.S",
]
asmflags = [ "-DOHOS_VDSO_SO=\"OHOS-vdso.so\"" ]
deps = [ ":copy_ohos_vdso" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
copy("copy_ohos_vdso") {
deps = [ "usr:OHOS-vdso" ]
sources = [ "$root_out_dir/libOHOS-vdso.so" ]
outputs = [ "$root_out_dir/OHOS-vdso.so" ]
}
......@@ -35,6 +35,6 @@ LOCAL_SRCS := $(wildcard *.c) $(wildcard *.S)
LOCAL_INCLUDE := -I $(LITEOSTOPDIR)/kernel/base/include -I $(LITEOSTOPDIR)/kernel/extended/include -I $(LITEOSTOPDIR)/kernel/extended/vdso/include
LOCAL_FLAGS := $(LOCAL_INCLUDE)
LOCAL_FLAGS := $(LOCAL_INCLUDE) -DOHOS_VDSO_SO=\"../usr/OHOS-vdso.so\"
include $(MODULE)
\ No newline at end of file
......@@ -31,4 +31,4 @@
.globl __vdso_text_start
.section .data.vdso.text
__vdso_text_start:
.incbin "../usr/OHOS-vdso.so"
\ No newline at end of file
.incbin OHOS_VDSO_SO
\ No newline at end of file
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
shared_library("OHOS-vdso") {
sources = [ "los_vdso_sys.c" ]
include_dirs = [
"$LITEOSTOPDIR/kernel/extended/vdso/include",
"$LITEOSTOPDIR/kernel/include",
"$LITEOSTOPDIR/platform",
"$LITEOSTOPDIR/bsd/compat/linuxkpi/include",
]
cflags = [
"-nostdlib",
"-fPIC",
"-fno-common",
"-fno-strict-aliasing",
]
ldflags = [
"-s",
"-Bsymbolic",
"-Tlos_vdso.ld",
]
}
......@@ -34,7 +34,7 @@ VDSO_SO = OHOS-vdso
VDSO_SRCS := los_vdso_sys.c
VDSO_INCLUDE := -I $(LITEOSTOPDIR)/kernel/extended/vdso/include \
-I $(LITEOSTOPDIR)/kernel/include \
-I $(LITEOSTOPDIR)/kernel/common \
-I $(LITEOSTOPDIR)/platform \
-I $(LITEOSTOPDIR)/bsd/compat/linuxkpi/include
VDSO_CCFLAGS := -nostdlib -fPIC -fno-common -fno-strict-aliasing \
......
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_name = "userinit"
shared_library(module_name) {
sources = [ "src/los_user_init.c" ]
include_dirs = [
"include",
"$LITEOSTOPDIR/syscall",
]
configs = []
configs += [
"$LITEOSTOPDIR:public",
"$LITEOSTOPDIR:los_config",
]
ldflags = [
"-static",
"-r",
]
output_extension = "O"
}
group("user") {
public_deps = [ ":$module_name" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
group("lib") {
deps = [
"libc",
"libmbedtls",
"libscrew",
"libsec",
"zlib",
]
}
config("public") {
configs = [
"libc:public",
"libmbedtls:public",
"libscrew:public",
"libsec:public",
"zlib:public",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
MUSLDIR = "$LITEOSTHIRDPARTY/musl"
OPTRTDIR = "$LITEOSTHIRDPARTY/optimized-routines"
import("$MUSLDIR/porting/liteos_a/kernel/musl.gni")
module_switch = defined(LOSCFG_LIB_LIBC)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = MUSL_SRC_COMMON
if (defined(LOSCFG_ARCH_ARM_AARCH32)) {
sources += MUSL_SRC_ARM
foreach(f, MUSL_SRC_ARM) {
sources -= [ string_replace(f, "/arm/", "/") ]
}
}
if (LOSCFG_ARCH_ARM_VER == "armv7-a") {
sources -= [
"$MUSLPORTINGDIR/src/string/memchr.c",
"$MUSLPORTINGDIR/src/string/memcpy.c",
"$MUSLPORTINGDIR/src/string/strcmp.c",
"$MUSLPORTINGDIR/src/string/strcpy.c",
"$MUSLPORTINGDIR/src/string/strlen.c",
]
sources += [
"$OPTRTDIR/string/arm/memchr.S",
"$OPTRTDIR/string/arm/memcpy.S",
"$OPTRTDIR/string/arm/strcmp.S",
"$OPTRTDIR/string/arm/strcpy.c",
"$OPTRTDIR/string/arm/strlen-armv6t2.S",
]
}
public_configs = [ ":public" ]
configs += [ ":private" ]
}
config("public") {
include_dirs = [ "$MUSLPORTINGDIR/include" ]
}
config("private") {
if (defined(LOSCFG_COMPILER_CLANG_LLVM)) {
cflags = [
"-Wno-char-subscripts",
"-Wno-unknown-pragmas",
]
} else {
cflags = [
"-frounding-math",
"-Wno-unused-but-set-variable",
"-Wno-unknown-pragmas",
]
}
include_dirs = [
"$MUSLPORTINGDIR/src/include",
"$MUSLPORTINGDIR/src/internal",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_DRIVERS_TZDRIVER)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"$LITEOSTHIRDPARTY/mbedtls/library/aes.c",
"$LITEOSTHIRDPARTY/mbedtls/library/aesni.c",
"$LITEOSTHIRDPARTY/mbedtls/library/arc4.c",
"$LITEOSTHIRDPARTY/mbedtls/library/aria.c",
"$LITEOSTHIRDPARTY/mbedtls/library/asn1parse.c",
"$LITEOSTHIRDPARTY/mbedtls/library/asn1write.c",
"$LITEOSTHIRDPARTY/mbedtls/library/base64.c",
"$LITEOSTHIRDPARTY/mbedtls/library/bignum.c",
"$LITEOSTHIRDPARTY/mbedtls/library/blowfish.c",
"$LITEOSTHIRDPARTY/mbedtls/library/camellia.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ccm.c",
"$LITEOSTHIRDPARTY/mbedtls/library/certs.c",
"$LITEOSTHIRDPARTY/mbedtls/library/chacha20.c",
"$LITEOSTHIRDPARTY/mbedtls/library/chachapoly.c",
"$LITEOSTHIRDPARTY/mbedtls/library/cipher.c",
"$LITEOSTHIRDPARTY/mbedtls/library/cipher_wrap.c",
"$LITEOSTHIRDPARTY/mbedtls/library/cmac.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ctr_drbg.c",
"$LITEOSTHIRDPARTY/mbedtls/library/debug.c",
"$LITEOSTHIRDPARTY/mbedtls/library/des.c",
"$LITEOSTHIRDPARTY/mbedtls/library/dhm.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ecdh.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ecdsa.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ecjpake.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ecp.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ecp_curves.c",
"$LITEOSTHIRDPARTY/mbedtls/library/entropy.c",
"$LITEOSTHIRDPARTY/mbedtls/library/entropy_poll.c",
"$LITEOSTHIRDPARTY/mbedtls/library/error.c",
"$LITEOSTHIRDPARTY/mbedtls/library/gcm.c",
"$LITEOSTHIRDPARTY/mbedtls/library/havege.c",
"$LITEOSTHIRDPARTY/mbedtls/library/hkdf.c",
"$LITEOSTHIRDPARTY/mbedtls/library/hmac_drbg.c",
"$LITEOSTHIRDPARTY/mbedtls/library/md.c",
"$LITEOSTHIRDPARTY/mbedtls/library/md2.c",
"$LITEOSTHIRDPARTY/mbedtls/library/md4.c",
"$LITEOSTHIRDPARTY/mbedtls/library/md5.c",
"$LITEOSTHIRDPARTY/mbedtls/library/md_wrap.c",
"$LITEOSTHIRDPARTY/mbedtls/library/memory_buffer_alloc.c",
"$LITEOSTHIRDPARTY/mbedtls/library/net_sockets.c",
"$LITEOSTHIRDPARTY/mbedtls/library/nist_kw.c",
"$LITEOSTHIRDPARTY/mbedtls/library/oid.c",
"$LITEOSTHIRDPARTY/mbedtls/library/padlock.c",
"$LITEOSTHIRDPARTY/mbedtls/library/pem.c",
"$LITEOSTHIRDPARTY/mbedtls/library/pk.c",
"$LITEOSTHIRDPARTY/mbedtls/library/pk_wrap.c",
"$LITEOSTHIRDPARTY/mbedtls/library/pkcs11.c",
"$LITEOSTHIRDPARTY/mbedtls/library/pkcs12.c",
"$LITEOSTHIRDPARTY/mbedtls/library/pkcs5.c",
"$LITEOSTHIRDPARTY/mbedtls/library/pkparse.c",
"$LITEOSTHIRDPARTY/mbedtls/library/pkwrite.c",
"$LITEOSTHIRDPARTY/mbedtls/library/platform.c",
"$LITEOSTHIRDPARTY/mbedtls/library/platform_util.c",
"$LITEOSTHIRDPARTY/mbedtls/library/poly1305.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ripemd160.c",
"$LITEOSTHIRDPARTY/mbedtls/library/rsa.c",
"$LITEOSTHIRDPARTY/mbedtls/library/rsa_internal.c",
"$LITEOSTHIRDPARTY/mbedtls/library/sha1.c",
"$LITEOSTHIRDPARTY/mbedtls/library/sha256.c",
"$LITEOSTHIRDPARTY/mbedtls/library/sha512.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ssl_cache.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ssl_ciphersuites.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ssl_cli.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ssl_cookie.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ssl_srv.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ssl_ticket.c",
"$LITEOSTHIRDPARTY/mbedtls/library/ssl_tls.c",
"$LITEOSTHIRDPARTY/mbedtls/library/threading.c",
"$LITEOSTHIRDPARTY/mbedtls/library/timing.c",
"$LITEOSTHIRDPARTY/mbedtls/library/version.c",
"$LITEOSTHIRDPARTY/mbedtls/library/version_features.c",
"$LITEOSTHIRDPARTY/mbedtls/library/x509.c",
"$LITEOSTHIRDPARTY/mbedtls/library/x509_create.c",
"$LITEOSTHIRDPARTY/mbedtls/library/x509_crl.c",
"$LITEOSTHIRDPARTY/mbedtls/library/x509_crt.c",
"$LITEOSTHIRDPARTY/mbedtls/library/x509_csr.c",
"$LITEOSTHIRDPARTY/mbedtls/library/x509write_crt.c",
"$LITEOSTHIRDPARTY/mbedtls/library/x509write_csr.c",
"$LITEOSTHIRDPARTY/mbedtls/library/xtea.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "$LITEOSTHIRDPARTY/mbedtls/include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/los_crc32.c",
"src/los_rbtree.c",
]
sources += [ "$LITEOSTHIRDPARTY/FreeBSD/sys/libkern/crc32.c" ]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_LIB_LIBC)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"$LITEOSTHIRDPARTY/bounds_checking_function/src/fscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/fwscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/gets_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/memcpy_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/memmove_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/memset_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/scanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/securecutil.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/secureinput_a.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/secureinput_w.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/secureprintoutput_a.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/secureprintoutput_w.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/snprintf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/sprintf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/sscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/strcat_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/strcpy_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/strncat_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/strncpy_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/strtok_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/swprintf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/swscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/vfscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/vfwscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/vscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/vsnprintf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/vsprintf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/vsscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/vswprintf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/vswscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/vwscanf_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/wcscat_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/wcscpy_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/wcsncat_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/wcsncpy_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/wcstok_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/wmemcpy_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/wmemmove_s.c",
"$LITEOSTHIRDPARTY/bounds_checking_function/src/wscanf_s.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "$LITEOSTHIRDPARTY/bounds_checking_function/include" ]
defines = [ "SECUREC_IN_KERNEL=0" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_LIB_ZLIB)
module_name = "z"
kernel_module(module_name) {
sources = [
"$LITEOSTHIRDPARTY/zlib/adler32.c",
"$LITEOSTHIRDPARTY/zlib/compress.c",
"$LITEOSTHIRDPARTY/zlib/crc32.c",
"$LITEOSTHIRDPARTY/zlib/deflate.c",
"$LITEOSTHIRDPARTY/zlib/gzclose.c",
"$LITEOSTHIRDPARTY/zlib/gzlib.c",
"$LITEOSTHIRDPARTY/zlib/gzread.c",
"$LITEOSTHIRDPARTY/zlib/gzwrite.c",
"$LITEOSTHIRDPARTY/zlib/infback.c",
"$LITEOSTHIRDPARTY/zlib/inffast.c",
"$LITEOSTHIRDPARTY/zlib/inflate.c",
"$LITEOSTHIRDPARTY/zlib/inftrees.c",
"$LITEOSTHIRDPARTY/zlib/trees.c",
"$LITEOSTHIRDPARTY/zlib/uncompr.c",
"$LITEOSTHIRDPARTY/zlib/zutil.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "$LITEOSTHIRDPARTY/zlib" ]
}
group("zlib") {
public_deps = [ ":$module_name" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("$root_out_dir/config.gni")
LITEOSTOPDIR = "//kernel/liteos_a"
LITEOSTHIRDPARTY = "//third_party"
HDFTOPDIR = "//drivers/adapter/khdf/liteos"
template("kernel_module") {
if (defined(invoker.module_switch) && !invoker.module_switch) {
group(target_name) {
not_needed(invoker, "*")
}
} else {
static_library(target_name) {
forward_variables_from(invoker, "*")
}
}
}
template("config") {
config(target_name) {
if (defined(invoker.module_switch) && !invoker.module_switch && target_name == "public") {
not_needed(invoker, "*")
} else {
forward_variables_from(invoker, "*")
}
}
}
set_defaults("kernel_module") {
configs = [
"$LITEOSTOPDIR:public",
"$LITEOSTOPDIR:los_config",
]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
group("net") {
deps = [
"lwip-2.1",
"telnet",
]
}
config("public") {
configs = [
"lwip-2.1:public",
"telnet:public",
]
}
# Copyright (c) 2021-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
import("$LITEOSTHIRDPARTY/lwip/lwip.gni")
import("lwip_porting.gni")
module_switch = defined(LOSCFG_NET_LWIP_SACK_2_1)
module_name = "lwip"
kernel_module(module_name) {
include_dirs = [ "$LWIP_PORTING_DIR/enhancement/include" ]
sources = LWIP_PORTING_FILES + LWIPNOAPPSFILES
sources -= [
"$LWIPDIR/api/sockets.c",
"$LWIPDIR/core/ipv4/dhcp.c",
"$LWIPDIR/core/ipv4/etharp.c",
]
public_configs = [ ":public" ]
defines = [
"__LWIP__",
"LWIP_NOASSERT",
"_BSD_SOURCE=1",
]
}
config("public") {
include_dirs = [ "../mac" ]
include_dirs += LWIP_PORTING_INCLUDE_DIRS
include_dirs += LWIP_INCLUDE_DIRS
}
group("lwip-2.1") {
public_deps = [ ":$module_name" ]
}
# Copyright (c) 2021-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
LWIP_PORTING_DIR = get_path_info(".", "abspath")
LWIP_PORTING_INCLUDE_DIRS = [ "$LWIP_PORTING_DIR/porting/include" ]
LWIP_PORTING_FILES = [
"$LWIP_PORTING_DIR/porting/src/driverif.c",
"$LWIP_PORTING_DIR/porting/src/sockets.c",
"$LWIP_PORTING_DIR/porting/src/sys_arch.c",
"$LWIP_PORTING_DIR/enhancement/src/api_shell.c",
"$LWIP_PORTING_DIR/enhancement/src/fixme.c",
"$LWIP_PORTING_DIR/enhancement/src/dhcps.c",
]
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
module_switch = defined(LOSCFG_NET_TELNET)
module_name = get_path_info(rebase_path("."), "name")
kernel_module(module_name) {
sources = [
"src/telnet_dev.c",
"src/telnet_loop.c",
]
public_configs = [ ":public" ]
}
config("public") {
include_dirs = [ "include" ]
}
# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
# Copyright (c) 2020-2021 Huawei Device Co., Ltd. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this list of
# conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice, this list
# of conditions and the following disclaimer in the documentation and/or other materials
# provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its contributors may be used
# to endorse or promote products derived from this software without specific prior written
# permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import("//kernel/liteos_a/liteos.gni")
cmd = "if [ -f " + rebase_path("//$LOSCFG_BOARD_CONFIG_PATH/BUILD.gn") + " ]; then echo true; else echo false; fi"
HAVE_BOARD_CONFIG = exec_script("//build/lite/run_shell_cmd.py", [ cmd ], "value")
module_name = "bsp"
kernel_module(module_name) {
sources = [ "main.c" ]
sources += [
"hwi_shell.c",
"los_cir_buf.c",
"los_config.c",
"los_excinfo.c",
"los_init.c",
"los_magickey.c",
"los_printf.c",
"los_seq_buf.c",
]
if (defined(LOSCFG_FS_VFS)) {
sources += [
"console.c",
"virtual_serial.c",
]
}
if (defined(LOSCFG_BASE_CORE_HILOG)) {
sources += [ "los_hilog.c" ]
}
public_configs = [ ":public" ]
}
group("platform") {
public_deps = [ ":$module_name" ]
deps = [ ":board.ld" ]
if (HAVE_BOARD_CONFIG) {
deps += [ "//$LOSCFG_BOARD_CONFIG_PATH" ]
}
}
config("public") {
include_dirs = [
".",
]
if (HAVE_BOARD_CONFIG) {
configs = [ "//$LOSCFG_BOARD_CONFIG_PATH:public" ]
}
}
source_set("board") {
sources = [ "board.ld.S" ]
configs = []
configs += [
"$LITEOSTOPDIR:los_config",
"$LITEOSTOPDIR/kernel/base:public",
":public",
]
asmflags = [
"-P",
"-E",
]
}
copy("board.ld") {
deps = [ ":board" ]
sources = [ "$target_out_dir/board.board.ld.o" ]
outputs = [ "$root_out_dir/board.ld" ]
}
......@@ -36,13 +36,12 @@ LOCAL_SRCS = $(wildcard ./main.c)
LOCAL_INCLUDE += -I $(LITEOSTOPDIR)/compat/posix/src \
-I $(LITEOSTOPDIR)/bsd/dev/random
LOCAL_SRCS += $(wildcard ../kernel/common/*.c)
LOCAL_SRCS := $(filter-out ../kernel/common/los_rootfs.c ../kernel/common/los_bootargs.c, $(LOCAL_SRCS))
LOCAL_SRCS += $(wildcard *.c)
ifneq ($(LOSCFG_FS_VFS), y)
LOCAL_SRCS := $(filter-out ../kernel/common/console.c ../kernel/common/virtual_serial.c, $(LOCAL_SRCS))
LOCAL_SRCS := $(filter-out console.c virtual_serial.c, $(LOCAL_SRCS))
endif
ifneq ($(LOSCFG_BASE_CORE_HILOG), y)
LOCAL_SRCS := $(filter-out ../kernel/common/los_hilog.c, $(LOCAL_SRCS))
LOCAL_SRCS := $(filter-out los_hilog.c, $(LOCAL_SRCS))
endif
ifeq ($(LOSCFG_KERNEL_TICKLESS), y)
......
......@@ -49,7 +49,8 @@ PLATFORM_BSP_BASE := $(LITEOSTOPDIR)/platform
PLATFORM_INCLUDE := -I $(LITEOSTOPDIR)/../../$(LOSCFG_BOARD_CONFIG_PATH) \
-I $(LITEOSTOPDIR)/../../$(LOSCFG_BOARD_CONFIG_PATH)/include \
-I $(PLATFORM_BSP_BASE)/../kernel/common \
-I $(PLATFORM_BSP_BASE)/../kernel/common/rootfs \
-I $(PLATFORM_BSP_BASE) \
-I $(PLATFORM_BSP_BASE)/../../../drivers/liteos/platform/pm \
-I $(PLATFORM_BSP_BASE)/hw/include \
-I $(PLATFORM_BSP_BASE)/include
......
......@@ -115,7 +115,7 @@ extern UINT32 __heap_end;
* @ingroup los_config
* External configuration item for timer tailoring
*/
#ifndef LOSCFG_BASE_CORE_TICK_HW_TIME
#if defined(LOSCFG_BASE_CORE_TICK_HW_TIME) && (LOSCFG_BASE_CORE_TICK_HW_TIME == 0)
#undef LOSCFG_BASE_CORE_TICK_HW_TIME
#endif
/****************************** Hardware interrupt module configuration ******************************/
......
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册