• 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("//build/ohos.gni")
15import("//build/test.gni")
16
17module_output_path = "asset/asset_UT_test"
18
19ohos_rust_static_library("asset_db_operator") {
20  sources = [ "src/lib.rs" ]
21  deps = [
22    ":asset_sqlite3_wrapper",
23    "../../frameworks/definition:asset_definition",
24    "../../frameworks/os_dependency/log:asset_log",
25    "../constants:asset_constants",
26  ]
27
28  crate_name = "asset_db_operator"
29  crate_type = "rlib"
30  subsystem_name = "security"
31  part_name = "asset"
32}
33
34ohos_rust_unittest("asset_db_operator_test") {
35  module_out_path = module_output_path
36  sources = [ "src/lib.rs" ]
37  deps = [
38    ":asset_sqlite3_wrapper",
39    "../../frameworks/definition:asset_definition",
40    "../../frameworks/os_dependency/log:asset_log",
41    "../constants:asset_constants",
42  ]
43  subsystem_name = "security"
44  part_name = "asset"
45}
46
47ohos_static_library("asset_sqlite3_wrapper") {
48  sources = [ "src/sqlite3_wrapper.c" ]
49  deps = [ "//third_party/sqlite:sqlite" ]
50  subsystem_name = "security"
51  part_name = "asset"
52}
53