Some codechanges, add some missing files and minor bugfixes.'