mirror of
https://gitee.com/openharmony/startup_init
synced 2024-11-30 05:41:10 +00:00
bugfix: fix compiling error for qemu-arm-linux-min system.
1)最小系统不需要profiler,通过support_jsapi进行隔离。 Signed-off-by: handyohos <zhangxiaotian@huawei.com> Change-Id: I1ef59b9a8e1c3428de45e5623126cc579f689d6a
This commit is contained in:
parent
bf278d085f
commit
26a2fe2595
@ -151,7 +151,9 @@ if (defined(ohos_lite)) {
|
||||
"//third_party/cJSON:cjson_static",
|
||||
]
|
||||
|
||||
external_deps = [ "profiler:libhidebug" ]
|
||||
if (support_jsapi) {
|
||||
external_deps = [ "profiler:libhidebug" ]
|
||||
}
|
||||
|
||||
cflags = []
|
||||
|
||||
@ -186,6 +188,9 @@ if (defined(ohos_lite)) {
|
||||
if (!enable_ramdisk) {
|
||||
defines += [ "DISABLE_INIT_TWO_STAGES" ]
|
||||
}
|
||||
if (support_jsapi) {
|
||||
defines += [ "SUPPORT_PROFILER_HIDEBUG" ]
|
||||
}
|
||||
|
||||
if (defined(product_name) && product_name == "rk3568") {
|
||||
defines += [ "PRODUCT_RK" ]
|
||||
|
@ -19,7 +19,10 @@
|
||||
#include <sys/param.h>
|
||||
#include <sys/resource.h>
|
||||
|
||||
#ifdef SUPPORT_PROFILER_HIDEBUG
|
||||
#include "hidebug_base.h"
|
||||
#endif
|
||||
|
||||
#include "init_group_manager.h"
|
||||
#include "init.h"
|
||||
#include "init_log.h"
|
||||
@ -86,7 +89,10 @@ int ServiceExec(const Service *service)
|
||||
}
|
||||
}
|
||||
INIT_CHECK_ONLY_ELOG(unsetenv("UV_THREADPOOL_SIZE") == 0, "set UV_THREADPOOL_SIZE error : %d.", errno);
|
||||
#ifdef SUPPORT_PROFILER_HIDEBUG
|
||||
InitEnvironmentParam(service->name);
|
||||
#endif
|
||||
|
||||
// L2 Can not be reset env
|
||||
if (service->extraArgs.argv != NULL && service->extraArgs.count > 0) {
|
||||
INIT_CHECK_ONLY_ELOG(execv(service->extraArgs.argv[0], service->extraArgs.argv) == 0,
|
||||
|
@ -190,10 +190,10 @@ ohos_unittest("init_ut") {
|
||||
]
|
||||
defines += [ "_GNU_SOURCE" ]
|
||||
|
||||
external_deps = [
|
||||
"hiviewdfx_hilog_native:libhilog",
|
||||
"profiler:libhidebug",
|
||||
]
|
||||
external_deps = [ "hiviewdfx_hilog_native:libhilog" ]
|
||||
if (support_jsapi) {
|
||||
external_deps += [ "profiler:libhidebug" ]
|
||||
}
|
||||
|
||||
if (param_feature_watcher) {
|
||||
external_deps += [
|
||||
|
Loading…
Reference in New Issue
Block a user