DLL Errors - Running Program in CLion using Cygwin

Hi there,

I've used CLion to build a C program on windows 8 using the cygwin configuration. This program links to a third party library I installed under cygwin present in /usr/local/bin

There are no build issues. Running the program in a cygwin terminal works correctly. I can even double click in explorer and the program runs fine.

However using the Run button in CLion displays

     Process finished with exit code -1073741515 (0xC0000135)

0xC0000135 is an error code on windows for "STATUS_DLL_NOT_FOUND".

The third party library was installed in /usr/local/bin as cygallegro-5.0.dll
CLion's cmake is currently linking to /usr/local/lib/liballegro.dll.a , which is correct for how I understand cygwin works wrt to dll's.

My windows PATH enviornment variable includes C:\cygwin64\bin and C:\cygwin\usr\local\bin,

I'm not sure how else to get CLion to run my compiled program, especially considering that it runs fine within and outside of cygwin.

Any ideas?

- Aaron

Comment actions Permalink

To make it simple, copying cyggcc_s-seh-1.dll, cygstdc++-6.dll, cygwin1.dll from $CYGWIN$\bin to C:\Windows\System32 solves this problem.

I know you probably have set the PATH environment variable. But still, give it a try. :)

Actually, I reported this problem about 3 months ago: https://youtrack.jetbrains.com/issue/CPP-938.

Comment actions Permalink

Thanks for reminding, it's on our radars now


Please sign in to leave a comment.