setup-toolchains: detect location of ar and nm

Gcc's executables might be split among several directories. This is the
case when using e.g. an installed icecc. The toolchain's install path is
/usr/lib/icecc/bin but the archiver is in /usr/bin.

Task-number: QBS-528
Change-Id: I8f448b482bb00854a3144643e886634199d37012
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>