Support cross-compiling

Upstart builds nih-dbus-tool and then expects to use it during the build
process, so we need to make sure that it's built for the build
architecture rather than for the host architecture.  Since this also
requires doing two builds of libnih and libnih-dbus, this is
unfortunately painful to do with Automake, but just about possible if
we're prepared to duplicate much of Automake's default compile and link
rules in custom targets.

Fortunately, we won't need to maintain this forever.  Lucid has a
separate source package for libnih, so when we move up to that we can
just build-depend on the native nih-dbus-tool.  With the stable Karmic
release, we seem to need something of about this level of complexity.

Review URL: http://codereview.chromium.org/549070
22 files changed