Make "dist/*.js" files for bower and npm

This PR is to make possible to build files of core both compat/nocompat in full and uglyfied versions. This is needed for Bower and maybe useful also for npm.

When running `grunt distBuild` 4 files will be generated and all will be tested with PhantomJS.

With this PR I added the build files with master at 1.5.0

closes #2596, closes #2548, closes #2115