From: Ben Noordhuis <info@bnoordhuis.nl>
Date: Sat, 17 Mar 2012 15:13:32 +0000 (+0100)
Subject: build: re-enable optimizations in release builds
X-Git-Tag: xonotic-v0.7.0~16^2~6^2~2^2^2
X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=d3e3a8e063ad587ab92af39b9b93244b249df450;p=xonotic%2Fnetradiant.git

build: re-enable optimizations in release builds

Commit f961a54 fixes the q3map2 crash at startup so it's safe to enable
optimizations again.
---

diff --git a/config.py b/config.py
index f55b7bfa..4c441393 100644
--- a/config.py
+++ b/config.py
@@ -247,9 +247,8 @@ class Config:
 			env.Append( CXXFLAGS = [ '-g' ] )
 			env.Append( CPPDEFINES = [ '_DEBUG' ] )
 		else:
-                        # '-O' causes q3map2 errors on Ubuntu 10.10 32 bit.
-			env.Append( CFLAGS = [ ] )
-			env.Append( CXXFLAGS = [ ] )
+			env.Append( CFLAGS = [ '-O2', '-fno-strict-aliasing' ] )
+			env.Append( CXXFLAGS = [ '-O2', '-fno-strict-aliasing' ] )
 
 	def CheckoutOrUpdate( self, svnurl, path ):
 		if ( os.path.exists( path ) ):