1# Copyright (c) 2020 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 14import("//build/ohos.gni") 15 16config("sysparam_simulator_public_config") { 17 include_dirs = [ 18 "../interfaces/innerkits/include/syspara", 19 "../interfaces/hals", 20 ] 21} 22 23config("sysparam_simulator_config") { 24 if (product_name != "ohos-sdk") { 25 if (board_toolchain_type != "iccarm") { 26 cflags = [ 27 "-Wno-error", 28 "-D_INC_STDIO_S", 29 "-D_INC_STDLIB_S", 30 "-D_INC_MEMORY_S", 31 "-D_INC_STRING_S", 32 "-D_INC_WCHAR_S", 33 "-D_SECTMP=//", 34 "-D_STDIO_S_DEFINED", 35 ] 36 } 37 } else { 38 cflags = [ 39 "-Wno-error", 40 "-D_INC_STDIO_S", 41 "-D_INC_STDLIB_S", 42 "-D_INC_MEMORY_S", 43 "-D_INC_STRING_S", 44 "-D_INC_WCHAR_S", 45 "-D_SECTMP=//", 46 "-D_STDIO_S_DEFINED", 47 ] 48 } 49 include_dirs = [ 50 "../../../../commonlibrary/utils_lite/include", 51 "./parameter/src", 52 "../interfaces/innerkits/include/syspara", 53 ] 54} 55 56ohos_static_library("sysparam_simulator") { 57 public_configs = [ ":sysparam_simulator_public_config" ] 58 configs = [ ":sysparam_simulator_config" ] 59 sources = [ 60 "./parameter/src/param_impl_posix/param_impl_posix.c", 61 "./parameter/src/parameter_common.c", 62 ] 63 external_deps = [ "bounds_checking_function:libsec_static" ] 64 defines = [ 65 "INCREMENTAL_VERSION=\"\"", 66 "BUILD_TYPE=\"\"", 67 "BUILD_USER=\"\"", 68 "BUILD_TIME=\"\"", 69 "BUILD_HOST=\"\"", 70 "BUILD_ROOTHASH=\"\"", 71 ] 72 part_name = "init" 73 subsystem_name = "startup" 74} 75