Linking include files in gcc

I never remember what to enter when linking included files to GCC, in fact the only thing I can remember is -lmfor math.h. The only thing I'm talking about right now is this sys/time.h.

This page clears some of them, but I still need a list.

Does anyone know a good list of links?

EDIT:

Perhaps my question was not clear. I want to know what I need to enter at the command line (for example, -lmfor mathematics or -lpthreadfor pthread) for various libraries that I may need for communication when creating C programs.

+3
source share
2 answers

, <sys/time.h>, libc.so ( C). , gcc libc.so . " " , , , .

-l GCC .

, gcc

, - libm ( -l m -lm) GCC.a >

+1

, , -lm ld , -l - -lx libx.a( .so, ). ld .
, , , libc.so(.a) (-lc)

0

Source: https://habr.com/ru/post/1777768/


All Articles