Date: Thu, 27 Mar 2003 15:28:26 +0100 From: "Poul-Henning Kamp" <phk@phk.freebsd.dk> To: freebsd@libkvm.org Cc: freebsd-bugs@freebsd.org Subject: Re: compile time error when calling getmicrotime() Message-ID: <3056.1048775306@critter.freebsd.dk> In-Reply-To: Your message of "Thu, 27 Mar 2003 15:26:43 %2B0100." <20030327142643.GA58757@postel.libkvm.org>
next in thread | previous in thread | raw e-mail | index | archive | help
In message <20030327142643.GA58757@postel.libkvm.org>, freebsd@libkvm.org write s: >hi, > >i am trying to call getmicrotime(&tv) in a program but i >get the following error when compiling : > >/tmp/ccfMfSM6.o(.text+0xe): undefined reference to `getmicrotime' > >yes, i have declared '#include <sys/time.h>' :-) > >FreeBSD 5.0-RELEASE-p4 i386 >FreeBSD 4.7-RELEASE-p9 i386 That is a kernel function you are trying to call. Use gettimeofday(2) -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3056.1048775306>