[vortex] How to use gettimeofday inside 3c59x.c ?

Marcus Ramos marcus@ansp.br
Thu, 22 Mar 2001 11:42:18 -0300


I've modified 3c59x.c code in order to be able to insert GPS timestamps
in UDP packets both when they are sent and when they are received from
the net. As the GPS receivers are not available yet, I wanted to test my
code by using "gettimeofday" (local CPU clock) instead. This way I won't
have accurate time references, but will anyway be able to test the code.

The problem is that, after compiling without erros, insmod will not load
the module (3c59x.o) because it says it cannot resolve the symbol
"gettimeofday". If I #include <sys/time.h> and <unistd.h> in the source
code, as mentioned in man gettimeofday, I get many conflicts due to
duplicated symbols during compilation.

Am I trying to do  something not allowed ? Or, how can make it compile
and load without errors ?

Thanks in advance,