c - undeclared error with thread in OS X? -


error: use of undeclared identifier 'clone_fs' error: use of undeclared identifier 'clone_files' error: use of undeclared identifier 'clone_sighand' error: use of undeclared identifier 'clone_vm'

i use ubuntu code processes , thread can run in ubuntu in mac give me error.how can fix it? if change macro decimal error disapper too.

main(int argc,char *argv[]) { pthread_mutex_init(&mutex,null); sem_init(&product,0,0); sem_init(&warehouse,0,8); int clone_flag,arg,retval; clone_flag = clone_vm|clone_sighand|clone_fs|clone_files; int i; char *stack; for(i=0;i<2;i++) {     arg = i;     stack = (char *)malloc(4096);     retval = clone((void *)producer,&(stack[4095]),clone_flag,(void *)&arg);     stack = (char *)malloc(4096);     retval = clone((void *)consumer,&(stack[4095]),clone_flag,(void *)&arg); } exit(1); } 


Comments

Popular posts from this blog

javascript - oscilloscope of speaker input stops rendering after a few seconds -

javascript - gulp-nodemon - nodejs restart after file change - Error: listen EADDRINUSE events.js:85 -

Fatal Python error: Py_Initialize: unable to load the file system codec. ImportError: No module named 'encodings' -