Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation error #12

Open
damiencarol opened this issue Jul 11, 2016 · 3 comments
Open

Compilation error #12

damiencarol opened this issue Jul 11, 2016 · 3 comments

Comments

@damiencarol
Copy link

dcarol@dcarol ~/w/g/kilo> make
cc -o kilo kilo.c -Wall -W -pedantic -std=c99
In file included from /usr/include/termios.h:25:0,
                 from kilo.c:40:
/usr/include/features.h:148:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
 # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
   ^~~~~~~
kilo.c: In function ‘editorRefreshScreen’:
kilo.c:953:19: warning: implicit declaration of function ‘time’ [-Wimplicit-function-declaration]
     if (msglen && time(NULL)-E.statusmsg_time < 5)
                   ^~~~
@damiencarol
Copy link
Author

damiencarol commented Jul 11, 2016

#include <time.h>

is missing IMHO

@e12e
Copy link

e12e commented Jul 11, 2016

Adding:
#include <time.h>
silences the error.

@damiencarol
Copy link
Author

will be fixed with #5

antirez added a commit that referenced this issue Jul 2, 2020
Use _POSIX_C_SOURCE, drop _BSD_SOURCE, _GNU_SOURCE (#5, #12)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants