Henk-Jan van Tuyl | 21 Dec 21:08 2012
Picon

Troubles with DLLs


L.S.,

I am having troubles with DLLs; my application (Haskell, C and C++) gives  
several messages about DLLs not being found. I added these one by one to  
the current directory. At a certain point there are just error messages  
about null pointers and "Segmentation fault/access violation in generated  
code". When I try to load my application in GHCi, I get more messages  
about missing DLLs, up to a point where GHCi refuses to load a library  
because of an unknown section (a bug to be solved in GHC 7.6.2). (Several  
other programs have the same problem.)

Now I am still stuck with a null pointer error message.
1) How can I find out which DLLs my application needs (and which  
package/library is to blame for it) and
2) how can I find the error location when the crash occurs in C/C++ code  
(it might be something else than a missing DLL of course)?

My system:
Windows XP + MinGW/MSYS
Haskell platform 2012.4.0.0

The application uses wxHaskell.

Regards,
Henk-Jan van Tuyl

--

-- 
http://Van.Tuyl.eu/
http://members.chello.nl/hjgtuyl/tourdemonad.html
(Continue reading)

Henk-Jan van Tuyl | 22 Dec 08:10 2012
Picon

Re: Troubles with DLLs

On Fri, 21 Dec 2012 21:08:43 +0100, Henk-Jan van Tuyl <hjgtuyl <at> chello.nl>
wrote:

> 1) How can I find out which DLLs my application needs (and which  
> package/library is to blame for it)

I have found a partial answer: cygcheck from Cygwin can list dependencies
on DLLs recursively, like this:

> cygcheck.exe .\BouncingBalls.exe
.\BouncingBalls.exe
     C:\WINDOWS\system32\KERNEL32.DLL
       C:\WINDOWS\system32\ntdll.dll
     C:\WINDOWS\system32\msvcrt.dll
     C:\WINDOWS\system32\SHELL32.DLL
       C:\WINDOWS\system32\ADVAPI32.dll
         C:\WINDOWS\system32\RPCRT4.dll
           C:\WINDOWS\system32\Secur32.dll
       C:\WINDOWS\system32\GDI32.dll
         C:\WINDOWS\system32\USER32.dll
       C:\WINDOWS\system32\SHLWAPI.dll
     C:\WINDOWS\system32\WSOCK32.DLL
       C:\WINDOWS\system32\WS2_32.dll
         C:\WINDOWS\system32\WS2HELP.dll
     C:\Haskell\Projects\X\wxc.dll
       C:\Haskell\Projects\X\libstdc++-6.dll
         C:\Haskell\Projects\X\libgcc_s_dw2-1.dll
etcetera.

If a DLL is not found, you will get a message like:
(Continue reading)


Gmane