From: Michael R. <re...@eu...> - 2004-10-17 09:32:13
|
Hi Luis, > Ok, here it goes my first try to support I2C: > This is a huge mess, because i'm working on a CVS version of some weeks > ago. > Since the functions were empty, I think i'm not stepping on anyone's toes. I tried to apply your "patch", it worked, but it does not compile. I'm afraid there's a problem with the i2c.h include. That's what I get when I do a make: gcc -DHAVE_CONFIG_H -I. -I. -I. -I/usr/X11R6/include -D_GNU_SOURCE -Wall -W -g -O2 -c drv_HD44780.c In file included from /usr/include/linux/sched.h:12, from /usr/include/linux/module.h:10, from /usr/include/linux/i2c.h:31, from drv_HD44780.c:216: /usr/include/linux/jiffies.h:16: error: parse error before "jiffies_64" /usr/include/linux/jiffies.h:20: error: parse error before "get_jiffies_64" In file included from /usr/include/linux/cpumask.h:8, from /usr/include/linux/sched.h:15, from /usr/include/linux/module.h:10, from /usr/include/linux/i2c.h:31, from drv_HD44780.c:216: /usr/include/linux/bitmap.h: In function `bitmap_empty': /usr/include/linux/bitmap.h:15: error: `BITS_PER_LONG' undeclared (first use in this function) /usr/include/linux/bitmap.h:15: error: (Each undeclared identifier is reported only once /usr/include/linux/bitmap.h:15: error: for each function it appears in.) and so on... The first error is a missing "u64" declaration, which is defined in asm/types.h, but only if the symbol __KERNEL__ is defined (which is not in a userspace program) I commented out all failing sections in the driver with a #if 0, and checked in the driver. Maybe you want to have a look at it, and find out how to make it compile cleanly. bye, Michael -- Michael Reinelt <re...@eu...> http://members.eunet.at/reinelt GPG-Key 0xDF13BA50 ICQ #288386781 |