Based on the output of the identify-compilers.sh script below, it appears that the following C compilers are available on Cygwin. Those labeled "Cygwin" require the cygwin1.dll file to be available.
What is the difference between the "pc" and "w64" compilers?
Why is there no x86_64-pc-mingw-gcc.exe executabe?
Are there any other C compilers available?
/usr/bin/gcc.exe 64-bit Cygwin
/usr/bin/i686-pc-cygwin-gcc.exe 32-bit Cygwin
/usr/bin/i686-pc-mingw32-gcc.exe 32-bit
/usr/bin/i686-w64-mingw32-gcc.exe 32-bit
/usr/bin/x86_64-pc-cygwin-gcc.exe 64-bit Cygwin
/usr/bin/x86_64-w64-mingw32-gcc.exe 64-bit
$ cat identify-compilers.sh
#!/bin/bash
for c in $(ls -1 /usr/bin/*gcc.exe); do
echo === compiler: $c
$c -o hello.exe hello.c
objdump -p hello.exe | grep -i "cygwin"
objdump -p hello.exe | grep -i "64$"
rm hello.exe
done