MeanEYE / Disk-Indicator

Small program for Linux that will turn your Scroll, Caps or Num Lock LED into hard disk indicator.
GNU General Public License v3.0
155 stars 9 forks source link

error: implicit declaration of function ‘fsync’ [-Werror=implicit-function-declaration] #11

Open leonstafford opened 7 years ago

leonstafford commented 7 years ago

failing to build on *buntu 12

c99 -Wall -pedantic -Werror -D _DEFAULT_SOURCE -c src/xorg.c
c99 -Wall -pedantic -Werror -D _DEFAULT_SOURCE -c src/console.c
c99 -Wall -pedantic -Werror -D _DEFAULT_SOURCE -c src/thinkpad.c
src/thinkpad.c: In function ‘thinkpad_turn_on’:
src/thinkpad.c:86:2: error: implicit declaration of function ‘fsync’ [-Werror=implicit-function-declaration]
cc1: all warnings being treated as errors
make: *** [thinkpad.o] Error 1
MeanEYE commented 7 years ago

I'll check. Thanks for reporting.

MeanEYE commented 6 years ago

fsync function was added in glibc version 2.8. Try changing it to fdatasync and see if you can build. Also, sorry for the late reply. Am long overdue on my projects.

MeanEYE commented 6 years ago

Just pushed version which allows you to specify with which provider program is to be built. This will allow you to go around this issue if you don't need ThinkPad support.