Hello: I am new to linux and facing a simple compile problem. I have written a C file which is using the do_gettimeofday() function.
#include <linux/time.h> #include <stdio.h> main() { struct timeval start; do_gettimeofday(&start); printf ("%d", start.tv_usec); } gcc a1.c -- undefined reference to `do_gettimeofday' here is the PATH: echo $PATH /usr/lib/qt-3.3/bin:/usr/kerberos/bin:/usr/lib/ccache:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/homes/iws/arpalla/bin I checked that the /usr/include/linux/time.h file got the function declaration for do_gettimeofday() Is there anything missing in the PATH variable? I am facing same error for rdtscl() function as well!! The Linux version is : [arpalla]$ uname -a Linux <..> 2.6.30-2.0 #6 SMP Mon Sep 21 11:03:44 PDT 2009 i686 i686 i386 GNU/Linux Can anyone please help? Thanks, Anu
-- fedora-list mailing list fedora-list@redhat.com To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list Guidelines: http://fedoraproject.org/wiki/Communicate/MailingListGuidelines