Homebrew pwd (rebased onto develop)



This is the same as gh-653 but rebased onto develop.

----

Two of the three commits from gh-574. Very minor modifications to the homebrew hudson script to be a bit more robust.

/cc @sbesson