1 #######################################################################
4 # For example, invoke scons as
8 # to set configuration variables. Or you can write those options to a file
19 # to get the full list of options. See scons manpage for more info.
26 opts = Options('config.py')
27 opts.Add(BoolOption('debug', 'build debug version', 'no'))
28 opts.Add(PathOption('dxsdk', 'DirectX SDK installation dir', os.environ.get('DXSDK_DIR', 'C:\\DXSDK')))
33 Help(opts.GenerateHelpText(env))
35 env.Append(CPPDEFINES = [
40 '_CRT_SECURE_NO_DEPRECATE',
41 '_CRT_NON_CONFORMING_SWPRINTFS',
42 'WIN32_LEAN_AND_MEAN',
47 env.Append(CPPDEFINES = ['_DEBUG'])
49 env.Append(CPPDEFINES = ['NDEBUG'])
50 env['PDB'] = '${TARGET.base}.pdb'
53 '/W4', # warning level
57 '/Od', # disable optimizations
58 '/Oy-', # disable frame pointer omission
62 '/Ox', # maximum optimizations
63 '/Os', # favor code space
66 '/Oi', # enable intrinsic functions
67 '/GF', # enable read-only string pooling
70 env.Append(CFLAGS = cflags)
71 env.Append(CXXFLAGS = cflags)
82 env.Append(CPPPATH = [
83 os.path.join(env['dxsdk'], 'Include'),
88 source = ['d3d8.py', 'd3d8types.py', 'd3d8caps.py', 'windows.py', 'base.py'],
89 action = 'python $SOURCE > $TARGET',
92 d3d8 = env.SharedLibrary(
105 source = ['d3d9.py', 'd3d9types.py', 'd3d9caps.py', 'windows.py', 'base.py'],
106 action = 'python $SOURCE > $TARGET',
109 d3d9 = env.SharedLibrary(
120 env.Tool('packaging')
128 SUMMARY = 'Tool to trace Direct3D API calls from applications.',
129 SOURCE_URL = 'http://cgit.freedesktop.org/~jrfonseca/d3dtrace/',
141 env.Alias('zip', zip)