|
|
Line 1: |
Line 1: |
− | Hey,
| |
− | the new version (0.4_beta1) doesn't compile on Debian Etch.
| |
| | | |
− | > make
| |
− | gcc -g -Wall -lX11 -lXss -o brightd brightd.c
| |
− | brightd.c:48:25: error: sys/inotify.h: No such file or directory
| |
− | brightd.c: In function 'main':
| |
− | brightd.c:530: warning: implicit declaration of function 'inotify_init'
| |
− | brightd.c:532: warning: implicit declaration of function 'inotify_add_watch'
| |
− | brightd.c:532: error: 'IN_CREATE' undeclared (first use in this function)
| |
− | brightd.c:532: error: (Each undeclared identifier is reported only once
| |
− | brightd.c:532: error: for each function it appears in.)
| |
− | brightd.c:593: error: invalid application of 'sizeof' to incomplete type 'struct inotify_event'
| |
− | brightd.c:595: error: dereferencing pointer to incomplete type
| |
− | brightd.c:715: error: invalid application of 'sizeof' to incomplete type 'struct inotify_event'
| |
− | brightd.c:716: error: invalid application of 'sizeof' to incomplete type 'struct inotify_event'
| |
− | brightd.c:718: error: dereferencing pointer to incomplete type
| |
− | brightd.c:718: error: dereferencing pointer to incomplete type
| |
− | brightd.c:719: error: dereferencing pointer to incomplete type
| |
− | make: *** [brightd] Error 1
| |
− |
| |
− | So I changed the line
| |
− | #include <sys/inotify.h>
| |
− | to
| |
− | #include <linux/inotify.h>
| |
− | which gives me:
| |
− |
| |
− | > make
| |
− | gcc -g -Wall -lX11 -lXss -o brightd brightd.c
| |
− | brightd.c: In function 'main':
| |
− | brightd.c:530: warning: implicit declaration of function 'inotify_init'
| |
− | brightd.c:532: warning: implicit declaration of function 'inotify_add_watch'
| |
− | /tmp/ccIEzkru.o: In function `main':
| |
− | /home/thomas/downloads/brightd-0.4_beta4/brightd.c:530: undefined reference to `inotify_init'
| |
− | /home/thomas/downloads/brightd-0.4_beta4/brightd.c:532: undefined reference to `inotify_add_watch'
| |
− | /home/thomas/downloads/brightd-0.4_beta4/brightd.c:576: undefined reference to `inotify_init'
| |
− | /home/thomas/downloads/brightd-0.4_beta4/brightd.c:578: undefined reference to `inotify_add_watch'
| |
− | collect2: ld returned 1 exit status
| |
− | make: *** [brightd] Error 1
| |
− |
| |
− | Do I need a special version of inotify? Sry, I have no real experience in c programming.
| |
− |
| |
− | > uname -a
| |
− | Linux phooka 2.6.22 #1 PREEMPT Wed Aug 1 11:47:42 CEST 2007 i686 GNU/Linux
| |