From: Henrik S. <hst...@pr...> - 2001-05-29 20:05:01
|
aj <aj...@oi...> wrote: > what do i do in my program to tell the operating system to > load the DLL's, so my program can access them. Either you use the win32 API call LoadLibrary() to load the DLL or you do like most people and create an import library which loads the DLL for you and creates wrappers for all the DLL content so you can easily access it. > i presume when i write an allegro dll'ed program, allegro > must tell the operating system how to find the correct dll.. nope! allegro doesn't tell windows anything. windows loads the DLL from either the local directory, the /windows/system folder or a predefined directory using LoadLibraryEx() IIRC. > where in the /allegro/src do i find this, i want to learn > how to do it, and would like some sample code. you didn't tell me what compiler you use so i will simply assume you use mingw. a simple example on how to make and use DLLs can be found here: ftp://ftp.franken.de/pub/win32/develop/gnuwin32/mingw32/porters/Khan_Mumit/m isc/dllhelpers-0.2.5.zip i also recommend that you visit http://msdn.microsoft.com and read through their docs on dynamic link libraries. Sincerely, Henrik Stokseth. |