Register unit tests with CMake

Use add_tests() to register the test binaries with CMake
so they can be executed with 'make test'/CTest.

MD-19678 #time 10m
Enable building the updater with newer SDKs on Mac

 * Remove the CMAKE_OSX_DEPLOYMENT_TARGET setting and just
   rely on the -mmacosx-min-version argument.

 * Avoid requiring a specific OS X SDK version - just use the
   default one.
Enable customization of the tool used to sign the updater

Add a BINARY_SIGNING_TOOL CMake var which can be overridden to specify
a custom script/tool to use to sign the updater binary.
Fix build issues on Ubuntu 13.04

 * Add missing <unistd.h> include
 * Check for presence of bzip2 library

MD-19678 #time 10m
Replace use of deprecated pkgconfig() macro with find_package()

MD-19678 #time 15m
Fix updater test on Ubuntu 13.04

Set file permissions to match those specified in
the updater script or in the case of new-dir/new-dir2
the mode hard-coded into FileUtils::mkdir()