Hello,

yes, to interface between Pascal and C I use 'extern "C"'. I do not have 
any problems linking between my C code and the Pascal code.

The only problem is that the Pascal RTL uses DLL imports, which the 
Microsoft linker cannot resolve, for example:

unresolved external symbol _$dll$kernel32$Sleep

So again the question is how to enable the Microsoft linker to resolve
the DLL dependencies.

Cheers,
Tobias

> On 08/20/2015 12:27 PM, tobiasgie...@gmail.com wrote:
> > Hello,
> >
> > I have to compile a few Pascal units with FPC and add them to a Visual
> > C++ project.
> As the object structure (and supposedly the naming scheme for overloaded  
> functions) is different in fpc and C++ you can't link them (neither 
> statically nor dynamically).
> 
> You need to do  a "flat" interface between the parts of the project using 
> e.,g. STDCALL on either site.
> 
> -Michael
> _______________________________________________
> fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
> http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply via email to