Clion will simply not autodetect Cygwin's GCC

I discovered this in Clion a few years ago, and hoped it has disappeared. Alas, it is still present. When I use Cygwin, Clion is incapable of detecting the gcc compiler. This is a particularly interesting bug because it can detect the Cygwin root path, C++, and GDB compilers just fine. It also accepts Cygwin's cmake executable as a replacement to the bundled Cmake, and it doesn't throw any fits. It builds projects and accepts the executable 100% correctly when I point the IDE to the C compiler manually. To be absolutely clear, this is true when using both cygwin's native gcc-core & gcc-g++ packages, as well as when using mingw-x86_64-gcc-core & respective g++ packages. So it's not like there's a problem with the build system at all, and the Clion-specific path'ing works. But autodetect of those paths, for the C compiler, does not. I get two slightly different messages that I can screen shot here when using the bundled cmake, and the Cygwin cmake.

 

Here is what I get

Cygwin's cmake

Bundled cmake

When I go hunting for this bug, I discovered that according to the windows file explorer, and according to dir/ls in the windows command prompt/powershell, the /bin folder inside /usr does not exist. It doesn't appear, it doesn't show....nothing. Of course, I have quickly discovered that the /bin that it is pointing to is the /bin dir that exists in the root directory of the cygwin installation. Perhaps this is a windows issue and not an intellij issue? Nonetheless, I am not sure how to proceed.

0
1 comment

Hello!

I didn't manage to reproduce the problem. I have Cygwin and the required packages (gcc-g++, make, gdb) installed according to https://www.jetbrains.com/help/clion/quick-tutorial-on-configuring-clion-on-windows.html#Cygwin.

The toolchain looks like this (everything is detected successfully):

A default "Hello, World!" project (`File | New Project` > `C Executable` > `Create`) is also loaded fine:

0

Please sign in to leave a comment.