Skip to content

Add --permission to SDL2 bootstraps #458

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 3, 2015
Merged

Conversation

str4d
Copy link
Contributor

@str4d str4d commented Sep 14, 2015

A more complete setup might try to factor out the commonalities between the three bootstraps (pygame, sdl2 and sdl2python3), but for now this at least allows permissions to be specified for SDL2 bootstraps.

@inclement
Copy link
Member

At one point I started out to factor out the common stuff using a build.py jinja2 template, but eventually decided it wasn't actually worth it since it seemed either very fiddly (factoring out in a fine grained way) or not really doing much (just factoring it into large blocks that were mostly duplicated anyway). I'm happy to do it if someone wants to, but it made me think it's not a priority, unless maybe we somehow get several very similar bootstraps.

Anyway, seems good, I'll check it later.

@inclement
Copy link
Member

It seems you don't actually use the --permissions optio for anything, so they can be specified but are ignored. Is this correct?

@str4d
Copy link
Contributor Author

str4d commented Oct 1, 2015

Incorrect. The --permissions options are rendered in AndroidManifest.xml.tmpl, and must be specified if any Android permissions are required. I made this PR because, to get Twisted to run, the INTERNET permission was required.

@inclement
Copy link
Member

Oh, okay, I didn't remember copying it. Thanks.

On 02/10/15 00:21, str4d wrote:

Incorrect. The |--permissions| options are rendered
https://github.com/str4d/python-for-android/blob/permissions/pythonforandroid/bootstraps/sdl2/build/build.py#L262
in |AndroidManifest.xml.tmpl|
https://github.com/str4d/python-for-android/blob/permissions/pythonforandroid/bootstraps/sdl2/build/templates/AndroidManifest.xml.tmpl,
and must be specified if any Android permissions are required. I made
this PR because, to get Twisted to run, the |INTERNET| permission was
required.


Reply to this email directly or view it on GitHub
#458 (comment).

@str4d
Copy link
Contributor Author

str4d commented Oct 1, 2015

Yeah, the code to use permissions is all there, all that was missing from SDL2 was the command-line arguments.

inclement added a commit that referenced this pull request Oct 3, 2015
Add --permission to SDL2 bootstraps
@inclement inclement merged commit 99d7e93 into kivy:revamp Oct 3, 2015
@inclement
Copy link
Member

Super then, thanks.

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.

2 participants