Linker cannot find malloc and free on OS X

Stefan Koch via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sun Jun 4 03:59:46 PDT 2017


On Sunday, 4 June 2017 at 10:45:23 UTC, Nordlöw wrote:
> My gmp-d tests successfully on Linux as
>
> dub test
>
> but on OS X it fails as
>
> Undefined symbols for architecture x86_64:
>   "free", referenced from:
>   ...
>   "malloc", referenced from:
>   ...
>
> Any ideas on why?
>
> https://github.com/nordlow/gmp-d/issues/4#issuecomment-305974761

try giving it -lc


More information about the Digitalmars-d-learn mailing list