Before you can export Construct 2 or Construct 3 Cordova project to a native Android APP you will need install these following software :

  • Node.js
  • Apache Cordova CLI
  • Java SE Development Kit 8(JDK)
  • Android Studio
  • SDKMAN!
  • Gradle

If you already installed above following software then you can jump to Construct 2 & 3 to Android APK – Part 2.


Install Node.js & Cordova

Download Node.js from this link Download here
After install process finished check node.js installed, open terminal type:
npm -v

and the result should like picture below.

Check Cordova CLI Installed

Now install Apache Cordova, open terminal then type:
sudo npm install -g cordova

After install process finished check Cordova CLI installed correctly, type:
cordova -v

Result should like picture below.

Check node.js installed


Install Java SE Development Kit 8

Download Java SE Development Kit 8 on this link then select your operating system version. After finished installing Java SE Development Kit 8 then we add Java path to system environment.

After process installation finished, open terminal and type:

java -version

javac -version

If Java installed correctly you will see like picture below:

then type

touch .bash_profile

ls -al

open -e .bash_profile

On the text editor then add this text:

export JAVA_HOME=$(/usr/libexec/java_home)

then save (control x) and close the text editor and quit terminal.

Open terminal again for check JAVA_HOME path by type on terminal:

echo $JAVA_HOME

The result should like picture above.


Install Android Studio

Download Android Studio on this link, after download process finished then follow these steps:

Select Custom

Remember Android SDK location

 

Review Installation

After installation finished then click “Configure”

Select target platform API Level

Note: Since I am not targeting Android device below Android 5.0 (Lollipop) then I select API Level 21 to 28.

Next step is open terminal and type:

sudo nano /etc/paths

then add these following texts:

/users/your_user_name/Library/Android/sdk/platform-tools

/users/your_user_name/Library/Android/sdk/tools

See picture below for example:

After finished then press control x and exit. On terminal now type:

open -e .bash_profile

then add this text:

export ANDROID_HOME=/users/your_user_name/Library/Android/sdk

Save and exit then on terminal type:

echo $ANDROID_HOME

You should see SDK location like picture above.


Install SDKMAN!

I use SDKMAN! for installing gradle, on terminal type:

curl -s "https://get.sdkman.io" | bash

Open new terminal and type:

source "$HOME/.sdkman/bin/sdkman-init.sh"

and then check SDKMAN! installed:

sdk version


Install Gradle

Type on terminal:

sdk install gradle 5.0

After all steps done then you can continue read Construct 2 & 3 Build APK on macOS – Part 2


Creative Commons LicenseThis article is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.