beast: Properly overlay Bluetooth apex
authorBruno Martins <bgcngm@gmail.com>
Fri, 27 Oct 2023 12:11:54 +0000 (13:11 +0100)
committerNolen Johnson <johnsonnolen@gmail.com>
Sat, 28 Oct 2023 19:05:18 +0000 (15:05 -0400)
Change-Id: I87c4f1136fd68490bd55bda4033f36988cbd57f1

device.mk
overlay/packages/apps/Bluetooth/res/values/config.xml [deleted file]
rro_overlays/BluetoothOverlay/Android.bp [new file with mode: 0644]
rro_overlays/BluetoothOverlay/AndroidManifest.xml [new file with mode: 0644]
rro_overlays/BluetoothOverlay/res/values/config.xml [new file with mode: 0644]

index 8ce994b348cd312529be5272b4b40d8a3ef40a48..3555dc972e6e984f72d73daef7404e1e0f53416b 100644 (file)
--- a/device.mk
+++ b/device.mk
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2022 The LineageOS Project
+# Copyright (C) 2022-2023 The LineageOS Project
 #
 # SPDX-License-Identifier: Apache-2.0
 #
@@ -8,6 +8,9 @@
 BOARD_HAVE_BLUETOOTH_RTK_TV := true
 include hardware/realtek/rtkbt/rtkbt.mk
 
+PRODUCT_PACKAGES += \
+    BeastBluetoothOverlay
+
 ## Init-Files
 PRODUCT_COPY_FILES += \
     $(LOCAL_PATH)/init-files/init.amlogic.wifi_buildin.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.amlogic.wifi_buildin.rc
@@ -16,10 +19,6 @@ PRODUCT_COPY_FILES += \
 PRODUCT_PACKAGES += \
     8822bs
 
-## Overlays
-DEVICE_PACKAGE_OVERLAYS += \
-    $(LOCAL_PATH)/overlay
-
 ## Platform
 TARGET_AMLOGIC_SOC := gxl
 
diff --git a/overlay/packages/apps/Bluetooth/res/values/config.xml b/overlay/packages/apps/Bluetooth/res/values/config.xml
deleted file mode 100644 (file)
index 0d9c979..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-<resources>
-    <bool name="profile_supported_opp">false</bool>
-    <bool name="profile_supported_hdp">false</bool>
-    <bool name="profile_supported_hs_hfp">false</bool>
-    <bool name="profile_supported_pbap">false</bool>
-    <bool name="pbap_include_photos_in_vcard">false</bool>
-    <bool name="enable_phone_policy">false</bool>
-</resources>
diff --git a/rro_overlays/BluetoothOverlay/Android.bp b/rro_overlays/BluetoothOverlay/Android.bp
new file mode 100644 (file)
index 0000000..e3d10f6
--- /dev/null
@@ -0,0 +1,11 @@
+//
+// Copyright (C) 2023 The LineageOS Project
+//
+// SPDX-License-Identifier: Apache-2.0
+//
+runtime_resource_overlay {
+    name: "BeastBluetoothOverlay",
+    resource_dirs: ["res"],
+    sdk_version: "current",
+    proprietary: true
+}
diff --git a/rro_overlays/BluetoothOverlay/AndroidManifest.xml b/rro_overlays/BluetoothOverlay/AndroidManifest.xml
new file mode 100644 (file)
index 0000000..d775401
--- /dev/null
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+     Copyright (C) 2023 The LineageOS Project
+
+     SPDX-License-Identifier: Apache-2.0
+-->
+<!-- Device specific bluetooth overlays -->
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.android.bluetooth.beast"
+    android:versionCode="1"
+    android:versionName="1.0">
+    <application android:hasCode="false" />
+    <overlay
+      android:targetPackage="com.android.bluetooth"
+      android:isStatic="true"
+      android:priority="0"/>
+</manifest>
diff --git a/rro_overlays/BluetoothOverlay/res/values/config.xml b/rro_overlays/BluetoothOverlay/res/values/config.xml
new file mode 100644 (file)
index 0000000..0d9c979
--- /dev/null
@@ -0,0 +1,8 @@
+<resources>
+    <bool name="profile_supported_opp">false</bool>
+    <bool name="profile_supported_hdp">false</bool>
+    <bool name="profile_supported_hs_hfp">false</bool>
+    <bool name="profile_supported_pbap">false</bool>
+    <bool name="pbap_include_photos_in_vcard">false</bool>
+    <bool name="enable_phone_policy">false</bool>
+</resources>