[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [iiwusynth-devel] iiwusynth static lib on Windows
From: |
Peter Hanappe |
Subject: |
Re: [iiwusynth-devel] iiwusynth static lib on Windows |
Date: |
Thu, 25 Jul 2002 10:41:05 +0200 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.8) Gecko/20020205 |
Hi Stephane,
I don't have much experience making static libraries on Windows so
I can only guess. Are you sure the driver and the library use the
same malloc function? In particular, are they both compiled with the
same debug/optimization flags? Also, check that it is linked with the
same runtime library. In particular, verify that the both use the
multi-threaded or single-threaded one.I can't think of anything else
right now. Is it possible to step thru the code with a debugger?
Ahhh, yes! Because of the bad design of DirectSound, iiwusynth needs
a handle to the application or DLL instance (a HINSTANCE) to open
DirectSound. As a DLL, it obtains the handle in the DllMain function
in iiwu_dll.c. When you link to it as a static library, you will
have to set the hinstance variable explicitely before creating the
synthesizer. The function to call is iiwu_set_hinstance and is defined
in iiwu_dll.c.
Hope this helps.
(BTW, why not keep it as a DLL?)
Best,
Peter
Stephane Letz wrote:
Hi,
I'm trying to compile iiwusynth as a static libary on Windows. This
library is later used in a MidiShare driver.
I have some crash problems : allocation a new iiwusynth crash
immediatly, seems in a malloc call.
It there any specific compiler options to be used when compiling the
library? or any other issue to be considered?
Thanks
Stephane Letz
Grame: Centre National de creation musicale
9, Rue du Garet
69001 Lyon
Tel: 04-72-07-37-00
Fax: 04-72-07-37-01
Web: www.grame.fr
_______________________________________________ iiwusynth-devel mailing
list address@hidden
http://mail.freesoftware.fsf.org/mailman/listinfo/iiwusynth-devel