improved build-file, cleaned code