Fixed inability to regenerate build under Windows:

- fixed windows paths to unix paths, so that slash can be used in all comparisons
- simplified algorithm by using recursive directory iterator