Switched to appbundler for building distribution files for MacOSX

Originally based on #1665.

The appbundler used on build.xml includes the patch from Haavar Valeur to fix version number and file associations. The patched source code is available here:

https://github.com/arduino/appbundler
https://github.com/arduino/appbundler/commits/arduino

Close #1665