From 950be7eaff7e6699b35e9acf1d1b8056e19ca0bc Mon Sep 17 00:00:00 2001 From: handyohos Date: Thu, 30 Dec 2021 22:09:13 +0800 Subject: [PATCH] bugfix: optimize link libraries for init. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 去掉libbegetutil对libcrypto_static的无效依赖,修改libsyspara_watcher对ipc_core的依赖为ipc_single。 Signed-off-by: handyohos Change-Id: I02d1c74154991752ff5ee98a1485ba7c6b202981 --- interfaces/innerkits/BUILD.gn | 1 - services/init/standard/device.c | 3 +++ services/param/watcher/BUILD.gn | 4 ++-- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/interfaces/innerkits/BUILD.gn b/interfaces/innerkits/BUILD.gn index 7ba11337..b14fdc9b 100755 --- a/interfaces/innerkits/BUILD.gn +++ b/interfaces/innerkits/BUILD.gn @@ -46,7 +46,6 @@ ohos_shared_library("libbegetutil") { "//base/startup/init_lite/services/param:param_client", "//base/startup/init_lite/services/utils:libinit_utils", "//third_party/bounds_checking_function:libsec_shared", - "//third_party/openssl:libcrypto_static", "//utils/native/base:utils", ] external_deps = [ "hiviewdfx_hilog_native:libhilog" ] diff --git a/services/init/standard/device.c b/services/init/standard/device.c index 8d4b3618..bac801fc 100755 --- a/services/init/standard/device.c +++ b/services/init/standard/device.c @@ -44,6 +44,9 @@ void MountBasicFs(void) if (mount("tmpfs", "/dev", "tmpfs", MS_NOSUID, "mode=0755") != 0) { INIT_LOGE("Mount tmpfs failed. %s", strerror(errno)); } + if (mount("tmpfs", "/mnt", "tmpfs", MS_NOSUID, "mode=0755") != 0) { + INIT_LOGE("Mount tmpfs failed. %s", strerror(errno)); + } if (mkdir("/dev/pts", S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH) != 0) { INIT_LOGE("mkdir /dev/pts failed. %s", strerror(errno)); } diff --git a/services/param/watcher/BUILD.gn b/services/param/watcher/BUILD.gn index 52b1fe9e..711f6d27 100644 --- a/services/param/watcher/BUILD.gn +++ b/services/param/watcher/BUILD.gn @@ -51,7 +51,7 @@ ohos_shared_library("param_watcheragent") { external_deps = [ "hiviewdfx_hilog_native:libhilog", - "ipc:ipc_core", + "ipc:ipc_single", "safwk:system_ability_fwk", "samgr_standard:samgr_proxy", ] @@ -99,7 +99,7 @@ ohos_shared_library("param_watcher") { external_deps = [ "hiviewdfx_hilog_native:libhilog", - "ipc:ipc_core", + "ipc:ipc_single", "safwk:system_ability_fwk", "samgr_standard:samgr_proxy", ] -- GitLab