0

I'm trying to compile my GTK+ 3 (using gtkmm3) program under windows. After setting everything up, I now get the following error:

Error: Aggregate »GStatBuf sbuf« has incomplete type and cannot be defined
 GStatBuf sbuf;

The same code compiles fine under linux. Here is the Code that causes the trouble:

            GStatBuf sbuf;

            if(g_stat(some_c_string, &sbuf) == 0) {
                some_var = sbuf.st_mtim.tv_sec;

I'm compiling my program using the following command:

/usr/bin/g++ Patte.cpp -o Patte -L/opt/lib `pkg-config gstreamer-1.0 gstreamer-video-1.0 gtkmm-3.0 --cflags --libs`

I would appreciate any help on this issue :)

Edit: The error occurs pretty deep into the program, so I am pretty sure that nothing that is included is missing.

tagelicht
  • 467
  • 3
  • 14
  • 1
    In your earlier question you decided to use the 64-bit MinGW toolchain, so you should be using the `g++` command (which resolves to `/mingw64/bin/g++.exe`) – David Grayson Nov 25 '18 at 06:10
  • You should post your full file so we can see which headers you included. Bettter yet, make a [mcve]. – David Grayson Nov 25 '18 at 06:12
  • When I tried using the raw g++ commans after installing the toolchain, I would get an error "spawn: No such file or directory", but strangely, now it works and which g++ also tells me the path u mentioned :) Maybe I should have closed and reopened the shell? Whatever, now the error I mentioned is gone, I'm getting others instead but I'll try to resolve them now. So thanks again :) – tagelicht Nov 25 '18 at 15:26

0 Answers0