Fix support for basename in working dir