Skip to content

Add --extra-manifest-application-xml for injecting elements inside <application> - #3377

Merged
kuzeyron merged 2 commits into
kivy:developfrom
copiousfish:feature/manifest-application-xml
Sep 10, 2026
Merged

Add --extra-manifest-application-xml for injecting elements inside <application>#3377
kuzeyron merged 2 commits into
kivy:developfrom
copiousfish:feature/manifest-application-xml

Conversation

@copiousfish

Copy link
Copy Markdown
Contributor

There's currently no way to add an arbitrary child element (like a , needed for e.g. a FileProvider) inside in the generated AndroidManifest.xml:

  • --extra-manifest-xml writes at the root, as a sibling of -- a there is invalid, providers must be nested inside .
  • --extra-manifest-application-arguments only splices into the <application ...> opening tag's attribute list, so it can't hold a full child element either.

This is a real gap: a FileProvider (needed to hand another app, e.g. a camera app, a content:// Uri instead of a file:// one and avoid FileUriExposedException on API 24+) requires exactly this kind of entry, and there's currently no supported way to add one without patching the rendered manifest after the fact via a p4a.hook.

Adds --extra-manifest-application-xml, rendered immediately before in every bootstrap's manifest template, alongside the two existing options.

…pplication>

There's currently no way to add an arbitrary child element (like a
<provider>, needed for e.g. a FileProvider) inside <application> in
the generated AndroidManifest.xml:

- --extra-manifest-xml writes at the <manifest> root, as a sibling
  of <application> -- a <provider> there is invalid, providers must
  be nested inside <application>.
- --extra-manifest-application-arguments only splices into the
  <application ...> opening tag's attribute list, so it can't hold a
  full child element either.

This is a real gap: a FileProvider (needed to hand another app, e.g.
a camera app, a content:// Uri instead of a file:// one and avoid
FileUriExposedException on API 24+) requires exactly this kind of
<provider> entry, and there's currently no supported way to add one
without patching the rendered manifest after the fact via a p4a.hook.

Adds --extra-manifest-application-xml, rendered immediately before
</application> in every bootstrap's manifest template, alongside the
two existing options.
@Novfensec

Copy link
Copy Markdown
Contributor

Thanks #3173

@kuzeyron
kuzeyron merged commit 32994be into kivy:develop Sep 10, 2026
38 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants