which: rewrite

function                                             old     new   delta
which_main                                           237     212     -25

Signed-off-by: Tito Ragusa <farmatito@tiscali.it>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
trylink: emit names of linked executables

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>