mirror of
https://gitee.com/openharmony/filemanagement_storage_service
synced 2024-11-23 06:59:59 +00:00
update services/storage_daemon/mtp/test/BUILD.gn.
Signed-off-by: 李尚 <lishang21@huawei.com>
This commit is contained in:
parent
f9def91abc
commit
233515b33c
@ -11,30 +11,30 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
import("//build/ohos.gni")
|
||||
import("//build/test.gni")
|
||||
import("//foundation/filemanagement/storage_service/storage_service_aafwk.gni")
|
||||
|
||||
ohos_executable("mtpfs") {
|
||||
branch_protector_ret = "pac_ret"
|
||||
ROOT_DIR = "${storage_service_path}/services"
|
||||
|
||||
ohos_unittest("mtpfs_fuse_test") {
|
||||
branch_protector_ret = "pac_ret"
|
||||
sanitize = {
|
||||
integer_overflow = true
|
||||
ubsan = true
|
||||
boundary_sanitize = true
|
||||
cfi = true
|
||||
cfi_cross_dso = true
|
||||
debug = false
|
||||
}
|
||||
|
||||
include_dirs = [
|
||||
"./include",
|
||||
"${storage_daemon_path}/include/utils",
|
||||
"${storage_service_common_path}/include",
|
||||
]
|
||||
module_out_path = "storage_service/storage_daemon"
|
||||
|
||||
defines = [
|
||||
"STORAGE_LOG_TAG = \"StorageDaemon\"",
|
||||
"LOG_DOMAIN = 0xD004301",
|
||||
"private = public",
|
||||
]
|
||||
|
||||
include_dirs = [
|
||||
"${storage_daemon_path}/mtpfs/include",
|
||||
"${storage_daemon_path}/include/utils",
|
||||
"${storage_service_common_path}/include",
|
||||
]
|
||||
|
||||
cflags = [
|
||||
@ -44,24 +44,27 @@ ohos_executable("mtpfs") {
|
||||
"-std=c++11",
|
||||
]
|
||||
|
||||
deps = [ "${storage_daemon_path}:storage_common_utils" ]
|
||||
deps = [
|
||||
"${storage_daemon_path}:storage_common_utils",
|
||||
"//third_party/googletest:gtest_main",
|
||||
]
|
||||
|
||||
external_deps = [
|
||||
"c_utils:utils",
|
||||
"hilog:libhilog",
|
||||
]
|
||||
|
||||
if (support_open_source_libmtp) {
|
||||
# if (support_open_source_libmtp) {
|
||||
sources = [
|
||||
"./src/mtpfs_fuse.cpp",
|
||||
"./src/mtpfs_libmtp.cpp",
|
||||
"./src/mtpfs_main.cpp",
|
||||
"./src/mtpfs_mtp_device.cpp",
|
||||
"./src/mtpfs_tmp_files_pool.cpp",
|
||||
"./src/mtpfs_type_dir.cpp",
|
||||
"./src/mtpfs_type_file.cpp",
|
||||
"./src/mtpfs_type_tmp_file.cpp",
|
||||
"./src/mtpfs_util.cpp",
|
||||
"$ROOT_DIR/storage_daemon/mtpfs/src/mtpfs_fuse.cpp",
|
||||
"$ROOT_DIR/storage_daemon/mtpfs/src/mtpfs_libmtp.cpp",
|
||||
"$ROOT_DIR/storage_daemon/mtpfs/src/mtpfs_mtp_device.cpp",
|
||||
"$ROOT_DIR/storage_daemon/mtpfs/src/mtpfs_tmp_files_pool.cpp",
|
||||
"$ROOT_DIR/storage_daemon/mtpfs/src/mtpfs_type_dir.cpp",
|
||||
"$ROOT_DIR/storage_daemon/mtpfs/src/mtpfs_type_file.cpp",
|
||||
"$ROOT_DIR/storage_daemon/mtpfs/src/mtpfs_type_tmp_file.cpp",
|
||||
"$ROOT_DIR/storage_daemon/mtpfs/src/mtpfs_util.cpp",
|
||||
"$ROOT_DIR/storage_daemon/mtpfs/test/mtpfs_fuse_test.cpp",
|
||||
]
|
||||
external_deps += [
|
||||
"libfuse:libfuse",
|
||||
@ -69,11 +72,16 @@ ohos_executable("mtpfs") {
|
||||
"libusb:libusb",
|
||||
"openssl:libcrypto_shared",
|
||||
]
|
||||
} else {
|
||||
sources = [ "./src/mtpfs_main_virtual.cpp" ]
|
||||
}
|
||||
# } else {
|
||||
# sources = [ "$ROOT_DIR/storage_daemon/mtpfs/src/mtpfs_main_virtual.cpp" ]
|
||||
# }
|
||||
|
||||
subsystem_name = "filemanagement"
|
||||
part_name = "storage_service"
|
||||
install_enable = true
|
||||
}
|
||||
|
||||
group("storage_daemon_mtpfs_test") {
|
||||
testonly = true
|
||||
deps = [ ":mtpfs_fuse_test" ]
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user