Subject: Re: Building DLL
From: "Gerrit P. Haase" <[email-masked]>
To: Maarten Boekhold <[email-masked]>
Cc: [email-masked]
Date: Fri, 9 Jul 2004 17:10:02 +0200

Maarten wrote:

> Gerrit P. Haase wrote:

>> You don't need .def files on Cygwin.  Just add -no-undefined to
>> libxyz_LDFLAGS.

> OK, I'm making progress with getting XFCE to compile under cygwin (with
> help of one of the XFCE developers), but now we're running into the 
> following:

> XFCE has a plugin mechanism, based on shared libraries. These plugins 
> use functions/symbols from the program that they 'plug in to'. I.e. if I
> have appA, and libB is a plugin for appA, then libB contains calls that
> are defined in appA.

> How do I get this to work under cygwin? Obviously I can't link libB 
> against appA!

Put all the functions into a library.  Link the application and the
modules against this library (building only the appA's main() into
the executable).

It was also reported that creating an import library (or stub library)
for the executables functions is sufficient if it is linked in, IIRC it
was the same problem with naim & plugins.  Maybe there are some useful
hints in the naim sources.

Gerrit
-- 
=^..^=                                     http://nyckelpiga.de/donate.html

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/