realPath() fixed

Fix realPath() to correctly handle non-relative symlinks

For example if /usr/bin/haxelib is symlink to /usr/lib/haxe/haxelib, original realPath() will return incorrect path - /usr/bin//usr/lib/haxe/haxelib

This patch fixes it, and now realPath() will return correct path - /usr/lib/haxe/haxelib