Fix shortest absolute paths from cwd to classmap path
Use cross-platform absolute path check
Cache getcwd() result
Merge pull request #1743 from sandermarechal/abs-path

Fix shortest absolute paths from cwd to classmap path