Changed the filesystem code to be based on Boost.Filesystem to provide a better underlying compatibility layer.