Affiliate Window App for Ubuntu
Today I'm pleased to announce that I have the Affiliate Window Stats app, that I previously built for Android devices, running on Ubuntu Touch devices too, namely my Bq Aquarius E4.5 Ubuntu Edition
The original app was built using the Phonegap/Cordova framework which has support for Ubuntu Touch as well as Android, iOS, Windows and Blackberry amongst others so it was possible to get the app running on Ubuntu Touch without having to touch a single line of code in the app itself. It did however involve some extra steps to create the click package that could be installed into Ubuntu.
The first step was adding the Ubuntu platform to my project
cordova platform add ubuntu
As the majority of mobiles run on the ARM architecture rather than x86 processors the app needed to be compiled as armhf binaries. As I don't have a development system running on an ARM processor I had to cross compile from my x86 desktop system which involved creating an armhf chroot for compiling armhf native code.
sudo click chroot -a armhf -f ubuntu-sdk-14.10 create sudo click chroot -a armhf -f ubuntu-sdk-14.10 install cmake libicu-dev:armhf pkg-config qtbase5-dev:armhf qtchooser qtdeclarative5-dev:armhf qtfeedback5-dev:armhf qtlocation5-dev:armhf qtmultimedia5-dev:armhf qtpim5-dev:armhf libqt5sensors5-dev:armhf qtsystems5-dev:armhf
Once the above steps were completed I connected the phone via USB to my PC and issued the following commands
cordova build --device cordova run --device
A few seconds later the app popped up on my phones screen.
One thing that did have me frustratingly going around in circles for a while was the fact that chroot wasn't working with my Documents directory due to the fact that I have it stored on a separate drive mounted at /data and then symlinked to /home/simon/Documents. Once I moved the directory of my phonegap application to my main hard drive it worked fine.
The app is now available to download from the Ubuntu app store. The original Android version can be found at http://www.affiliatestats.co.uk/