On Wed, 9 Jun 2010 09:10:59 -0700, Josh Triplett <josh@xxxxxxxxxxxxxxxx> wrote: > On Wed, Jun 09, 2010 at 05:09:54PM +0200, bonneta wrote: >> I am working on git, and i would like to apply sparse on its source code. >> >> I've downloaded the source of sparse from its git repository, and >> compiled >> it successfully. >> >> I've read the little documentation furnished with the code, but i didn't >> manage to apply sparse on the sources of git. >> >> I've basically tried "sparse file.c", but it always returns with an error >> like : >> "git-compat-util.h:140:11: error: unable to open 'openssl/ssl.h'" >> or >> "builtin/blame.c:7:10: error: unable to open 'cache.h'" >> >> I don't know how to resolve it... > > These errors occur because you haven't supplied the full compiler > command-line that Git supplies in its build process, which includes > flags for include paths. > > The script "cgcc", provided with sparse, provides the most convenient > way to integrate Sparse into an existing build system with minimal work. > Once you've done a "make install" of Sparse into a directory on your > $PATH (or just put the Sparse source directory on your $PATH), just do > "make CC=cgcc". Thank you all, it works fine. Does sparse look for all the errors with this method? I saw in the sparse man page that a "Wsparse-all" option exists. Is it used by default? Otherwise how to use it in the "make" command line? Axel Bonnet > > - Josh Triplett > -- > To unsubscribe from this list: send the line "unsubscribe linux-sparse" in > the body of a message to majordomo@xxxxxxxxxxxxxxx > More majordomo info at http://vger.kernel.org/majordomo-info.html -- To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html