Cross compiler problem...
Hi there,
I am using cross compiler on Fedora 8 and having a problem when i compile the code with include path and library.
example: arm-linux-gcc -I/home/linux-2.3.28/include -o myobj myprog.c -L/home/linux-2.3.28/lib
// myprog.c
#include <linux/ioport.h> //which is located in
//home/linux-2.3.28/include
int main(void)
{
return 0;
} // that's all so far
errors: home/linux-2.3.28/include/ioport.h:19: expected specifier-qualifier-list before 'resource size_t'
.....
.... // all errors are belong to ioport.h.
I strongly believe i should set the links somewhere.
Please tell me how to set.
And also, do i need to use -mcpu=arm_VERSION option?
thanks to all who help me.
Last edited by mashhur; 01-29-2012 at 11:34 PM.
|