Author Topic: Compiling precompiled headers file with Code::Blocks  (Read 15711 times)

Offline thomas

  • Administrator
  • Lives here!
  • *****
  • Posts: 3979
Re: Compiling precompiled headers file with Code::Blocks
« Reply #15 on: August 25, 2007, 01:41:58 pm »
Quote
Wwolf is right insofar as we can indeed not do much about it (nothing at all, actually). Just ignore it, or use the compiler option to turn off attribute warnings (this won't affect any other warnings).

I think we should do that, what is the option ?
I think we should not do that. I makes building with 3.4.x impossible.

3.4.x fails to build then ?
-Wno-comment was added with gcc 4.1, so both the 3.4 and 4.0 series will fail with "unknown command line switch" if you add that to the project/makefile.

It's ok for someone to use the flag if he only wants use gcc 4.2 anyway... but I think we should not use it.
"We should forget about small efficiencies, say about 97% of the time: Premature quotation is the root of public humiliation."

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5491
Re: Compiling precompiled headers file with Code::Blocks
« Reply #16 on: August 25, 2007, 01:53:39 pm »
I'll see if I can do it with scripting ;-)

Offline Biplab

  • Developer
  • Lives here!
  • *****
  • Posts: 1874
    • Biplab's Blog
Re: Compiling precompiled headers file with Code::Blocks
« Reply #17 on: August 25, 2007, 01:58:28 pm »
I'll see if I can do it with scripting ;-)

There is a SDK function, CompilerMINGW::GetVersionString(). It'll return the version string of GCC (e.g., 4.1.2). You can use it somehow.  :)
Be a part of the solution, not a part of the problem.

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5491
Re: Compiling precompiled headers file with Code::Blocks
« Reply #18 on: August 25, 2007, 04:17:08 pm »
yes indeed, an when we know it's above 4.2 we add the little option to the compiler.
Just need to check with the big boss, if it is ok, to have a codeblocks.script next to our codeblocks.cbp ;-)

Offline thomas

  • Administrator
  • Lives here!
  • *****
  • Posts: 3979
Re: Compiling precompiled headers file with Code::Blocks
« Reply #19 on: August 25, 2007, 05:50:10 pm »
Why an extra file? You could [[  ]] it as pre-build step for the first target.
"We should forget about small efficiencies, say about 97% of the time: Premature quotation is the root of public humiliation."

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5491
Re: Compiling precompiled headers file with Code::Blocks
« Reply #20 on: August 25, 2007, 10:56:58 pm »
Why an extra file? You could [[  ]] it as pre-build step for the first target.
now that's something I didn't know

Offline yakumoklesk

  • Multiple posting newcomer
  • *
  • Posts: 34
Re: Compiling precompiled headers file with Code::Blocks
« Reply #21 on: August 26, 2007, 03:10:26 pm »
It would be nice if another workaround is found rather of the -"Wno_attributes" option. I like the most warnings that are really warnings to be shown, and only mask the warnings that one knows to be sure that are harmless.