Locking for event loops

Set up the given loop for mutex locking from haskell-land -- if you want
to touch the loop from other Haskell threads, you'll need to do this. The
two FunPtr objects returned need to be explicitly freed with
freeMutexCallback.

IMPORTANT: if you want multithreaded access to an EvLoopPtr, you'll have
to acquire the MVar returned here (using withMVar) whenever you call any
of the ev functions. Very bad C-land crash/bang/boom could otherwise
result.

ALSO IMPORTANT: any changes you make to an EvLoopPtr from another thread
while the event loop thread is blocked inside ev_loop() will NOT take
effect until the the event loop thread unblocks. You'll need to set up an
ev_async watcher in order to wake up the event loop thread.