This is not exactly an answer, since I can't figure out exactly what your problem from the information provided. So, I need more space compared to that permitted by the "comment" box above (.. if SO moderators are upset by this, let me know, and I'll take down my submission).
First, what do you mean when you say "MinGW"? Do you mean:
1) you have built a proper MinGW environment and compiled all your code from scratch (e.g. following the excellent instructions such as these (http://ingar.satgnu.net/devenv/mingw32/index.html) )
2) You have download some Windows binaries for Glade etc?
3) You are using MSys2?
If you are using Msys2, I would be surprised for your Glade to be Gtk+ (2), as AlexPu (the head honcho at MSys2) has told me personally that he will not create a Gtk+ (2) variant of Glade, since he feels that would cause too much conflict with the Gtk3 variant. This means, on Msys2, the only way to have a (MinGW) Gtk+ (2) compliant Glade is to use the MSys2/AlexPu "create from scratch mystery mechanism". We have not ever been able to get that to build, not even with MSys2's help (and that process throws a lot of bash errors).
Therefore, one possibility is that you are using a Gtk3 Glade variant with Gtk2 code, which will never work, but that can't be the only "issue", see below.
Also, your reference to libs looks a bit different from what we would expect if you had proper MinGW Gtk+ machinery. For example, all of our Win/Gtk+ (2) apps, usually, would have to have at least the following libs required:
$(#gtk)\bin\libgtk-win32-2.0-0.dll
$(#gtk)\bin\libgdk-win32-2.0-0.dll
$(#gtk)\bin\libgobject-2.0-0.dll
$(#gtk)\bin\libglib-2.0-0.dll
... and usually many more for Pango, Cairo, etc.
These should be the same whether your compiled from scratch, or if just "installed via MSys2/pacman".
Of course, almost surely, there will be other dependencies, and "search paths" required, and various things must be on your "Path".
Second, your error messages are quite odd, and cite "bash" issues. That sounds more like "scripting/instruction" problems within whatever MinGW/Unix-like shell/system you are working in.
They don't sound like "proper Gtk crashes". Typically, Windows, will actually issue a SIGSEGV and also in the debugger log it will actually use the words "segmentation fault" etc. If the SIGSEGV is really nasty, Windows may not "say anything" explicitly (blank console, etc), and your GDB might see only "some mention" of "some" problem.
Also, if you are using Glade, then it is just an xml file that attempts to make your Gtk life easier. Gtk has code for interpreting the Glade xml files into otherwise virtual "Gtk code". Frankly, we have found that Glade is more trouble than its worth in many cases, and just writing the GUI via code is more efficient, again, often, not always.
Third, it is possible (we have done it) to use Glade based on Windows binaries, and link to libs therein, but that would be for the Glade libs, you would still need to obtain the (correct) Gtk+ libs.
As you can see, it is difficult to provide a precise answer without knowing more about your set up.
I would strongly recommend also that you do not run from the command line. It can be done, but there is much too much in the way of fiddly things that need to be "connected" to have Gtk/Glade/GCC etc all talking to each other correctly. I would strongly recommend installing Code::Blocks (http://www.codeblocks.org/); it's free and excellent (or some decent IDE). Then, you can very easily set up your paths/dependencies (after you have confirmed the existence of the dll's/lib's, and their exact path, versions, tc.).
Also, the CodeBlock's community has considerable experience integrating external packages (like Glade/GCC/Gtk etc).
Some, not all, MinGW dll's will include version numbers, right click the dll, click properties and look for, depending on your OS, "version" or "details" etc where the dll's version number is kept. All the Gtk ones will. Often, the file name also incorporates version number "indicator", but sometimes it's best to be sure.
BTW, if your Glade has a ver num > 3.8.5, then almost surely it's Gtk3.
Incidentally, had you coded everything "correctly" and supplied all the libs, etc etc. but some of the libs were Gtk2 while others were Gtk3 (and there are no other major problems), then Gtk itself would disallow it, and tell you it wont accept "mixed 2 and 3".
... as before, our experience with MSys2 has been an unhappy one. We have found that investing about a day or so and following "Ingar's instructions" (http://ingar.satgnu.net/devenv/mingw32/index.html) will provide you a built from scratch fully functioning Windows MinGW infrastructure with GCC/Gtk etc, and that you have complete control over, and know where everything is, and what everything does etc.
pkg-config --cflags --libs gtk+-2.0
by itself? – andlabsprogram as
meansthe program called "as"
then the assembler is segfaulting, which is all sorts of bizarre. What doesgcc --version
say? Whichpacman
packages did you install? – andlabs