1#Copyright (c) 2020-2021 Huawei Device 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, for example: "cortex-a7", "riscv32". 21board_cpu = "" 22 23# Board arch, for example: "armv7-a", "rv32imc". 24board_arch = "rv32imac" 25 26# Toolchain used for system compiling. 27# For example: gcc-arm-none-eabi, arm-linux-ohoseabi-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 = "riscv32-unknown-elf" 30 31#board_toolchain = "riscv-none-embed" 32 33# The path which toolchain installed, it's not mandatory if toolchain path has been added to your ~/.bashrc. 34board_toolchain_path = "" 35 36# Compiler prefix. 37board_toolchain_prefix = "riscv32-unknown-elf-" 38 39#board_toolchain_prefix = "riscv-none-embed-" 40 41# Compiler type, "gcc" or "clang". 42board_toolchain_type = "gcc" 43 44#Debug compiler optimization level options 45board_opt_flags = [] 46 47# Board related common compile flags. 48board_cflags = [ 49 "-mabi=ilp32", 50 "-falign-functions=2", 51 "-msave-restore", 52 "-fno-optimize-strlen", 53 "-freorder-blocks-algorithm=simple", 54 "-fno-schedule-insns", 55 "-fno-inline-small-functions", 56 "-fno-inline-functions-called-once", 57 "-mtune=size", 58 "-mno-small-data-limit=0", 59 "-fno-aggressive-loop-optimizations", 60 "-std=c99", 61 "-Wpointer-arith", 62 "-ffunction-sections", 63 "-fdata-sections", 64 "-fno-exceptions", 65 "-fno-short-enums", 66 "-fno-builtin", 67 "-O2", 68 "-static", 69 "-fno-common", 70 "-fno-stack-protector", 71 "-fno-omit-frame-pointer", 72 "-Wno-format-truncation", 73 "-D__RISC_V__", 74 "-D__LITEOS_M__", 75 "-DLWIP_SUPPORT_CUSTOM_PBUF=1", 76 "-D_BSD_SOURCE", 77] 78 79board_cflags += board_opt_flags 80 81board_asmflags = [ 82 "-march=rv32imac", 83 "-mabi=ilp32", 84 "-static", 85 "-O2", 86] 87board_asmflags += board_opt_flags 88board_cxx_flags = board_cflags 89board_ld_flags = [] 90 91# Board related headfiles search path. 92board_include_dirs = [] 93 94# Board adapter dir for OHOS components. 95board_adapter_dir = "//device/qemu/riscv32_virt/driver" 96 97# Sysroot path. 98board_configed_sysroot = "" 99 100# Board storage type, it used for file system generation. 101storage_type = "" 102