prog.c: In function 'my_thread_process':
prog.c:5:3: warning: implicit declaration of function 'pthread_setcancelstate' [-Wimplicit-function-declaration]
pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL);
^
prog.c:5:26: error: 'PTHREAD_CANCEL_ENABLE' undeclared (first use in this function)
pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL);
^
prog.c:5:26: note: each undeclared identifier is reported only once for each function it appears in
prog.c:5:49: error: 'NULL' undeclared (first use in this function)
pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL);
^
prog.c:6:3: warning: implicit declaration of function 'pthread_setcanceltype' [-Wimplicit-function-declaration]
pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL);
^
prog.c:6:25: error: 'PTHREAD_CANCEL_ASYNCHRONOUS' undeclared (first use in this function)
pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL);
^
prog.c:9:5: warning: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
printf ("Thread %s: %d\n", (char*)arg, i);
^
prog.c:9:5: warning: incompatible implicit declaration of built-in function 'printf'
prog.c:10:5: warning: implicit declaration of function 'sleep' [-Wimplicit-function-declaration]
sleep (1);
^
prog.c:12:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^