otonchev / grove_dust

Monitor/Log/Share Fine particle (PM2.5) with Grove Dust sensor(Shinyei PPD42NS) and Raspberry Pi
20 stars 9 forks source link

Error with make #4

Open TBR-BRD opened 7 years ago

TBR-BRD commented 7 years ago

Hi, i have a error with make test, please help me: pi@rpi:~/grove_dust $ make test gcc -c -o lngpio.o lngpio.c -I. -Werror -pthread -g lngpio.c: In function ‘lngpio_pin_pulse_len’: lngpio.c:292:3: error: implicit declaration of function ‘gettimeofday’ [-Werror=implicit-function-declaration] gettimeofday (&t1, NULL); ^~~~ cc1: all warnings being treated as errors Makefile:14: die Regel für Ziel „lngpio.o“ scheiterte make: *** [lngpio.o] Fehler 1

TBR-BRD commented 7 years ago

Raspbian GNU/Linux 9 (stretch)

simepy commented 6 years ago

For fix this error just add: "#include <sys/time.h>" in: