Skip to content

Instantly share code, notes, and snippets.

/-

Created April 3, 2016 20:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/77f7e53bfda8d1c769b583517f061152 to your computer and use it in GitHub Desktop.
Save anonymous/77f7e53bfda8d1c769b583517f061152 to your computer and use it in GitHub Desktop.
diet gcc -s -pipe -Os -o sln sln.c
sln.c:3:5: error: conflicting types for ‘strlen’
int strlen(const char *s) {
^
In file included from /usr/include/diet/sys/select.h:4:0,
from /usr/include/diet/unistd.h:8,
from sln.c:1:
/usr/include/diet/string.h:28:8: note: previous declaration of ‘strlen’ was here
size_t strlen(const char *s) __THROW __pure __nonnull((1));
^
sln.c: In function ‘die’:
sln.c:11:3: warning: implicit declaration of function ‘exit’ [-Wimplicit-function-declaration]
exit(111);
^
sln.c:11:3: warning: incompatible implicit declaration of built-in function ‘exit’
sln.c:11:3: note: include ‘<stdlib.h>’ or provide a declaration of ‘exit’
sln.c: At top level:
sln.c:14:1: warning: return type defaults to ‘int’ [-Wimplicit-int]
main(int argc,char *argv[]) {
^
Makefile:2: recipe for target 'sln' failed
make: *** [sln] Error 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment