Re: sparse error: unable to open 'stdarg.h'

From: Christopher Li
Date: Wed May 18 2005 - 11:38:22 EST


On Wed, May 18, 2005 at 10:51:08AM -0500, Timur Tabi wrote:
> Christopher Li wrote:
>
> >That is wired. Can you try to edit a test.c contain just one line:
> >
> >#include <stdarg.h>
> >
> >run sparse on that test.c and see if you get any complain or not?
>
> I did "sparse test.c" and got no output whatsoever. No files were created,
> either.

The sparse checker does not create files. That means your sparse is
fine. It should locate the stdarg.h

> There must be something specific about how kbuild calls sparse.

I think I know that it is. There is a "-nostdinc" in the sparse
options, which I saw it in the other email you send out. It
drop the internal include path. Gcc is does the same thing.

gcc -c -nostdinc /tmp/test.c
/tmp/test.c:1:22: no include path in which to find stdarg.h

Chris

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/