Can't get D calling C to build.

SK sk at metrokings.com
Thu Aug 19 16:56:05 PDT 2010


On Thu, Aug 19, 2010 at 2:46 PM, Jonathan M Davis <jmdavisprog at gmail.com> wrote:

> My first question would be whether you used the same linker for both D and C. On
> Linux, they should both be using gcc. On Windows, they should both be using dmc.
> Still, I would have expected a linking error to be a bit more explosive than
> nothing.
>
> - Jonathan M Davis

My experience has been the opposite - dmd is needed to link programs
that mix C and D.  While you may not want to jump into CMake for
builds, the regression tests for cmaked include building and link D+C
objects and D + C libraries.
http://code.google.com/p/cmaked2/wiki/GettingStarted
FYI, cmaked is still work in progress, so you might run into bumps.
-steve


More information about the Digitalmars-d-learn mailing list