I am adding a library to my project. It comes in the form of AAR . But it has a BroadcastReceiver that listens to BOOT_COMPLETED , starts the service. I do not want this behavior in my application. I would like it to start from the moment the application starts. (This part has already been done using AAR , I assume the user force stopped the application).
Is there a way to change my manifest; or tell Gradle not to merge my manifest (in which I would have to declare my activity in my own manifest, I think); or override their manifest and have android:enabled="false for BroadcastReceiver "?
I would also like to do this in a manifest or Gradle , because if I do this programmatically and if they install the application but never open it, the library service will start automatically the next time the user reboots their phone.
source share