1# Copyright (c) 2021-2022 Talkweb Co., Ltd. 2# Licensed under the Apache License, Version 2.0 (the "License"); 3# you may not use this file except in compliance with the License. 4# You may obtain a copy of the License at 5# 6# http://www.apache.org/licenses/LICENSE-2.0 7# 8# Unless required by applicable law or agreed to in writing, software 9# distributed under the License is distributed on an "AS IS" BASIS, 10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11# See the License for the specific language governing permissions and 12# limitations under the License. 13 14# Kernel type, e.g. "linux", "liteos_a", "liteos_m". 15kernel_type = "liteos_m" 16 17# Kernel version. 18kernel_version = "3.0.0" 19 20# Board CPU type, e.g. "cortex-a7", "riscv32". 21board_cpu = "cortex-m4" 22 23# Board arch, e.g. "armv7-a", "rv32imac". 24board_arch = "" 25 26# Toolchain name used for system compiling. 27# E.g. gcc-arm-none-eabi, arm-linux-harmonyeabi-gcc, ohos-clang, riscv32-unknown-elf. 28# Note: The default toolchain is "ohos-clang". It's not mandatory if you use the default toolchain. 29board_toolchain = "arm-none-eabi-gcc" 30 31use_board_toolchain = true 32 33# The toolchain path installed, it's not mandatory if you have added toolchain path to your ~/.bashrc. 34board_toolchain_path = "" 35 36# Compiler prefix. 37board_toolchain_prefix = "arm-none-eabi-" 38 39# Compiler type, "gcc" or "clang". 40board_toolchain_type = "gcc" 41 42#Debug compiler optimization level options 43board_opt_flags = [ 44 "-mcpu=cortex-m4", 45 "-mthumb", 46 "-mfpu=fpv4-sp-d16", 47 "-mfloat-abi=hard", 48] 49 50# Board related common compile flags. 51board_cflags = [ 52 "-Og", 53 "-Wall", 54 "-fdata-sections", 55 "-ffunction-sections", 56 "-DUSE_HAL_DRIVER", 57 "-DSTM32F407xx", 58 "-DUSE_FULL_LL_DRIVER", 59 60 # "-MMD", 61 # "-MP", 62 # "-MF\"$(@:%.o=%.d)\"", 63 "-D__LITEOS_M__", 64] 65board_cflags += board_opt_flags 66 67board_asmflags = [ 68 "-Og", 69 "-Wall", 70 "-fdata-sections", 71 "-ffunction-sections", 72] 73board_asmflags += board_opt_flags 74 75board_cxx_flags = board_cflags 76 77board_ld_flags = [ 78 "--specs=nano.specs", 79 "-Wl,--gc-sections", 80 "-Wl,--wrap=_calloc_r", 81 "-Wl,--wrap=_malloc_r", 82 "-Wl,--wrap=_realloc_r", 83 "-Wl,--wrap=_reallocf_r", 84 "-Wl,--wrap=_free_r", 85 "-Wl,--wrap=_memalign_r", 86 "-Wl,--wrap=_malloc_usable_size_r", 87] 88board_ld_flags += board_opt_flags 89 90# Board related headfiles search path. 91board_include_dirs = [ "//commonlibrary/utils_lite/include" ] 92 93# Board adapter dir for OHOS components. 94board_adapter_dir = "" 95 96# Sysroot path. 97board_configed_sysroot = "" 98 99# Board storage type, it used for file system generation. 100storage_type = "spinor" 101