On Tue, 4 Aug 2009, Greg Peter wrote: > Hello, > > I am trying to build LDD3 sample code, just to get expirement around. > (Obtained from the link -> > http://oreilly.com.cn/codeexample/ldd3/examples.tar.gz). > > But I get the following errors when I run make: (PS note, I have the kernel > source and headers installed) > > > #examples> make > for n in misc-progs misc-modules skull scull scullc sculld scullp scullv > sbull snull short shortprint pci simple usb tty lddbus; do make -C $n || > exit 1; done > make[1]: Entering directory `/home/gregp/examples/misc-progs' > cc -O2 -fomit-frame-pointer -Wall > -I/lib/modules/2.6.27.23-0.1-pae/build/include setlevel.c -o setlevel > setlevel.c:30: error: expected declaration specifiers or ?...? before ?syslog? > setlevel.c:30: error: expected declaration specifiers or ?...? before ?type? > setlevel.c:30: error: expected declaration specifiers or ?...? before ?bufp? > setlevel.c:30: error: expected declaration specifiers or ?...? before ?len? > setlevel.c:30: warning: data definition has no type or storage class > setlevel.c:30: warning: type defaults to ?int? in declaration of ?_syscall3? > setlevel.c: In function ?main?: > setlevel.c:41: warning: implicit declaration of function ?syslog? > make[1]: *** [setlevel] Error 1 > make[1]: Leaving directory `/home/gregp/examples/misc-progs' > make: *** [subdirs] Error 1 those userspace programs still use the now-deprecated and unsupported _syscall macros. they should be rewritten to use syscall() instead. see: http://www.kernel.org/doc/man-pages/online/pages/man2/_syscall.2.html rday -- ======================================================================== Robert P. J. Day Waterloo, Ontario, CANADA Linux Consulting, Training and Annoying Kernel Pedantry. Web page: http://crashcourse.ca Twitter: http://twitter.com/rpjday "Kernel Newbie Corner" column @ linux.com: http://cli.gs/WG6WYX ========================================================================