http://www.perlmonks.org?node_id=1018994


in reply to Re^3: openssh build with Strawberry Perl provided gcc
in thread openssh build with Strawberry Perl provided gcc

You need sh to run autotools, otherwise you're poking in the dark

Yes - but autotools are part of MSYS, not gcc .... and MSYS therefore finds those autotools irrespective of which gcc is being used.

I use different gcc compilers with MSYS all the time and it has never been an issue.
Mostly I'll download and extract a library source, do the ./configure dance, and end up with a 32-bit build of that library.
Then it's just a matter of:
make distclean export PATH=/c/_64/mingw/bin:$PATH
Then do the same ./configure dance and end up with a 64-bit build of the same library. (Needless to say, C:/_64/mingw/bin houses a 64-bit gcc.)
I have, on occasion, even used a Strawberry compiler to build a C library in this way in the MSYS shell - though, mostly, the "external" gcc compiler that I use is not actually one of the ones that ship with Strawberry.

And I did once ask kmx how he built gmp for x86 and x64 Strawberry - to which he replied "Same way as you".

Cheers,
Rob