I'm linking *.a file
with *.c file
, so I have used the following command:
gcc abc.c -l ad.a
(here abc
is the C source file and ad is the static library file)
then after executing the following error message is coming.
the library lad.a
not found.
-l
. Trygcc abc.c libad.a
, or whatever the actual static library name is. Just pretend the library is another object file. – jw013 Oct 13 '14 at 2:33gcc abc.c -L . -lad
– o11c Oct 13 '14 at 2:51gcc -ansi -Wpedantic -std=c++11
, of course you can choose anotherstd
. – PersianGulf Oct 13 '14 at 2:54