tri-state-key: Add support for system variants
* SDM845 family of OnePlus devices on LineageOS use a prebuilt vendor. Change-Id: I0bbb1ac2d97e49fcc2aa5d78138ae97cf6b536b8
This commit is contained in:
committed by
LuK1337
parent
7c8c176fd7
commit
60811b3df4
@@ -13,9 +13,9 @@
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
cc_binary {
|
||||
name: "tri-state-key_daemon",
|
||||
init_rc: ["tri-state-key_daemon.rc"],
|
||||
cc_defaults {
|
||||
name: "tri-state-key_defaults",
|
||||
stem: "tri-state-key_daemon",
|
||||
srcs: [
|
||||
"main.cpp",
|
||||
"uevent_listener.cpp",
|
||||
@@ -24,7 +24,6 @@ cc_binary {
|
||||
"-Wall",
|
||||
"-Werror",
|
||||
],
|
||||
vendor: true,
|
||||
shared_libs: [
|
||||
"libbase",
|
||||
"liblog",
|
||||
@@ -32,3 +31,17 @@ cc_binary {
|
||||
"libutils",
|
||||
],
|
||||
}
|
||||
|
||||
cc_binary {
|
||||
name: "tri-state-key_daemon",
|
||||
defaults: ["tri-state-key_defaults"],
|
||||
init_rc: ["tri-state-key_daemon.rc"],
|
||||
system_ext_specific: true,
|
||||
}
|
||||
|
||||
cc_binary {
|
||||
name: "tri-state-key_daemon.vendor",
|
||||
defaults: ["tri-state-key_defaults"],
|
||||
init_rc: ["vendor.tri-state-key_daemon.rc"],
|
||||
vendor: true,
|
||||
}
|
||||
|
||||
@@ -2,9 +2,9 @@ on fs
|
||||
chown system system /sys/devices/platform/soc/soc:tri_state_key/hall_data_calib
|
||||
chown system system /mnt/vendor/persist/engineermode/tri_state_hall_data
|
||||
|
||||
start vendor.tri-state-key_daemon
|
||||
start tri-state-key_daemon
|
||||
|
||||
service vendor.tri-state-key_daemon /vendor/bin/tri-state-key_daemon
|
||||
service tri-state-key_daemon /system_ext/bin/tri-state-key_daemon
|
||||
class late_start
|
||||
user system
|
||||
group system uhid
|
||||
|
||||
10
tri-state-key/vendor.tri-state-key_daemon.rc
Normal file
10
tri-state-key/vendor.tri-state-key_daemon.rc
Normal file
@@ -0,0 +1,10 @@
|
||||
on fs
|
||||
chown system system /sys/devices/platform/soc/soc:tri_state_key/hall_data_calib
|
||||
chown system system /mnt/vendor/persist/engineermode/tri_state_hall_data
|
||||
|
||||
start vendor.tri-state-key_daemon
|
||||
|
||||
service vendor.tri-state-key_daemon /vendor/bin/tri-state-key_daemon
|
||||
class late_start
|
||||
user system
|
||||
group system uhid
|
||||
Reference in New Issue
Block a user