Disable AVX for LLVM 3.2 by default (#9391)

Due to a bug LLVM generates a C-like frame pointer prelude for functions
that use AVX instructions. This causes programs using the GHC calling
convention to crash, therefore we simply disable them. People that want
to use AVX should consider upgrading to a more current LLVM version.

Signed-off-by: Austin Seipp <austin@well-typed.com>
Fix detection of GNU gold linker if invoked via gcc with parameters

Previously the linker was called without any commandline parameters to
detect whether bfd or gold is used. However the -fuse-ld parameter can
be used to switch between gold and bfd and should be taken into account
here.

Trac #9336

Signed-off-by: Austin Seipp <austin@well-typed.com>