diff --git a/services/distributedfiledaemon/BUILD.gn b/services/distributedfiledaemon/BUILD.gn old mode 100755 new mode 100644 index 7a2313b34a755878fd72e9cc45e1c49bc2de7842..6cd5642e517030a0998476b2e136922cfe901636 --- a/services/distributedfiledaemon/BUILD.gn +++ b/services/distributedfiledaemon/BUILD.gn @@ -18,7 +18,6 @@ ohos_shared_library("libdistributedfiledaemon") { "include", "//foundation/distributedhardware/devicemanager/interfaces/inner_kits/native_cpp/include", "//base/security/deviceauth/interfaces/innerkits", - "//third_party/json/include", ] sources = [ @@ -42,7 +41,9 @@ ohos_shared_library("libdistributedfiledaemon") { "${utils_path}:libdistributedfileutils", "//base/security/deviceauth/services:deviceauth_sdk", "//foundation/distributedhardware/devicemanager/interfaces/inner_kits/native_cpp:devicemanagersdk", + "//third_party/json:nlohmann_json_static", ] + ldflags = [ "-Wl,--exclude-libs,libnlohmann_json_static.a" ] external_deps = [ "dataclassification:data_transit_mgr", "dsoftbus_standard:softbus_client", diff --git a/services/distributedfiledaemon/test/unittest/BUILD.gn b/services/distributedfiledaemon/test/unittest/BUILD.gn index 94b311b308c399185e57b81306b6be9b0d172609..c9b71941f3130cea05ce3700e8869145618c1a4b 100644 --- a/services/distributedfiledaemon/test/unittest/BUILD.gn +++ b/services/distributedfiledaemon/test/unittest/BUILD.gn @@ -22,7 +22,6 @@ config("module_private_config") { "${services_path}/distributedfiledaemon/include", "//foundation/distributedhardware/devicemanager/interfaces/inner_kits/native_cpp/include", "//base/security/deviceauth/interfaces/innerkits", - "//third_party/json/include", ] } @@ -43,8 +42,11 @@ ohos_unittest("DeviceManagerAgentTest") { "//base/security/deviceauth/services:deviceauth_sdk", "//foundation/distributedhardware/devicemanager/interfaces/inner_kits/native_cpp:devicemanagersdk", "//third_party/googletest:gtest_main", + "//third_party/json:nlohmann_json_static", ] + ldflags = [ "-Wl,--exclude-libs,libnlohmann_json_static.a" ] + external_deps = [ "dataclassification:data_transit_mgr", "dsoftbus_standard:softbus_client", diff --git a/test/moduletest/BUILD.gn b/test/moduletest/BUILD.gn index 3c6b63319a2f5dc704ae0033ed6473d8c52b4fa8..beddafdeed1bb806fbd15870b2d0f7b3583cfb5c 100644 --- a/test/moduletest/BUILD.gn +++ b/test/moduletest/BUILD.gn @@ -25,7 +25,6 @@ config("module_private_config") { "//foundation/communication/dsoftbus/interfaces/kits/bus_center", "//foundation/communication/dsoftbus/interfaces/kits/common", "//base/security/deviceauth/interfaces/innerkits", - "//third_party/json/include", ] } @@ -65,8 +64,11 @@ ohos_moduletest("DistributedFileDaemonServiceTest") { "//foundation/filemanagement/dfs_service/services/distributedfiledaemon:libdistributedfiledaemon", "//third_party/googletest:gmock", "//third_party/googletest:gtest_main", + "//third_party/json:nlohmann_json_static", ] + ldflags = [ "-Wl,--exclude-libs,libnlohmann_json_static.a" ] + external_deps = [ "dataclassification:data_transit_mgr", "dsoftbus_standard:softbus_client",