This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug preprocessor/55115] [>=4.5.0 regression] missing headers as fatal breaks cproto logic
- From: "manu at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 29 Oct 2012 14:53:24 +0000
- Subject: [Bug preprocessor/55115] [>=4.5.0 regression] missing headers as fatal breaks cproto logic
- Auto-submitted: auto-generated
- References: <bug-55115-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55115
--- Comment #5 from Manuel LÃpez-IbÃÃez <manu at gcc dot gnu.org> 2012-10-29 14:53:24 UTC ---
(In reply to comment #3)
>
> Now - myfuncs.h being auto generated, during first build, prototyping will fail
> quickly due to "Missing headers"...
> This create some kind of a "Chicken/Egg" problem :-)
So do "touch myfuncs.h" before the first file is built. Or invoke gcc -E in a
temp file for which you comment out the #include "myfuncs.h". Or make cproto do
any of this automatically.
Or even better, use libClang <http://clang.llvm.org/docs/Tooling.html> to do
what you want instead of parsing GCC errors, which are likely to change in
unexpected ways.