Simplest way to build a DMD compatible C lib, and how to link using DUB.
hardreset via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Thu Dec 15 10:30:14 PST 2016
On Thursday, 15 December 2016 at 03:47:27 UTC, Mike Parker wrote:
> On Wednesday, 14 December 2016 at 23:08:30 UTC, hardreset wrote:
> As Basile recommended, DerelictFT[1] will save you from the
> hassle of object formats. It's a dynamic binding, so you don't
> need to link with FreeType at all during compilation. You
> simply call DerelictFT.load during initialization and it will
> load the FreeType DLL for you. However, if your goal is to use
> DLLs, then you either have to use the MS linker as I described
> above or get FreeType into the OMF format (either by compiling
> with DMC or using an object converter).
>
> [1] https://github.com/DerelictOrg/DerelictFT
Thanks, I'm trying the "-m32mscoff" method for now, but I get
"error LNK2019: unresolved external symbol _FT_Init_FreeType
referenced...."
I have pragma(lib,**fullpath**) in my freetype.d file, is that
the correct way?
More information about the Digitalmars-d-learn
mailing list