Workaround missing os.path.samefile on Windows