From 69e246053cf4a2c27eb4ea5924c0b2fb911dcf70 Mon Sep 17 00:00:00 2001 From: l30005037 Date: Wed, 9 Apr 2025 10:52:31 +0800 Subject: [PATCH] The security link option is modified Signed-off-by: l30005037 --- services/distributeddataservice/adapter/utils/BUILD.gn | 2 +- services/distributeddataservice/app/BUILD.gn | 2 +- services/distributeddataservice/app/src/checker/BUILD.gn | 2 +- services/distributeddataservice/framework/BUILD.gn | 2 +- services/distributeddataservice/service/BUILD.gn | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/services/distributeddataservice/adapter/utils/BUILD.gn b/services/distributeddataservice/adapter/utils/BUILD.gn index f96b7fe3e..bf5b815f0 100755 --- a/services/distributeddataservice/adapter/utils/BUILD.gn +++ b/services/distributeddataservice/adapter/utils/BUILD.gn @@ -31,7 +31,7 @@ ohos_source_set("distributeddata_utils") { } include_dirs = [ "../include/utils" ] - ldflags = [ "-Wl,-z,relro,-z,now,--exclude-libs,ALL" ] + ldflags = [ "-Wl,--exclude-libs,ALL" ] external_deps = [ "c_utils:utils", diff --git a/services/distributeddataservice/app/BUILD.gn b/services/distributeddataservice/app/BUILD.gn index 7748c2fda..084cbb75e 100644 --- a/services/distributeddataservice/app/BUILD.gn +++ b/services/distributeddataservice/app/BUILD.gn @@ -83,7 +83,7 @@ config("module_private_config") { "-Oz", ] - ldflags = [ "-Wl,-z,relro,-z,now,--gc-sections" ] + ldflags = [ "-Wl,--gc-sections" ] } ohos_shared_library("distributeddataservice") { diff --git a/services/distributeddataservice/app/src/checker/BUILD.gn b/services/distributeddataservice/app/src/checker/BUILD.gn index 575e9fad2..f0fa8dd25 100644 --- a/services/distributeddataservice/app/src/checker/BUILD.gn +++ b/services/distributeddataservice/app/src/checker/BUILD.gn @@ -37,7 +37,7 @@ ohos_source_set("distributeddata_checker") { if (build_public_version) { cflags_cc += [ "-DCONFIG_PUBLIC_VERSION" ] } - ldflags = [ "-Wl,-z,relro,-z,now,--exclude-libs,ALL" ] + ldflags = [ "-Wl,--exclude-libs,ALL" ] deps = [ "${data_service_path}/adapter/utils:distributeddata_utils" ] cflags = [ "-Oz" ] external_deps = [ diff --git a/services/distributeddataservice/framework/BUILD.gn b/services/distributeddataservice/framework/BUILD.gn index 9270da8f4..344f08426 100644 --- a/services/distributeddataservice/framework/BUILD.gn +++ b/services/distributeddataservice/framework/BUILD.gn @@ -126,7 +126,7 @@ ohos_shared_library("distributeddatasvcfwk") { "-ffunction-sections", ] - ldflags = [ "-Wl,-z,relro,-z,now,--gc-sections" ] + ldflags = [ "-Wl,--gc-sections" ] cflags_cc = [ "-fvisibility=hidden" ] diff --git a/services/distributeddataservice/service/BUILD.gn b/services/distributeddataservice/service/BUILD.gn index 6274b1d1c..952c92895 100644 --- a/services/distributeddataservice/service/BUILD.gn +++ b/services/distributeddataservice/service/BUILD.gn @@ -65,7 +65,7 @@ ohos_shared_library("distributeddatasvc") { "-ffunction-sections", ] - ldflags = [ "-Wl,-z,relro,-z,now,--gc-sections" ] + ldflags = [ "-Wl,--gc-sections" ] cflags_cc = [ "-fvisibility=hidden", -- Gitee