• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2023 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("//arkcompiler/ets_runtime/js_runtime_config.gni")
15
16src_libmplutil = [
17  "src/mpl_logging.cpp",
18  "src/muid.cpp",
19  "src/namemangler.cpp",
20  "src/literalstrname.cpp",
21  "src/file_layout.cpp",
22  "src/file_utils.cpp",
23  "src/mpl_scheduler.cpp",
24  "src/mpl_timer.cpp",
25  "src/profile.cpp",
26  "src/string_utils.cpp",
27  "src/error_code.cpp",
28  "src/thread_env.cpp",
29  "src/mpl_int_val.cpp",
30]
31
32src_libcommandline = [
33  "src/cl_option.cpp",
34  "src/cl_option_parser.cpp",
35  "src/cl_parser.cpp",
36]
37
38include_libmplutil = [
39  "${MAPLEALL_ROOT}/maple_util/include",
40  "${MAPLEALL_ROOT}/maple_ir/include",
41  "${MAPLEALL_ROOT}/mempool/include",
42  "${MAPLEALL_ROOT}/maple_driver/include",
43]
44
45include_libcommandline = [ "${MAPLEALL_ROOT}/maple_util/include" ]
46
47ohos_static_library("libmplutil") {
48  stack_protector_ret = false
49  if (enable_sanitize) {
50    sanitize = {
51      cfi = true
52      cfi_cross_dso = true
53      debug = false
54    }
55    branch_protector_ret = "pac_ret"
56  }
57  configs = [ "${MAPLEALL_ROOT}:mapleallcompilecfg" ]
58  sources = src_libmplutil
59  include_dirs = include_libmplutil
60  external_deps = [ "bounds_checking_function:libsec_static" ]
61  libs = [ "pthread" ]
62  output_dir = "${root_out_dir}/lib/${HOST_ARCH}"
63  part_name = "ets_runtime"
64  subsystem_name = "arkcompiler"
65}
66
67ohos_static_library("libcommandline") {
68  stack_protector_ret = false
69  configs = [ "${MAPLEALL_ROOT}:mapleallcompilecfg" ]
70  sources = src_libcommandline
71  include_dirs = include_libcommandline
72  external_deps = [ "bounds_checking_function:libsec_static" ]
73  output_dir = "${root_out_dir}/lib/${HOST_ARCH}"
74  part_name = "ets_runtime"
75  subsystem_name = "arkcompiler"
76}
77