Fixed basename command to be compatible with old style basename call without -s parameter