Re: OK to stop using .def files for Windows builds with gcc?



On 15/10/2003 6:47 AM, Tor Lillqvist wrote:

Espen Harlinn writes:
> Could you not use dlltool/pexports to generate the def files and put
> them into the ditribution?

Yes, something along those lines is what people have suggested. I
particularily liked Owen's suggestion:

> I don't think it would be too hard to set things up so that
> on Linux, 'make check' makes sure that all exported symbols for
> libgtk are listed either in gtk.defs or in a gtk-exclude.defs.

I think it could be set up so that no .def files would be in CVS, but
they would be generated when a new GLib etc release is built (on a
Linux machine), and then included in the official source tarballs.

But this would mean that an "official" .def file would be available
only after each new release of GTK. When I and others build from CVS
before that, and want to be able to use new functionality not yet in
the .def file from the previous release, would ld's auto-export then
have to do?
Did you modify the configure script to pass -export-symbols-regex for windows builds when doing this test?

Looking at libtool.m4, it looks like it invokes "dlltool --export-all --exclude-symbols DllMain 12,... --output-def filename objects ...", then cleans up the resulting file to look like a symbol list. This list is then grepped with the symbol regex to form the final exports list.

Although I haven't tried it, it looks like this code should produce the same results as the Unix build (modulo gtk_plug/socket symbols, etc).

James.

--
Email: james daa com au
WWW:   http://www.daa.com.au/~james/






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