Merge pull request #1 from pohly/master

Python 2.7 support
libffcall -> libffi

This replaces libffcall with libffi for binding the PyObject callback into
the plain C callback for the Crosswalk engine.

The advantage of libffi is more active maintance (?) and wider range
of projects using it, the more liberal license, and availability
(Tizen has libffi, but not libffcall).
adding some disabled logging

These printf()s were useful when debugging why Cloudeebus was unable
to process incoming D-Bus communication. Instead of adding them
manually each time they are needed, let's keep them in the code,
disabled via a single define.
enable multithreading

Python is single-threaded by default and crashes (when using an
unitialized semaphore) respectively blocks (when the main thread still
holds the Python global interpreter lock when it is outside the
pycrosswalk extension).

To avoid this, pycrosswalk must initialize multithreading and be more
careful about entering/leaving methods using Python.

The thread in which XW_Initialize() gets called becomes the main thread.
It must release the global lock when returning to Crosswalk and restore
it when called again. Otherwise Python code called by other threads cannot
run. The assumption is that Crosswalk will always call the extension from
the same thread.

Without this thread support, pycloudeebus in xwalk-launcher does not work:
the main thread is running the glib event loop in which twisted reacts
to D-Bus calls, while the second thread runs a Crosswalk event loop and
would hold the Python lock if we didn't release it.