1

I am trying to build an android app using buildozer. On my windows 10 device, I am running python 3.9.6, and I've installed buildozer version 1.2.0 and kivy version 2.0.0.

Problem is that when I press buildozer init in my folder NewApp, there is no bin folder or .buildozer folder created there. It just creates a buildozer.spec file. Now that I wish to access buildozer templates, I am having trouble finding them since there is no folder named .buildozer in the root folder NewApp.

Martund
  • 291
  • 1
  • 8
  • According to the [documentation](https://buildozer.readthedocs.io/en/latest/quickstart.html#init-and-build-for-android), that's what `buildozer init` is supposed to do. – John Anderson Jul 02 '21 at 02:34
  • Oh @JohnAnderson, seems like it has changed since [this](https://www.amazon.com/Building-Android-Python-Using-Studio/dp/1484250303) book is written. Can you please tell how do I access the templates then? – Martund Jul 02 '21 at 02:53
  • I suggest following the instructions in the above mentioned documentation. – John Anderson Jul 02 '21 at 03:17

2 Answers2

2

Buildozer is always that way. That book might have missed saying that you need to build it once before you can access .buildozer folder and its contents.

If you want to access buildozer template or want to play around p4a contents, you need to build it once, doesn't matter if it fails.

You can build using below commands depending upon what you're targeting inside your project folder where you have buildozer.spec file.

  • If creating for Android,
buildozer -v android debug
  • If targeting iOS,
buildozer -v ios debug
watney
  • 141
  • 1
  • 5
  • Where do I have to use this command (in cmd as well as in python environment, both are showing error)? Also, would that command work in windows? – Martund Jul 03 '21 at 04:15
  • You need to run this command in terminal inside your project directory where you've your `buildozer.spec` file. You'd need WSL on windows for buildozer to work. – watney Jul 03 '21 at 07:26
  • Even that doesn't work, see [this](https://i.stack.imgur.com/tTjhw.png). – Martund Jul 03 '21 at 09:11
  • I see. Must be something to do with Windows. I personally don't have any experience using bulldozer on windows but I've seen people in Kivy community claiming to use bulldozer usin WSL. – watney Jul 03 '21 at 16:09
  • Similar problem here: https://stackoverflow.com/questions/47176947/buildozer-unknown-command-target-android-old You may want to ask this in the community on discord – watney Jul 03 '21 at 16:09
  • Ok, seems like what I want to do isn't possible on windows. – Martund Jul 04 '21 at 10:10
0

You have to create a virtual machine on your PC. The VM (Virtual Machine) should be running on Linux (Ubuntu). WSL(2) still have a lot of problems. You can then install Buildozer on Ubuntu easily. Once installed, you can execute build by running the the following command on the terminal : buildozer -v android debug

Rey Monta
  • 31
  • 3