Jump to content

Recommended Posts

Posted (edited)

Hi,

 

I've been trying to compile a c program with GCC and have been unable to move past various errors related to file functions that should be declared in fs.h

I have installed (several times!) linux-headers-5.7.15-sunxi, made scripts, pointed the make file to ARCH=arm (not really necessary I know) and KSRC=/usr/src/linux-headers-5.7.15-sunxi/.

In the fs header in /usr/src/linux-headers-5.7.15-sunxi/linux/ looks correct and includes references to the functions I require (filp_open(), filp_close(), kernel_write()) but the compiler simply refuses to accept that these functions are declared. It appears to still be using the original headers in /usr/include.

I just know that I've done something wrong here but, having done everything I can find in this forum, I am now simply going round in circles...

 

Also tried adding  -I /usr/src/linux-headers-5.7.15-sunxi/include/ to the make file to force the compiler to look at the sunxi headers before the system ones however this just gives errors such as;

/usr/src/linux-headers-5.7.15-sunxi/include/linux/linkage.h:8:10: fatal error: asm/linkage.h: No such file or directory

Anyone point a poor frustrated programmer in the right direction?

 

Edited by jcheriton
Addition of further detail
Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines