Eclipse - Tips'n Tricks - Adding flags to the GCC compiler

You may want to add some commands to your GCC flag settings.

No problem, Eclipse can allow you this.

Right click on your project > Properties > C/C++ Build > Settings > Tool Settings > GCC C++ Compiler > Miscellaneous.
On the right, there is an input with the name Other flags.
Enter your command there.

For example, if when you compiling you have this error:

  • deprecated conversion from string constant to 'char*' [-Wwrite-strings]

You can add this command to remove it:

  • -Wno-write-strings

Add new comment

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.
CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
Refresh Type the characters you see in this picture. Type the characters you see in the picture; if you can't read them, submit the form and a new image will be generated. Not case sensitive.  Switch to audio verification.