시스템호출 에서 include애러 좀 봐주세요.
글쓴이: okgo / 작성시간: 월, 2004/03/01 - 9:15오후
시스템호출 연습을 해보려고 아래와같은 test.c파일을 하나 만들었는데요.
#include<include/asm-i386/unistd.h> _syscall0(int.newsyscall); main() { int i; i=newsyscall(); }
gcc 컴파일을 하면
[root@localhost linux-2.4.24]# gcc test.c test.c:1:37: include/asm-i386/unistd.h: 그런 파일이나 디렉토리가 없 음 test.c:2: parse error before '.' token test.c:2: warning: data definition has no type or storage class
와 같은 메세지가 뜹니다.
unistd.h파일의 경로는linux-2.4.24/ include/asm-i386/unistd.h 이거든요,
test.c 의 위치는 linux-2.4.24 이구요,gcc test.c 실행위치도 linux-2.4.24 입니다.
test.c 위치를 바꿔보고 #include<include/asm-i386/unistd.h> 경로 부분을
<asm-i386/unistd.h> 등 다양하게 바꿔봐도 똑같은 메세지만 나옵니다.
도와주세요,
Forums:
[code:1]gcc -I/usr/src/linux ...... [/co
gcc -I/usr/src/linux ......
식으로 include path 를 명시해줘보세요..
오랫동안 꿈을 그리는 사람은 그 꿈을 닮아간다...
http://mytears.org ~(~_~)~
나 한줄기 바람처럼..
아무히 해봐도 [code:1]test.c:1:37&#
아무히 해봐도
test.c:1:37: include/asm-i386/unistd.h: 그런 파일이나 디렉토리가 없 음
에러베세지가 계속뜨는데 해결방법 좀 알려주세요.
댓글 달기