You are not logged in.
I get "...sys\stat.h: No such file or directory" error when compiling a simple C program. i have been searching for a while on web and see people writing "# pacman -S base-devel" i have that already and some more packages like glib ...
These are the includes i am using :
#include <stdio.h>
#include <stdlib.h>
#include <io.h>
#include <fcntl.h>
#include <sys\stat.h>
...
// here is when i use the libraries sys/stats.h
struct stat stbuf;
stat(argv[2], &stbuf);
int infSize = stbuf.size;
...
This is the output of the command "gcc -o copy copy.c" :
copy.c:3:16: error: io.h: No such file or directory
copy.c:5:22: error: sys\stat.h: No such file or directory
copy.c: In function 'main':
copy.c:35: error: storage size of 'stbuf' isn't known
Either i am missing any package needed or the gcc compiler is missing any lib directory. But i dont know which one is it.
Any ideas are apreciated. Thanks you
EDIT : The error was actually on #Include <io.h> , but i dunno why it conflicted with #include <sys\stat.h>.
Anyway Problem Solved.
Last edited by puzzled (2008-10-05 17:07:03)
Offline