Improve rebuild to work if there is a folder with the same name as a haxelib, which is not a build directory