Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Question Having trouble with merging AndroidManifest

Discussion in 'Android' started by AiR-Cord, Aug 1, 2023.

  1. AiR-Cord

    AiR-Cord

    Joined:
    Nov 15, 2018
    Posts:
    5
    I am developing an app for Android version 12, but I'm having trouble with the final merge of the AndroidManifest.
    I have set the value of android:exported to true in the AndroidManifest before building.
    However, when I check the merged file after the build, the value has become false.

    I performed the installation of the latest package after removing the Notification package from the package manager.Afterwards, I conducted the build, but the result remained unchanged.

    I would appreciate it if you could provide a solution. Thank you in advance.
     

    Attached Files:

  2. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    3,632
    Why are you setting it to true?
    Android 12 requires the attribute to be present, it's value can be either true or false. One sets this to true so that other apps can access it.
     
  3. AiR-Cord

    AiR-Cord

    Joined:
    Nov 15, 2018
    Posts:
    5
    Thank you for your reply.

    The other day, I uploaded a test app to the Google Play Store, but it was not approved due to not being able to explicitly set the value of android:exported.
    I misunderstood that I had to set the value of android:exported to true. Thank you for pointing that out.

    If it's enough for the attribute to exist, I don't understand the reason for the rejection. Could you please tell me what should be included in the AndroidManifest and if there are any other necessary steps?
     

    Attached Files:

  4. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    3,632
    The after build manifest has a bunch of other activities, probably coming from the manifest some plugins. And some of those activities don't have exported attribute on them.