views:

246

answers:

3

Hi, if I have a source of library written in C/C++ (lets say its libxml2), now I'd like to build it, and link it into the delphi application... I know it is possible, since Delphi Zlib does it ( http://www.dellapasqua.com/delphizlib/ ) ... But my question is, how to prepare those .obj files?

Thanks in advance m.

+4  A: 

You would need to use CodeGear's C++ compiler to produce compatible obj files for Delphi. Does your Delphi come with C++ Builder? Otherwise you could try the free (Borland) commandline version. Read more about this subject here.

Lars Truijens
I've already read that article. This however doesn't cover the topic of solving C standard library dependencies, I don't find it possible to re-implement so many C standard functions like open,read, recv, memcpy etc etc ... I believe there is a better solution than the one author did proposed.
migajek
Maybe it is best if update your question with this new information. Or ask a new question about this specific issue.
Lars Truijens
tip from Allen's article: add crtl.dcu to your project to solve core C RTL link issues.
Warren P
+2  A: 

I'd say that my answer for this question applies equally

Allen Bauer
Nifty tip! Adding the CRTL.DCU to your delphi app is kind of nifty.
Warren P
A: 
doron