作者shane123 (家產有八十七億  ﰩ
看板FreeBSD
標題[問題] system call 實做的方式?
時間Wed Oct 5 07:22:08 2005
hi,
請問一下
我現在要寫一個 system call 如下 (under FreeBSD 5.4)
syscalls.master:
445 STD { int syshello(char *buf); }
之後執行 makesyscalls.sh
sys_hello.c:
int syshello(struct thread *td,struct syshello_args *uap)
{
printf(usp->buf);
td->td_retval[0]=0;
return 0;
}
那請問一下
我需要include 哪些檔? 因為他都說 prototype not declare
以及如果我想呼叫一些,例如 printf, fopen 等等
又該 include 哪些 header file?
還有是否還要去改那複雜的 Makefile 呢?
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 61.62.97.25