Automatically find bin directories
Some chanes from sourcetree