Libc functions undefined when linking

Ali Çehreli acehreli at yahoo.com
Tue Jan 4 18:26:41 UTC 2022


On 1/4/22 10:13 AM, Ben Jones wrote:

 > So I think I need to specify that I want to explicitly include libc when
 > I link it.  `-lc` didn't seem to work.

Did you add -lc and -lpthread on the linker line?

 > ld build/*.o -L. -lphobos2 -o build/executable

Ali



More information about the Digitalmars-d-learn mailing list