Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2006-02-04 18:44:34 +0300
committerNathan Letwory <nathan@letworyinteractive.com>2006-02-04 18:44:34 +0300
commitc0234bd9ecb0c7ab1065dfe4ebaf779fe8d99426 (patch)
tree7ed89bffbd72d38cdfac59288d3c20d410702045
parent0884402f2bd52365ddd964d677f3fceaa92e91f9 (diff)
==SCons==
* add REL_CFLAGS and REL_CCFLAGS when not building debug. This adds NDEBUG to compile on Win32 * fix path to makesdna binary
-rw-r--r--config/win32-vc-config.py4
-rw-r--r--source/blender/makesdna/intern/SConscript15
-rw-r--r--tools/Blender.py2
3 files changed, 7 insertions, 14 deletions
diff --git a/config/win32-vc-config.py b/config/win32-vc-config.py
index 377d5f41ec6..6c48641136d 100644
--- a/config/win32-vc-config.py
+++ b/config/win32-vc-config.py
@@ -132,8 +132,8 @@ BF_OPENGL_LIB_STATIC = [ BF_OPENGL + '/lib/libGL.a', BF_OPENGL + '/lib/libGLU.a'
CCFLAGS = ['/nologo', '/Og', '/Ot', '/Ob1', '/Op', '/G6','/EHsc', '/J', '/W3', '/Gd', '/MT']
CPPFLAGS = ['-DWIN32','-D_CONSOLE', '-D_LIB', '-DUSE_OPENAL', '-DFTGL_LIBRARY_STATIC']
-REL_CFLAGS = []
-REL_CCFLAGS = []
+REL_CFLAGS = ['-O2', '-DNDEBUG']
+REL_CCFLAGS = ['-O2', '-DNDEBUG']
##BF_DEPEND = 'true'
##
##AR = ar
diff --git a/source/blender/makesdna/intern/SConscript b/source/blender/makesdna/intern/SConscript
index 2e18528aaa4..e0e06cd0f23 100644
--- a/source/blender/makesdna/intern/SConscript
+++ b/source/blender/makesdna/intern/SConscript
@@ -2,39 +2,30 @@
import sys
import os
-#Import ('cflags')
-#Import ('defines')
Import ('env')
cflags = ''
defines = []
root_build_dir=env['BF_BUILDDIR']
-# TODO: make sure the makesdna program does not get installed on the system.
source_files = ['makesdna.c']
makesdna_tool = env.Copy()
dna = env.Copy()
makesdna_tool.Append(CCFLAGS = '-DBASE_HEADER="\\"source/blender/makesdna/\\"" ')
-#makesdna_tool = Environment (ENV = os.environ, CCFLAGS='-DBASE_HEADER="\\"source/blender/makesdna/\\"" ')
makesdna_tool.Append (CPPPATH = ['#/intern/guardedalloc',
'../../makesdna'])
-#makesdna_tool.Replace (CC = user_options_dict['HOST_CC'])
-#makesdna_tool.Replace (PATH = user_options_dict['PATH'])
-
if sys.platform != 'cygwin':
makesdna_tool.Append (CCFLAGS = cflags)
- #makesdna_tool.Append (LINKFLAGS = user_options_dict['PLATFORM_LINKFLAGS'])
makesdna_tool.Append (CPPDEFINES = defines)
makesdna_tool.Append (LIBPATH = '#'+root_build_dir+'/lib')
makesdna_tool.Append (LIBS = 'blender_guardedalloc')
-makesdna_tool.Program (target = '#'+root_build_dir+'makesdna', source = source_files)
+makesdna_tool.Program (target = '#'+root_build_dir+os.sep+'makesdna', source = source_files)
-#dna = Environment (ENV = os.environ)
dna_dict = dna.Dictionary()
-makesdna_name = root_build_dir+'makesdna' + dna_dict['PROGSUFFIX']
+makesdna_name = root_build_dir+'/makesdna' + dna_dict['PROGSUFFIX']
dna.Depends ('dna.c', '#'+makesdna_name)
-dna.Command ('dna.c', '', root_build_dir+"makesdna $TARGET")
+dna.Command ('dna.c', '', root_build_dir+os.sep+"makesdna $TARGET")
obj = 'intern/dna.c'
Return ('obj')
diff --git a/tools/Blender.py b/tools/Blender.py
index 0da25350620..11c5251a899 100644
--- a/tools/Blender.py
+++ b/tools/Blender.py
@@ -275,6 +275,8 @@ class BlenderEnvironment(SConsEnvironment):
lenv.Append(CPPDEFINES=['GAMEBLENDER=1'])
if lenv['BF_DEBUG']:
lenv.Append(CCFLAGS = lenv['BF_DEBUG_FLAGS'], CXXFLAGS = lenv['BF_DEBUG_FLAGS'])
+ else:
+ lenv.Append(CCFLAGS = lenv['REL_CFLAGS'], CXXFLAGS = lenv['REL_CCFLAGS'])
if lenv['BF_PROFILE']:
lenv.Append(CCFLAGS = lenv['BF_PROFILE_FLAGS'], CXXFLAGS = lenv['BF_PROFILE_FLAGS'])
if compileflags: