Page 1 of 1

Change default compiler settings

Posted: Sun Sep 18, 2016 4:14 am
by asdfxcvad
I've been playing with compiler settings recently but as far as I can see there's no way to change the default compiler settings for new projects.
This has left me having to manually add some commonly used options to several new projects by hand. Is it possible to change the default compiler settings? (possibly in a config file somewhere as I've found no option to do this through the software.)

Thanks

Re: Change default compiler settings

Posted: Sun Sep 18, 2016 11:45 am
by eranif
Can you please provide some more info of what are you trying to do?
And what you tried so far

Re: Change default compiler settings

Posted: Sun Sep 18, 2016 8:18 pm
by asdfxcvad
Sorry, I've been a bit of a fool, I've found the solution now.

I'm currently making several projects which require the "-std=c++11" flag to be passed to the compiler. To save time, I was currently trying to make it such that whenever I start a new project, that flag is added as standard to the compiler settings.
Essentially, I was trying to change the compiler options in the template which I was using. I've now found the templates folder and have made a corrected template with the new option.

Thanks anyway :)

Re: Change default compiler settings

Posted: Sun Apr 16, 2017 5:26 pm
by rburkhardt
I am attempting to do the same thing but am not figure out what template I would need to change. Could you direct me to the correct template, I am using gnu gcc

Re: Change default compiler settings

Posted: Sun Apr 16, 2017 7:16 pm
by eranif
From: settings->build settings->compilers->YOUR COMPILER->Tools tab->C++ compiler field add the flag to the current value, for example, so instead of something like this:

Code: Select all

C:/TDM-GCC-64/bin/g++.exe
Change it to:

Code: Select all

C:/TDM-GCC-64/bin/g++.exe -std=c++11
Eran