My WebOS Makefile

One of the first things I do when developing with a new framework is automate as much as I can. When it comes to automating builds, GNU Make is still king of the hill. Sure, it has a notoriously finicky syntax. But when you know what you’re doing no other tool can express dependency information as concisely as Make.

I thought I’d post the Makefile I’ve been creating as I work on my first WebOS app. It’s definitely a work in progress, but it’s capable of building packages, launching the emulator, launching novacomd as a background job, and reloading the app. I’ve tried to get the dependencies right so that altering any part of the app forces a package rebuild before installing.

Note, this makefile is for Webos SDK 1.2 on an Ubuntu system. It will probably require some small modifications to work on an OS X system.

The Makefile, along with a small helper script for launching novacomd, can be found at http://gist.github.com/212448. Please let me know if you find it useful!

EDIT: I realised there’s one part of the Makefile which might not be immediately clear. In order to keep things DRY, I have the Makefile be the sole source of the app version (in the VERSION variable). Then I generate the appinfo.json file from a template (appinfo.json.m4) using the GNU M4 macro processor and passing in the app version.

4 comments

    1. Heh. Truth is, I wrote all that weeks ago, and as I was looking over my project today I realised it might be of use to someone else. It's certainly nice to know someone else doing Webos dev, though.

Leave a Reply

Your email address will not be published. Required fields are marked *