From 71793e0f7907421d5bee619ae524e5178c6f3f32 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Fonseca?= Date: Tue, 14 Apr 2009 21:39:54 +0100 Subject: scons: Support winddk 6001.18002. --- scons/gallium.py | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) (limited to 'scons/gallium.py') diff --git a/scons/gallium.py b/scons/gallium.py index e2cd0546c1..696ddd025f 100644 --- a/scons/gallium.py +++ b/scons/gallium.py @@ -252,21 +252,24 @@ def generate(env): # http://msdn2.microsoft.com/en-us/library/6dwk3a1z.aspx, 'WIN32_LEAN_AND_MEAN', ] - if msvc: + if msvc and env['toolchain'] != 'winddk': cppdefines += [ 'VC_EXTRALEAN', '_CRT_SECURE_NO_DEPRECATE', ] if debug: cppdefines += ['_DEBUG'] - if platform == 'winddk': + if env['toolchain'] == 'winddk': # Mimic WINDDK's builtin flags. See also: # - WINDDK's bin/makefile.new i386mk.inc for more info. # - buildchk_wxp_x86.log files, generated by the WINDDK's build # - http://alter.org.ua/docs/nt_kernel/vc8_proj/ + if machine == 'x86': + cppdefines += ['_X86_', 'i386'] + if machine == 'x86_64': + cppdefines += ['_AMD64_', 'AMD64'] + if platform == 'winddk': cppdefines += [ - ('_X86_', '1'), - ('i386', '1'), 'STD_CALL', ('CONDITION_HANDLING', '1'), ('NT_INST', '0'), @@ -309,15 +312,6 @@ def generate(env): cppdefines += ['PIPE_SUBSYSTEM_WINDOWS_CE_OGL'] env.Append(CPPDEFINES = cppdefines) - # C preprocessor includes - if platform == 'winddk': - env.Append(CPPPATH = [ - env['SDK_INC_PATH'], - env['DDK_INC_PATH'], - env['WDM_INC_PATH'], - env['CRT_INC_PATH'], - ]) - # C compiler options cflags = [] if gcc: -- cgit v1.2.3