From b21c1ac8761115ece5c790f1515bf53d921100dc Mon Sep 17 00:00:00 2001 From: lokilee73 Date: Thu, 14 Jan 2021 16:45:06 +0900 Subject: Add FEATURE_DLOG and change LOG_TAG Change-Id: Ied9d765909ba6d409550b14088012524913b9f63 Signed-off-by: lokilee73 --- CMakeLists.txt | 4 ++++ hw/common/common.h | 2 +- packaging/device-manager-plugin-sc7730.spec | 4 +++- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 9b7d08a..6e928e8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,6 +7,10 @@ SET(PREFIX ${CMAKE_INSTALL_PREFIX}) SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS} -Wall -Werror") +IF(ENABLE_DLOG STREQUAL on) + ADD_DEFINITIONS("-DFEATURE_DLOG") +ENDIF() + ADD_SUBDIRECTORY(hw/battery) ADD_SUBDIRECTORY(hw/cpu) ADD_SUBDIRECTORY(hw/display) diff --git a/hw/common/common.h b/hw/common/common.h index 3c506ff..ae965d6 100644 --- a/hw/common/common.h +++ b/hw/common/common.h @@ -25,7 +25,7 @@ #include #ifdef FEATURE_DLOG - #define LOG_TAG "HALBACKEND_DEVICE" + #define LOG_TAG "HAL_BACKEND_DEVICE" #include #define _D(fmt, args...) SLOGD(fmt, ##args) #define _I(fmt, args...) SLOGI(fmt, ##args) diff --git a/packaging/device-manager-plugin-sc7730.spec b/packaging/device-manager-plugin-sc7730.spec index 8e4af3c..f536e98 100644 --- a/packaging/device-manager-plugin-sc7730.spec +++ b/packaging/device-manager-plugin-sc7730.spec @@ -25,7 +25,9 @@ Device manager plugin sc7730 cp %{SOURCE1} . %build -%cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} +%cmake \ + -DCMAKE_INSTALL_PREFIX=%{_prefix} \ + -DENABLE_DLOG=on \ make %{?jobs:-j%jobs} -- cgit v1.2.3