Allow the gradle file templates to be overridden in python-for-android
#8
Replies: 7 comments 19 replies
-
Please explain in more detail. How are they "hidden"? How would they be "exposed"? What hurdle are you facing? |
Beta Was this translation helpful? Give feedback.
-
I think @baseplate-admin has a good point, this is what I would suggest (and why it would not be a good suggestion!!): I would like to kill almost all the buildozer.spec Baroque because buildozer.spec has too many options. The growth of these options has been organic, there is no big picture. And the two lines of text are insufficient to document the behavior they implement, unless you already know. Backwards because most of the time when I want to set some unusual option it it because I read about it in the Android documentation and it is documented there in terms of AndroidManifest.xml code. Sooo I go to the template in p4a, find the option that is in the right place, then look in buildozer.spec for that option name. The process is backwards, and depends on knowing where to look in p4a. Unfortunately I think this suggestion would create a long term support problem. If p4a developers want to change AndroidManifest.xml then there is no backwards compatibility for existing apps with an updated p4a. And a version tag would give app owners a surprise update task. I did consider the better documentation approach. And concluded that would be the template AndroidManifest abstracted in some way and annotated with 'this option goes here'. But documenting our abstraction by removing it is a soul destroying task, as it seems to indicate a fundamental problem with the abstraction. So I don't think I have a good suggestion. But I do think there is an issue. |
Beta Was this translation helpful? Give feedback.
-
The main Android app I want to build cannot be build by Buildozer/p4a, because the templates can't be used to make the right Android Manifest. The solution I am thinking of (and have no concrete plans to implement) is ANOTHER BuildSpec option (with the obligatory 2 line explanation 😉) which is a pathname to a manifest xml that completely overrides all the other options and simply substitutes in the provided file. I wonder if a similar option will satisfy @baseplate-admin. [I confess I have no idea what "Projects flutter exposes them in an android folder" and the given error log means.] |
Beta Was this translation helpful? Give feedback.
-
Yes, I can see this. In my world I thought about this as an old/new transition flag (More detail than was needed above). But yes, this is at least a catchall. The support answer is then always yes 🙂 |
Beta Was this translation helpful? Give feedback.
-
The current workflow can be easily modified by having the to be used manifest file being put in some designated easily accessible folder by buildozer and use that file for future changes and builds. Also, we can have another thing to be added in buildozer is to follow the spec of android manifest as theres only a handful of directives to be used we can may be expose just one arg in buildozer spec that can take up any of such xml scripts or files and put them in to the relevant manner. But then this might end up being more complicated then to have just the manifest being rendered once and put into a folder with ease of access and being used during the build. This will need to change just two path lookup behaviours but for end users it wont feel any different. for advanced users they can utilize it though. |
Beta Was this translation helpful? Give feedback.
-
Hi, Is this on the roadmap? Not being able to modify the p4a files seems to be a roadblocker for my project. Any way i can contribute that fix? |
Beta Was this translation helpful? Give feedback.
-
@baseplate-admin if you need to replace AndroidManifest directly, I explained how to do it here on this repo. The only issue is that you need to compile the app first, then enter on the This is what I need to do every time I need to modify Or we could build a GUI program using Kivy and package it to all desktop systems, this GUI would show all these options from |
Beta Was this translation helpful? Give feedback.
-
While hiding everything behind
p4a
seems like a good idea at first, for those of us who have complex requirement, this becomes a hurdle.Please expose the template files in here
https://github.com/kivy/python-for-android/tree/fbe9fe496363c5b46427407b3a5c59099e02cfbc/pythonforandroid/bootstraps/common/build/templates
Beta Was this translation helpful? Give feedback.
All reactions