touch: Make gestures configurable without TARGET_SPECIFIC_HEADER_PATH

SOONG_CONFIG_NAMESPACES += OPLUS_LINEAGE_TOUCH_HAL
SOONG_CONFIG_OPLUS_LINEAGE_TOUCH_HAL := INCLUDE_DIR
SOONG_CONFIG_OPLUS_LINEAGE_TOUCH_HAL_INCLUDE_DIR := \
    $(DEVICE_PATH)/touch/include

Change-Id: Ib4574926ceb16961e2b435aae4e8921665af4e23
This commit is contained in:
LuK1337
2022-07-12 10:18:42 +02:00
parent 7b65e6e8d9
commit 0962815d6f
5 changed files with 23 additions and 5 deletions

View File

@@ -1,6 +1,26 @@
soong_config_module_type {
name: "oplus_lineage_touch_hal_cc_defaults",
module_type: "cc_defaults",
config_namespace: "OPLUS_LINEAGE_TOUCH_HAL",
value_variables: ["INCLUDE_DIR"],
properties: ["include_dirs"],
}
oplus_lineage_touch_hal_cc_defaults {
name: "oplus_lineage_touch_hal_defaults",
soong_config_variables: {
INCLUDE_DIR: {
include_dirs: ["%s"],
},
},
}
cc_binary {
name: "vendor.lineage.touch@1.0-service.oplus",
defaults: ["hidl_defaults"],
defaults: [
"hidl_defaults",
"oplus_lineage_touch_hal_defaults",
],
init_rc: ["vendor.lineage.touch@1.0-service.oplus.rc"],
vintf_fragments: ["vendor.lineage.touch@1.0-service.oplus.xml"],
vendor: true,
@@ -15,5 +35,4 @@ cc_binary {
"libutils",
"vendor.lineage.touch@1.0",
],
local_include_dirs: ["include"],
}

View File

@@ -19,8 +19,7 @@
#include <android-base/file.h>
#include <android-base/strings.h>
#include <touch/oplus/TouchscreenGesture.h>
#include "touch/oplus/TouchscreenGestureConfig.h"
#include <TouchscreenGestureConfig.h>
using ::android::base::ReadFileToString;
using ::android::base::Trim;

View File

@@ -18,7 +18,7 @@
#include <android-base/logging.h>
#include <hidl/HidlTransportSupport.h>
#include <touch/oplus/TouchscreenGesture.h>
#include "TouchscreenGesture.h"
using android::sp;
using android::hardware::configureRpcThreadpool;