# Copyright (c) 2024 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. import("//base/sensors/sensor/sensor.gni") import("//test/xts/tools/build/suite.gni") module_output_path = "sensors/ActsSensorNdkTest" ohos_moduletest_suite("ActsSensorNdkTest") { module_out_path = module_output_path sources = [ "./sensor_native_test.cpp" ] include_dirs = [ "$SUBSYSTEM_DIR/utils/common/include", "$SUBSYSTEM_DIR/interfaces/kits/c", "$SUBSYSTEM_DIR/frameworks/native/include", ] cflags = [ "-Werror", "-fno-rtti", "-fno-exceptions", "-Wall", "-fno-common", "-fstack-protector-strong", "-Wshadow", "-FPIC", "-FS", "-O2", "-D_FORTIFY_SOURCE=2", "-fvisibility=hidden", "-Wformat=2", "-Wdate-time", "", ] deps = [ "$SUBSYSTEM_DIR/frameworks/native:ohsensor", "$SUBSYSTEM_DIR/utils/common:libsensor_utils", "//third_party/googletest:gmock_main", "//third_party/googletest:gtest_main", ] external_deps = [ "access_token:libaccesstoken_sdk", "access_token:libnativetoken", "access_token:libtoken_setproc", "c_utils:utils", "hilog:libhilog", "ipc:ipc_core", ] part_name = "sensor" subsystem_name = "sensors" }