blob: 2b04957e3506fe7fa8273b2bb57ea75dcd4c97c4 [file] [log] [blame] [edit]
soong_namespace {
}
soong_config_module_type {
name: "qti_thermal_hal_cc_defaults",
module_type: "cc_defaults",
config_namespace: "qti_thermal",
variables: ["netlink"],
properties: [
"cflags",
"header_libs",
"shared_libs",
"srcs",
],
}
soong_config_string_variable {
name: "netlink",
values: [
"true",
"false",
],
}
qti_thermal_hal_cc_defaults {
name: "qti_thermal_hal_defaults",
soong_config_variables: {
netlink: {
true: {
cflags: ["-DENABLE_THERMAL_NETLINK"],
header_libs: ["qti_kernel_headers"],
shared_libs: ["libnl"],
srcs: [
"thermalUtilsNetlink.cpp",
"thermalMonitorNetlink.cpp",
],
},
false: {
cflags: [],
header_libs: [],
shared_libs: [],
srcs: [
"thermalUtils.cpp",
"thermalMonitor.cpp",
],
},
conditions_default: {
cflags: ["-DENABLE_THERMAL_NETLINK"],
header_libs: ["qti_kernel_headers"],
shared_libs: ["libnl"],
srcs: [
"thermalUtilsNetlink.cpp",
"thermalMonitorNetlink.cpp",
],
},
},
},
}
cc_binary {
name: "android.hardware.thermal-service.qti",
defaults: ["qti_thermal_hal_defaults"],
relative_install_path: "hw",
init_rc: ["android.hardware.thermal-service.qti.rc"],
vintf_fragments: ["android.hardware.thermal-service.qti.xml"],
vendor: true,
shared_libs: [
"libbase",
"libbinder_ndk",
"android.hardware.thermal-V1-ndk",
"libcutils",
"libutils",
"liblog",
],
srcs: [
"service.cpp",
"thermal.cpp",
"thermalConfig.cpp",
"thermalCommon.cpp",
],
header_libs: [
"liblog_headers",
"libcutils_headers",
],
cflags: [
"-Wno-unused-parameter",
"-Wno-unused-variable",
"-fexceptions",
],
}