configure.ac, vars.am: Use host-specific link options for test programs.