Fixes compass race condition

This uses q's promises to defer compilation until compass is detected. Fixes #31.