Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
c++ flags
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
cujo
Tux's lil' helper
Tux's lil' helper


Joined: 30 Oct 2002
Posts: 84

PostPosted: Sun Feb 02, 2003 12:30 am    Post subject: c++ flags Reply with quote

is it possible to somehow embed optimization levels in c++ source code? i want to compile a program of mine with the -O3 option. can i somehow put this in the code?
Back to top
View user's profile Send private message
masseya
Bodhisattva
Bodhisattva


Joined: 17 Apr 2002
Posts: 2602
Location: Baltimore, MD

PostPosted: Sun Feb 02, 2003 12:35 am    Post subject: Reply with quote

I believe compiler flags can't be embedded in the code itself, but you can certainly do that in a makefile for your program. This would also make your code a lot more portable. There are several tutorials on makefiles availible. I would just google for one.
_________________
if i never try anything, i never learn anything..
if i never take a risk, i stay where i am..
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum