From a09beb0542ea7b93ad1df6c2fd7bf5bb085a7db2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A1rcio=20Moreira?= Date: Mon, 25 May 2020 15:37:50 -0300 Subject: [PATCH 1/2] Update instalation.rst for Windows 10 --- docs/source/installation.rst | 41 ++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/docs/source/installation.rst b/docs/source/installation.rst index f93e143..a1845ab 100644 --- a/docs/source/installation.rst +++ b/docs/source/installation.rst @@ -27,6 +27,47 @@ Android on Ubuntu 18.04 (64bit) # add the following line at the end of your ~/.bashrc file export PATH=$PATH:~/.local/bin/ +Android on Windows 10 +~~~~~~~~~~~~~~~~~~~~~ + +To use buildozer in Windows 10 you need first to enable Windows Subsystem for Linux (WSL) and install a Linux distribution: https://docs.microsoft.com/en-us/windows/wsl/install-win10. + +These instructions were tested with WSL 1 and Ubuntu 18.04 LTS. + +With WSL and Ubuntu installed on your Windows 10 machine, open Ubuntu and run these commands: + +:: + + sudo apt update + sudo apt install -y git zip unzip openjdk-8-jdk python3-pip autoconf libtool pkg-config zlib1g-dev libncurses5-dev libncursesw5-dev libtinfo5 cmake libffi-dev libssl-dev + # Use here the python version you need + sudo apt install -y python3.7-venv + # Create a folder for buildozer + mkdir /mnt/c/buildozer + cd /mnt/c/buildozer + python3.7 -m venv venv-buildozer + source venv/bin/activate + python -m pip install --upgrade pip + python -m pip install --upgrade wheel + python -m pip install --upgrade cython + python -m pip install --upgrade virtualenv + python -m pip install --upgrade buildozer + # Add the following line at the end of your ~/.bashrc file + export PATH=$PATH:~/.local/bin/ + # Restart your WSL terminal to enable the path change + +Now you need to install the Windows version of ADB (Android Debug Bridge): + +- Go to https://developer.android.com/studio/releases/platform-tools and click on "Download SDK Platform-Tools for Windows". + +- Unzip the downloaded file to a new folder. For example, "C:\\platform-tools". + +Before Using Buildozer +---------------------- + +If you wish, clone your code to a new folder, where the build process will run. You don't need to create a virtualenv for your code requirements. But just add these requirements to a configuration file called buildozer.spec as you will see in the following sections. + +Before running buildozer in your code folder, remember to go into the buildozer folder and activate the buildozer virtualenv. TroubleShooting ~~~~~~~~~~~~~~~ From ff55af5a05d5495d1671b8cb260c775d82daacf5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A1rcio=20Moreira?= Date: Fri, 5 Jun 2020 21:32:33 -0300 Subject: [PATCH 2/2] Updated installation.rst avoiding duplication Updated Windows 10 installation instructions avoiding duplication --- docs/source/installation.rst | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/docs/source/installation.rst b/docs/source/installation.rst index a1845ab..7fdf780 100644 --- a/docs/source/installation.rst +++ b/docs/source/installation.rst @@ -1,3 +1,4 @@ + Installation ============ @@ -34,15 +35,16 @@ To use buildozer in Windows 10 you need first to enable Windows Subsystem for Li These instructions were tested with WSL 1 and Ubuntu 18.04 LTS. -With WSL and Ubuntu installed on your Windows 10 machine, open Ubuntu and run these commands: +After installing WSL and Ubuntu in your Windows 10 machine, open Ubuntu and do this: + +1) Run the commands listed on the previous section (Android in Ubuntu 18.04 (64-bit). +2) Run the following commands: :: - sudo apt update - sudo apt install -y git zip unzip openjdk-8-jdk python3-pip autoconf libtool pkg-config zlib1g-dev libncurses5-dev libncursesw5-dev libtinfo5 cmake libffi-dev libssl-dev # Use here the python version you need sudo apt install -y python3.7-venv - # Create a folder for buildozer + # Create a folder for buildozer. For example: C:\buildozer mkdir /mnt/c/buildozer cd /mnt/c/buildozer python3.7 -m venv venv-buildozer @@ -52,20 +54,20 @@ With WSL and Ubuntu installed on your Windows 10 machine, open Ubuntu and run th python -m pip install --upgrade cython python -m pip install --upgrade virtualenv python -m pip install --upgrade buildozer - # Add the following line at the end of your ~/.bashrc file - export PATH=$PATH:~/.local/bin/ # Restart your WSL terminal to enable the path change -Now you need to install the Windows version of ADB (Android Debug Bridge): +Windows Subsystem for Linux does not have direct access to USB. Due to this, you need to install the Windows version of ADB (Android Debug Bridge): - Go to https://developer.android.com/studio/releases/platform-tools and click on "Download SDK Platform-Tools for Windows". - Unzip the downloaded file to a new folder. For example, "C:\\platform-tools". Before Using Buildozer ----------------------- +~~~~~~~~~~~~~~~~~~~~~~ -If you wish, clone your code to a new folder, where the build process will run. You don't need to create a virtualenv for your code requirements. But just add these requirements to a configuration file called buildozer.spec as you will see in the following sections. +If you wish, clone your code to a new folder, where the build process will run. + +You don't need to create a virtualenv for your code requirements. But just add these requirements to a configuration file called buildozer.spec as you will see in the following sections. Before running buildozer in your code folder, remember to go into the buildozer folder and activate the buildozer virtualenv.