Fix gnuplot detection so that it works when 'type' is a shell built-in.