C-based DLL with P/Invoke


F

fyderniX

Hey;

First things first: I'm an ignorant student and have no clue what I'm
doing.

I'm trying to compile the open source fitz/muPDF library (C) used in
the Sumatra PDF Viewer (http://blog.kowalczyk.info/software/
sumatrapdf/) into a dll for use via P/Invoke (C#).

I'm using Visual C++ Express 2005. Everything seemed to work
fine,
and the plethora of .c and .h files compiled/linked with the following
options:

/Od /I "c:\Documents and Settings\eric\Desktop\AUCAS\AUCAS
\sumatra-06March2007\fitz\include" /I "c:\Documents and Settings\eric
\Desktop\AUCAS\AUCAS\sumatra-06March2007\ext\jpeg" /I "c:\Documents
and Settings\eric\Desktop\AUCAS\AUCAS\sumatra-06March2007\ext\zlib" /I
"c:\Documents and Settings\eric\Desktop\AUCAS\AUCAS
\sumatra-06March2007\ext\freetype231\include" /D "_WIN32" /D "WIN32" /
D "_WINDOWS" /D "_DEBUG" /D "DEBUG" /D "NEED_MATH=1" /D
"NEED_STRLCPY=1" /D "NEED_STRSEP=1" /D "_MBCS" /Gm /RTC1 /MTd /GR- /
Fo"Debug-fitz\\" /Fd"C:\Documents and Settings\eric\Desktop\AUCAS
\AUCAS
\sumatra-06March2007\Debug-fitz\fitzlib_d.pdb" /W3 /nologo /c /ZI /
TC /
wd4996 /wd4244 /wd4267 /wd4995 /FC /errorReport:prompt

However, when I try to call functions from the dll, the library is
loaded but the function is never found. Running 'Dumpbin.exe /
EXPORTS' on it shows a very short output and no method names.

Any help, or at least pointers to someplace which might help get me
started? Google never yields much on intermediate programming topics.

SigmaX
 
Ad

Advertisements


Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top