deal with some unusual systems where $! doesn't work as expected