* configure.ac: better detection of how to pass version script to linker

This now also works on Illumos when using GNU ld

Fixes https://fedorahosted.org/augeas/ticket/289