tests: prevent warnings with some make implementations

some make implementations don't like empty $(AM_V_GEN) rule
commands, see http://lists.gnu.org/archive/html/bug-coreutils/2009-04/msg00251.html
for more info.
build: use AC_LINK_IFELSE instead of AC_TRY_LINK

AC_TRY_LINK is obsolete...
build: prevent warnings during dist/distcheck

Make transforms tr '/' '\\' into tr '/' '\', leading to
tr: warning: an unescaped backslash at end of string is not portable
so double escape to make the warnings go away...