fix perl if for absolute paths