Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 1
    In other words, if which gcc doesn't show /usr/bin/gcc or /bin/gcc, you need to either install Cygwin's gcc-core package, or fix your $PATH. Commented May 22, 2014 at 4:41
  • When I run inline where gcc, it tells me C:\MinGW\gcc.exe. I forgot I installed MinGW (gcc is 4.8.1) and am not using Cygwin default gcc.exe - a fact that might have been useful. /cygdrive/c/MinGW/bin is on my PATH (as evidenced by the where command). So it's a potentially different compiler than I reported, but the problem still seems to violate way the -I argument and #include are suppose to work together. Commented May 22, 2014 at 6:13
  • 3
    @GregYoung That's definitely the problem then. You have the MinGW version of gcc (which uses Windows path names), and are expecting that to work with Cygwin path names. It won't. You will need to either: (a) change your -I options to use Windows path names like MinGW-gcc expects, or (b) use the Cygwin build of gcc. Commented May 22, 2014 at 20:53
  • @GregHewgill That was it! Thanks! Not only does MinGW use Windows paths, but Cygwin installs the DBus headers in different locations. So my new makefile, which works both with Cygwin/MinGW and Mer/gcc, has separate INC defines based on ifeq ($(OS),Windows_NT) to detect Cygwin/MinGW. Commented May 23, 2014 at 3:06