added license headers etc.