Re: MinGW Build




On Nov 30, 2005, at 12:54 PM, Timm Murray wrote:

I'm trying to build Gtk2-perl on MinGW. I have a Perl compiled with MinGW under "E:\perl-5.8.7", and MinGW itself and the Gtk2 libs are under "E:
\msys\1.0\mingw".

It's being linked with the command below. Note that it's linked using g++ because Perl itself (for some reason) is linked using g++ when built with
MinGW, and so all xs modules also get linked using g++.

[snip]

But this gives these errors:

----
xs/Gdk.o(.text+0x75):Gdk.c: undefined reference to `gperl_argv_new'
xs/Gdk.o(.text+0x9a):Gdk.c: undefined reference to `gperl_argv_update'
xs/Gdk.o(.text+0xa2):Gdk.c: undefined reference to `gperl_argv_free'
xs/Gdk.o(.text+0x1d8):Gdk.c: undefined reference to `gperl_argv_new'
<snip about 4000 more>
----

And that's where I'm stuck.

Win32 does not allow unresolved symbols at link time. The symbols you need are exported by the Glib.dll built by the Glib perl module; you need to find that dll and add it to the link command. This is done for you with the MSVC toolchain by extra code in Gtk2/ Makefile.PL. Poke around in that and you should find the necessary pieces. Please post your solution, preferably as a patch, and we'll see about keeping this solved for future MinGW adventurers.


--
Examples really shouldn't include unexploded ordnance.
  -- Joe Smith, referring to an example program i wrote.




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]