[configure] Check more directories for libgc.

Use a list and a for loop to find the gc library file. We now
also check in /usr/lib64 and /usr/local/lib64 by default.

If there are 32 bit systems that also have a lib64, there might
be issues with this if there is a /usr/lib64/libgc.* but we wanted
to find /usr/local/lib/libgc.* instead. I'm not sure that this
would be an issue in actual practice.

Fixes #833.
[configure] Don't always look for GC_LIBRARY.

We only need GC_LIBRARY set when we are using GC_USE_STATIC_BOEHM,
which is only the case by default on Mac OS X, which means that we
don't need to go through all of this logic on other platforms.
[configure] Reset some values when using MPS.

When using MPS, make sure that GC_LFLAGS, GC_LIBRARY and
GC_USE_STATIC_BOEHM are reset to the correct values.
[configure] Check that the -lgc is valid.

Also, only add ${with_gc_path} to CFLAGS / LFLAGS when it is set.
[configure] Don't always search default directories.

When searching for a static libgc, only look in the default directories
when --with-gc-path has not been given.
Merge pull request #834 from waywardmonkeys/configure-check-lib64

[configure] Check more directories for libgc.