new buildish system for documentjs
merging with toms change, overwritting it