OESF Portables Forum
Everything Else => General Support and Discussion => Zaurus General Forums => Archived Forums => Software => Topic started by: rgzu on December 19, 2004, 02:03:59 pm
-
I am trying to compile a program using the zgcc compiler and get the following error:
undefined reference to 'stat'
Here is a small test program that displays the same error:
#include
<sys/stat.h>
main(){
struct stat buf;
char *fn;
int st;
st = stat( fn, &buf );
}
I have checked the obvious that stat.h is there and I have searched this forum and the internet and only come across a couple of references to this, but they were both in a foreign languages. Even translated they didn't seemed to make sense although it seems to be a problem with a library missing or incorrect? I am posting here to see if someone can help me out.
I am using a Zaurus 5500 with the sharp 3.13 ROM. Thanks for any help in advance.
-
You need to staticaly link with libc_nonshared.a
-
Thanks for the reply. Is there somewhere that I can download this? It appears I do not have this on my device and it is needed by a program I am trying to compile.
-
Thanks for the reply. Is there somewhere that I can download this? It appears I do not have this on my device and it is needed by a program I am trying to compile.
It should be a part of gcc compiler toolchain. At least it does exist in dev-img 1.6, for exmaple...
-
I managed to extract it from dev_img-1.5 from the Zaurus Software index and place it in /home/QtPalmtop/lib where I made a symbolic link from libc.a. The program that needs it compiles fine.