On Sat, Oct 23, 2010 at 5:51 PM, Cesar Strauss <cestrauss@...> wrote:
> On 10/23/2010 01:39 PM, Luis Lavena wrote:
>> I was attempting to port a program from Linux to Windows where certain
>> functions are exported and used by plugin/extensions. Since the
>> program is not a shared object, there is no import library to link
> Dear Luis,
> Please find attached an example I made some time ago while answering a
> similar question.
> 1. Each plugin calls a function bar() that is in main.cc.
> 2. The interface in the plugin is done by the constructor of a static
> object, which sets the global "x" to point to it.
> Expected result:
> ./a.out.exe ./my_dll.dll
> ./a.out.exe ./my_other_dll.dll
> Hope this helps,
Thank you Cesar.
This helped me be able to export the symbols properly and also link
the extensions/plugins against the import library.
I've also tested adding more symbols without the need to recompile the
extensions/plugins and seems to be working properly.
Once again, thank you for your time and example.
Perfection in design is achieved not when there is nothing more to add,
but rather when there is nothing more to take away.
Antoine de Saint-Exupéry