#include<../../..nsyscall.h>
#include <include.stdio.h> or #include<stdio.h> or many options...
int main()
{
int retval,i=5;
char * msg="ttt";
retval=nsyscall(i,msg);
printf("%d",retval);
return(1);
}
nsyscall is properly added and compiled into kernel syscall,using the
_syscall2 macro as well
however when trying to compile it says that it can't find some file
which stdio.h is supposed to use....
what do i do? the above file is found in numerous locations,do i need
to include everything the stdio.h uses-or is it supposed to find it by
himself?
another question:
I tried to use printk(),instead of the printf(),but it DOESN'T
actually print something to the stdout.... any explanation for this?
thanks a lot to all in advance
Yes, printk doesn't print to stdout it prints to the kernel log.
http://www.daimi.au.dk/~kasperd/comp.os.linux.development.faq.html
question #4.
--
Kasper Dupont -- der bruger for meget tid på usenet.
For sending spam use mailto:aaa...@daimi.au.dk
or mailto:mcxumhv...@skrammel.yaboo.dk
So tried to stick with the printf(),and I find that when I compile a
call to printf() with the regular gcc try.c it compiles and
works,however,when I compile a slighlty different file,which uses my
new syscall-with the long "gcc -pedantic -I../../linux/include
-I../../linux/include |..etc.line from my previous message-which I
need to properly include various system, files(I think)....-it can't
correctly find a file which a certain file included by stdio.h
includes...
I've tried "gcc -E try.c |less",and I see that the steps that both the
compilations take are similar-both seems to find the above
file(stdarg.h),but inthe 2nd case I still get an error msg,and the
compilation fails.
Can you think of a solution for this,please??? I've spent a week
adding the systam call,and now can't even check that it works....Got
to submit the thing tomorow,as well....
Thanks in advance,
Katy
Kasper Dupont <kas...@daimi.au.dk> wrote in message news:<3D60B72C...@daimi.au.dk>...