cc -c -std=c99 -pedantic -O2 -Wall -W -g -rdynamic -ggdb adlist.c
adlist.c:32:20: error: stdlib.h: No such file or directory
In file included from adlist.c:34:
zmalloc.h:34: error: expected ')' before 'size'
zmalloc.h:35: error: expected declaration specifiers or '...' before 'size_t'
zmalloc.h:38: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'zmalloc_used_memory'
adlist.c: In function 'listCreate':
adlist.c:45: warning: implicit declaration of function 'zmalloc'
adlist.c:45: warning: assignment makes pointer from integer without a cast
adlist.c:45: error: 'NULL' undeclared (first use in this function)
adlist.c:45: error: (Each undeclared identifier is reported only once
adlist.c:45: error: for each function it appears in.)
adlist.c: In function 'listAddNodeHead':
adlist.c:84: warning: assignment makes pointer from integer without a cast
adlist.c:84: error: 'NULL' undeclared (first use in this function)
adlist.c: In function 'listAddNodeTail':
adlist.c:110: warning: assignment makes pointer from integer without a cast
adlist.c:110: error: 'NULL' undeclared (first use in this function)
adlist.c: In function 'listGetIterator':
adlist.c:153: warning: assignment makes pointer from integer without a cast
adlist.c:153: error: 'NULL' undeclared (first use in this function)
adlist.c: In function 'listNext':
adlist.c:196: error: 'NULL' undeclared (first use in this function)
adlist.c: In function 'listDup':
adlist.c:224: error: 'NULL' undeclared (first use in this function)
adlist.c: In function 'listSearchKey':
adlist.c:267: error: 'NULL' undeclared (first use in this function)
make: *** [adlist.o] Error 1
To fix this:
$ sudo apt-get install libc6-dev
|
|