Added .gitignore.
Added support for building with pkgbuild and made it the default.