diff options
-rw-r--r-- | base/SConscript | 78 | ||||
-rw-r--r-- | build/SConscript.main | 22 | ||||
-rw-r--r-- | build/SConscript.main.linux | 21 | ||||
-rw-r--r-- | build/SConscript.v8 | 6 | ||||
-rw-r--r-- | net/SConscript | 32 | ||||
-rw-r--r-- | net/tools/tld_cleanup/SConscript | 17 | ||||
-rw-r--r-- | sandbox/src/SConscript | 13 | ||||
-rw-r--r-- | webkit/activex_shim_dll/SConscript | 15 | ||||
-rw-r--r-- | webkit/glue/plugins/test/SConscript | 13 | ||||
-rw-r--r-- | webkit/tools/npapi_layout_test_plugin/SConscript | 4 | ||||
-rw-r--r-- | webkit/tools/test_shell/SConscript | 106 |
11 files changed, 186 insertions, 141 deletions
diff --git a/base/SConscript b/base/SConscript index 601e9ad..100768c 100644 --- a/base/SConscript +++ b/base/SConscript @@ -41,12 +41,16 @@ env.Prepend( CPPDEFINES = [
'U_STATIC_IMPLEMENTATION',
],
- CCFLAGS = [
- '/TP',
- '/Wp64',
- ],
)
+if env['PLATFORM'] == 'win32':
+ env.Prepend(
+ CCFLAGS = [
+ '/TP',
+ '/Wp64',
+ ],
+ )
+
input_files = [
'at_exit.cc',
'base_drag_source.cc',
@@ -137,41 +141,45 @@ env_tests.Prepend( 'WINVER=0x0600',
'_HAS_EXCEPTIONS=0',
],
- CCFLAGS = [
- '/TP',
- '/WX',
- '/Wp64',
- ],
- LINKFLAGS = [
- '/MANIFEST',
- '/DELAYLOAD:"dwmapi.dll"',
- '/DELAYLOAD:"uxtheme.dll"',
- '/MACHINE:X86',
- '/FIXED:No',
-
- '/safeseh',
- '/dynamicbase',
- '/ignore:4199',
- '/nxcompat',
- ],
+ LIBS = [
+ 'base',
+ 'base_gfx',
+ 'skia',
+ 'libpng',
+ 'gtest',
+ 'icuuc',
+ 'zlib',
+ ]
)
-libs = [
- 'base.lib',
- 'gfx/base_gfx.lib',
- '$SKIA_DIR/skia.lib',
- '$LIBPNG_DIR/libpng.lib',
- '$TESTING_DIR/gtest.lib',
- '$ICU38_DIR/icuuc.lib',
- '$ZLIB_DIR/zlib.lib',
-]
-
env_tests.Append(
CPPPATH = [
'$GTEST_DIR/include',
],
)
+if env['PLATFORM'] == 'win32':
+ env_tests.Prepend(
+ CCFLAGS = [
+ '/TP',
+ '/WX',
+ '/Wp64',
+ ],
+ LINKFLAGS = [
+ '/MANIFEST',
+ '/DELAYLOAD:"dwmapi.dll"',
+ '/DELAYLOAD:"uxtheme.dll"',
+ '/MACHINE:X86',
+ '/FIXED:No',
+
+ '/safeseh',
+ '/dynamicbase',
+ '/ignore:4199',
+ '/nxcompat',
+ ],
+ )
+
+
env_tests_dll = env_tests.Clone()
env_tests_dll.Append(
CPPDEFINES = [
@@ -183,14 +191,14 @@ dll = env_tests_dll.ChromeSharedLibrary(['singleton_dll_unittest.dll', 'singleton_dll_unittest.ilk',
'singleton_dll_unittest.pdb'],
['singleton_dll_unittest.cc',
- 'build/singleton_dll_unittest.def'] + libs)
+ 'build/singleton_dll_unittest.def'])
i = env.Install('$TARGET_ROOT', dll[0])
env.Alias('base', i)
env_tests.ChromeTestProgram(['debug_message.exe',
'debug_message.ilk',
'debug_message.pdb'],
- ['debug_message.cc'] + libs)
+ ['debug_message.cc'])
test_files = [
'at_exit_unittest.cc',
@@ -241,7 +249,7 @@ test_files = [ 'win_util_unittest.cc',
'wmi_util_unittest.cc',
- 'singleton_dll_unittest.lib',
+ dll[0],
]
base_unittests = env_tests.ChromeTestProgram([
@@ -249,7 +257,7 @@ base_unittests = env_tests.ChromeTestProgram([ 'base_unittests.exp',
'base_unittests.ilk',
'base_unittests.lib',
- 'base_unittests.pdb'], test_files + libs)
+ 'base_unittests.pdb'], test_files)
# Install up a level to allow unit test path assumptions to be valid.
diff --git a/build/SConscript.main b/build/SConscript.main index 2ffebed..1c5af2e 100644 --- a/build/SConscript.main +++ b/build/SConscript.main @@ -53,6 +53,8 @@ env = Environment( TARGET_ROOT = '#/$BUILD_TYPE', OBJ_ROOT = '$TARGET_ROOT', + LIBS_DIR = '#/$BUILD_TYPE/Libs', + BASE_DIR = '#/$BUILD_TYPE/base', BREAKPAD_DIR = '#/$BUILD_TYPE/breakpad', CHROME_DIR = '#/$BUILD_TYPE/chrome', @@ -96,6 +98,8 @@ env = Environment( THIRD_PARTY_WEBKIT_DIR = '$THIRD_PARTY_DIR/webkit', PYTHON=sys.executable, + + LIBPATH = ['$LIBS_DIR'], ) @@ -108,7 +112,9 @@ def ChromeTestProgram(env, *args, **kw): env.AddMethod(ChromeTestProgram, "ChromeTestProgram") def ChromeStaticLibrary(env, *args, **kw): - return env.StaticLibrary(*args, **kw) + result = env.StaticLibrary(*args, **kw) + env.Install('$LIBS_DIR', result) + return result env.AddMethod(ChromeStaticLibrary, "ChromeStaticLibrary") def ChromeSharedLibrary(env, *args, **kw): @@ -194,12 +200,6 @@ if env['PLATFORM'] == 'win32': '$VISUAL_STUDIO/VC/atlmfc/include', ], - LIBPATH = [ - '$PLATFORMSDK_VISTA/files/Lib', - '$PLATFORMSDK_VISTA/files/VC/LIB', - '$VISUAL_STUDIO/VC/atlmfc/lib', - ], - LIBS = [ 'advapi32.lib', 'comdlg32.lib', @@ -229,6 +229,14 @@ if env['PLATFORM'] == 'win32': ], ) + env.Append( + LIBPATH = [ + '$PLATFORMSDK_VISTA/files/Lib', + '$PLATFORMSDK_VISTA/files/VC/LIB', + '$VISUAL_STUDIO/VC/atlmfc/lib', + ], + ) + # TODO(sgk): remove once we upgrade to SCons 0.98.4 for var in ['INCLUDE', 'LIB', 'PATH']: msvs_env[var] = msvs_env[var].split('|', 1)[0] diff --git a/build/SConscript.main.linux b/build/SConscript.main.linux index d092854..9d54d09 100644 --- a/build/SConscript.main.linux +++ b/build/SConscript.main.linux @@ -43,6 +43,8 @@ env = Environment( TARGET_ROOT = '#/$BUILD_TYPE', OBJ_ROOT = '$TARGET_ROOT', + LIBS_DIR = '#/$BUILD_TYPE/Libs', + BASE_DIR = '#/$BUILD_TYPE/base', #BREAKPAD_DIR = '#/$BUILD_TYPE/breakpad', #CHROME_DIR = '#/$BUILD_TYPE/chrome', @@ -87,6 +89,7 @@ env = Environment( PYTHON=sys.executable, + LIBPATH = ['$LIBS_DIR'], # XXX linux-specific: # Build 32-bit libraries/executables. @@ -106,7 +109,9 @@ def ChromeTestProgram(env, *args, **kw): env.AddMethod(ChromeTestProgram, "ChromeTestProgram") def ChromeStaticLibrary(env, *args, **kw): - return env.StaticLibrary(*args, **kw) + result = env.StaticLibrary(*args, **kw) + env.Install('$LIBS_DIR', result) + return result env.AddMethod(ChromeStaticLibrary, "ChromeStaticLibrary") def ChromeSharedLibrary(env, *args, **kw): @@ -192,12 +197,6 @@ if env['PLATFORM'] == 'win32': '$VISUAL_STUDIO/VC/atlmfc/include', ], - LIBPATH = [ - '$PLATFORMSDK_VISTA/files/Lib', - '$PLATFORMSDK_VISTA/files/VC/LIB', - '$VISUAL_STUDIO/VC/atlmfc/lib', - ], - LIBS = [ 'advapi32.lib', 'comdlg32.lib', @@ -226,6 +225,14 @@ if env['PLATFORM'] == 'win32': '/DEBUG', ], ) + + env.Append( + LIBPATH = [ + '$PLATFORMSDK_VISTA/files/Lib', + '$PLATFORMSDK_VISTA/files/VC/LIB', + '$VISUAL_STUDIO/VC/atlmfc/lib', + ], + ) # TODO(sgk): remove once we upgrade to SCons 0.98.4 for var in ['INCLUDE', 'LIB', 'PATH']: diff --git a/build/SConscript.v8 b/build/SConscript.v8 index 7a8f406..2144509 100644 --- a/build/SConscript.v8 +++ b/build/SConscript.v8 @@ -44,10 +44,11 @@ env.AppendENVPath('PATH', env['MSVS_ENV']['PATH']) mksnapshot_exe = File('#/../v8/bin/debug/mksnapshot.exe')
v8_exe = File('#/../v8/Debug/v8_shell.exe')
+v8_lib = File('#/../v8/bin/debug/v8.lib'),
v8_scons_targets = [
mksnapshot_exe,
- File('#/../v8/bin/debug/v8.lib'),
+ v8_lib,
File('#/../v8/bin/debug/snapshot-empty.obj'),
File('#/../v8/vc80.pdb')
]
@@ -63,6 +64,9 @@ env.Install('$V8_DIR', v8) i = env.Install('$TARGET_ROOT', mksnapshot_exe)
env.Alias('webkit', i)
+i = env.Install('$LIBS_DIR', v8_lib)
+env.Alias('webkit', i)
+
v8_shell = env.Command(v8_exe,
[],
diff --git a/net/SConscript b/net/SConscript index 01bd489..6b83174 100644 --- a/net/SConscript +++ b/net/SConscript @@ -162,6 +162,19 @@ env_tests.Prepend( 'WINVER=0x0600',
'_HAS_EXCEPTIONS=0',
],
+ LIBS = [
+ 'googleurl',
+ 'base',
+ 'gtest',
+ 'bzip2',
+ 'icuuc',
+ 'modp_b64',
+ 'zlib',
+ 'net',
+ ]
+)
+
+env_tests.Prepend(
CCFLAGS = [
'/TP',
'/WX',
@@ -185,17 +198,6 @@ env_tests.Append( ],
)
-libs = [
- '$GOOGLEURL_DIR/googleurl.lib',
- '$BASE_DIR/base.lib',
- '$TESTING_DIR/gtest.lib',
- '../third_party/bzip2/bzip2.lib',
- '$ICU38_DIR/icuuc.lib',
- '$MODP_B64_DIR/modp_b64.lib',
- '$ZLIB_DIR/zlib.lib',
- 'net.lib',
-]
-
unittest_files = [
'base/auth_cache_unittest.cc',
@@ -241,7 +243,7 @@ net_unittests = env_tests.ChromeTestProgram( ['net_unittests.exe',
'net_unittests.ilk',
'net_unittests.pdb'],
- unittest_files + libs
+ unittest_files
)
@@ -251,7 +253,7 @@ stress_cache = env_tests.ChromeTestProgram( 'stress_cache.ilk',
'stress_cache.pdb'],
['disk_cache/stress_cache.cc',
- 'disk_cache/disk_cache_test_util.cc'] + libs
+ 'disk_cache/disk_cache_test_util.cc']
)
@@ -260,7 +262,7 @@ crash_cache = env_tests.ChromeTestProgram( 'crash_cache.ilk',
'crash_cache.pdb'],
['tools/crash_cache/crash_cache.cc',
- 'disk_cache/disk_cache_test_util.cc'] + libs
+ 'disk_cache/disk_cache_test_util.cc']
)
@@ -273,7 +275,7 @@ net_perftests = env_tests.ChromeTestProgram( 'base/cookie_monster_perftest.cc',
# TODO(sgk): avoid using .cc from base directly
'$BASE_DIR/run_all_perftests$OBJSUFFIX',
- '$BASE_DIR/perftimer$OBJSUFFIX'] + libs
+ '$BASE_DIR/perftimer$OBJSUFFIX']
)
diff --git a/net/tools/tld_cleanup/SConscript b/net/tools/tld_cleanup/SConscript index 16f2286..4a0ca47 100644 --- a/net/tools/tld_cleanup/SConscript +++ b/net/tools/tld_cleanup/SConscript @@ -35,6 +35,13 @@ env.Prepend( CPPPATH = [
'../../..',
],
+ LIBS = [
+ 'googleurl',
+ 'icuuc',
+ 'base',
+ # We only need to link with net due to use precompiled_net.pch.
+ 'net',
+ ],
)
env.Append(
@@ -62,18 +69,10 @@ input_files = [ 'tld_cleanup.cc',
]
-libs = [
- '$GOOGLEURL_DIR/googleurl.lib',
- '$ICU38_DIR/icuuc.lib',
- '$BASE_DIR/base.lib',
- # We only need to link with net.lib due to use precompiled_net.pch.
- '$NET_DIR/net.lib',
-]
-
exe_targets = env.ChromeProgram(['tld_cleanup',
'tld_cleanup.ilk',
'tld_cleanup.pdb'],
- input_files + libs)
+ input_files)
i = env.Install('$TARGET_ROOT', exe_targets)
env.Alias('net', i)
diff --git a/sandbox/src/SConscript b/sandbox/src/SConscript index 24f88e1..986a783 100644 --- a/sandbox/src/SConscript +++ b/sandbox/src/SConscript @@ -142,8 +142,9 @@ env_tests.Prepend( '/nxcompat',
],
LIBS = [
- 'base.lib',
- 'sandbox.lib',
+ 'base',
+ 'gtest',
+ 'sandbox',
],
LIBPATH = [
'.',
@@ -153,8 +154,6 @@ env_tests.Prepend( controller_obj = env_tests.StaticObject('$TESTS_DIR/common/controller.cc')
-extra_libs = ['$TESTING_DIR/gtest.lib']
-
# Unit Tests
@@ -198,7 +197,7 @@ unit_tests = env_unit_tests.ChromeTestProgram( ['../sbox_unittests.exe',
'../sbox_unittests.ilk',
'../sbox_unittests.pdb'],
- unit_test_files + extra_libs,
+ unit_test_files,
)
@@ -244,7 +243,7 @@ integration_tests = env_integration_tests.ChromeTestProgram( '../sbox_integration_tests.lib',
'../sbox_integration_tests.exp',
'../sbox_integration_tests.pdb'],
- integration_test_files + extra_libs,
+ integration_test_files,
)
@@ -283,7 +282,7 @@ validation_tests = env_validation_tests.ChromeTestProgram( '../sbox_validation_tests.lib',
'../sbox_validation_tests.exp',
'../sbox_validation_tests.pdb'],
- validation_test_files + extra_libs,
+ validation_test_files,
)
diff --git a/webkit/activex_shim_dll/SConscript b/webkit/activex_shim_dll/SConscript index 85ca5f6..5a3a5e2 100644 --- a/webkit/activex_shim_dll/SConscript +++ b/webkit/activex_shim_dll/SConscript @@ -36,6 +36,12 @@ env.Prepend( '$NPAPI_DIR',
'#/..',
],
+ LIBS = [
+ 'activex_shim',
+ 'googleurl',
+ 'icuuc',
+ 'base',
+ ],
)
env.Append(
@@ -57,18 +63,11 @@ env.Append( ],
)
-libs = [
- '$WEBKIT_DIR/activex_shim/activex_shim.lib',
- '$GOOGLEURL_DIR/googleurl.lib',
- '$ICU38_DIR/icuuc.lib',
- '$BASE_DIR/base.lib',
-]
-
input_files = [
'activex_shim_dll.cc',
'activex_shim_dll.def',
]
-dll = env.ChromeSharedLibrary('npaxshim', input_files + libs)
+dll = env.ChromeSharedLibrary('npaxshim', input_files)
i = env.Install('$TARGET_ROOT', dll)
env.Alias('webkit', i)
diff --git a/webkit/glue/plugins/test/SConscript b/webkit/glue/plugins/test/SConscript index 7566c65..c238f4d 100644 --- a/webkit/glue/plugins/test/SConscript +++ b/webkit/glue/plugins/test/SConscript @@ -48,11 +48,15 @@ input_files = [ 'plugin_test.cc', 'plugin_window_size_test.cc', 'npapi_test.def', - - '$BASE_DIR/base.lib', ] env.Append( + LIBS = [ + 'base', + ], +) + +env.Append( CCFLAGS = [ '/TP', '/wd4800', @@ -66,6 +70,7 @@ env.Append( ], LINKFLAGS = [ + '/INCREMENTAL', '/DELAYLOAD:"dwmapi.dll"', '/DELAYLOAD:"uxtheme.dll"', '/FIXED:No', @@ -79,9 +84,13 @@ env.Append( ) dll = env.ChromeSharedLibrary(['npapi_test_plugin', + 'npapi_test_plugin.lib', 'npapi_test_plugin.ilk', 'npapi_test_plugin.pdb'], input_files) +# TODO(sgk): goes away once ChromeSharedLibrary does this for us. +env.Install('$LIBS_DIR', dll[1]) + i = env.Install('$TARGET_ROOT', dll) env.Alias('webkit', i) diff --git a/webkit/tools/npapi_layout_test_plugin/SConscript b/webkit/tools/npapi_layout_test_plugin/SConscript index fbcb9f8..5e8970c 100644 --- a/webkit/tools/npapi_layout_test_plugin/SConscript +++ b/webkit/tools/npapi_layout_test_plugin/SConscript @@ -72,6 +72,10 @@ dll = env.ChromeSharedLibrary(['npapi_layout_test_plugin', 'npapi_layout_test_plugin.pdb'], input_files) +# TODO(sgk): goes away when env.ChromeSharedLibrary() knows how +# to do this for us. +env.Install('$LIBS_DIR', dll[1]) + i = env.Install('$TARGET_ROOT/plugins', dll) env.Alias('webkit', i) diff --git a/webkit/tools/test_shell/SConscript b/webkit/tools/test_shell/SConscript index 85f7091..fcb8528 100644 --- a/webkit/tools/test_shell/SConscript +++ b/webkit/tools/test_shell/SConscript @@ -43,29 +43,43 @@ env_res.Append( ], ) -input_files = [ - 'drag_delegate.cc', - 'drop_delegate.cc', - 'event_sending_controller.cc', - 'layout_test_controller.cc', - 'simple_resource_loader_bridge.cc', - 'test_navigation_controller.cc', - 'test_shell.cc', - 'test_shell_switches.cc', - 'test_shell_request_context.cc', - 'test_webview_delegate.cc', - 'text_input_controller.cc', - 'webview_host.cc', - 'webwidget_host.cc', - 'temp/navigation_controller_base.cc', -] - env.Append( CPPPATH = [ '$BREAKPAD_DIR/src', '$WEBKIT_DIR/glue', '$GTEST_DIR/include', ], + LIBS = [ + 'test_shell', + 'base', + 'base_gfx', + 'breakpad_handler', + 'breakpad_sender', + 'googleurl', + 'net', + 'skia', + 'gtest', + 'bzip2', + 'icuuc', + 'libjpeg', + 'libpng', + 'libxml', + 'libxslt', + 'modp_b64', + 'zlib', + 'v8', + 'JavaScriptCore_pcre', + 'Port', + 'activex_shim', + 'WTF', + 'V8Bindings', + 'WebCore', + 'default_plugin', + 'Glue', + ], +) + +env.Append( CCFLAGS = [ '/TP', '/WX', @@ -93,8 +107,24 @@ env.Append( ], ) -lib = env.ChromeStaticLibrary('test_shell', input_files) +input_files = [ + 'drag_delegate.cc', + 'drop_delegate.cc', + 'event_sending_controller.cc', + 'layout_test_controller.cc', + 'simple_resource_loader_bridge.cc', + 'test_navigation_controller.cc', + 'test_shell.cc', + 'test_shell_switches.cc', + 'test_shell_request_context.cc', + 'test_webview_delegate.cc', + 'text_input_controller.cc', + 'webview_host.cc', + 'webwidget_host.cc', + 'temp/navigation_controller_base.cc', +] +lib = env.ChromeStaticLibrary('test_shell', input_files) @@ -104,42 +134,16 @@ resources = [ '$WEBKIT_DIR/build/localized_strings/webkit_strings_en-US.res', ] -components = [ - lib, - - '$BASE_DIR/base.lib', - '$BASE_DIR/gfx/base_gfx.lib', - '$BREAKPAD_DIR/breakpad_handler.lib', - '$BREAKPAD_DIR/breakpad_sender.lib', - '$GOOGLEURL_DIR/googleurl.lib', - '$NET_DIR/net.lib', - '$SKIA_DIR/skia.lib', - '$TESTING_DIR/gtest.lib', - '$BZIP2_DIR/bzip2.lib', - '$ICU38_DIR/icuuc.lib', - '$LIBJPEG_DIR/libjpeg.lib', - '$LIBPNG_DIR/libpng.lib', - '$LIBXML_DIR/libxml.lib', - '$LIBXSLT_DIR/libxslt.lib', - '$MODP_B64_DIR/modp_b64.lib', - '$ZLIB_DIR/zlib.lib', - '$V8_DIR/v8.lib', - '$V8_DIR/snapshot-empty.obj', - '$WEBKIT_DIR/JavaScriptCore_pcre.lib', - '$WEBKIT_DIR/Port.lib', - '$WEBKIT_DIR/activex_shim/activex_shim.lib', - '$WEBKIT_DIR/build/JavaScriptCore/WTF.lib', - '$WEBKIT_DIR/build/V8Bindings/V8Bindings.lib', - '$WEBKIT_DIR/build/WebCore/WebCore.lib', - '$WEBKIT_DIR/default_plugin/default_plugin.lib', - '$WEBKIT_DIR/glue/Glue.lib', + +exe_input_files = [ + 'test_shell_main.cc', + '$V8_DIR/snapshot-empty$OBJSUFFIX' ] test_shell = env.ChromeProgram(['test_shell.exe', 'test_shell.ilk', 'test_shell.pdb'], - components + resources + - ['test_shell_main.cc']) + resources + exe_input_files) i = env.Install('$TARGET_ROOT', test_shell) env.Alias('webkit', i) @@ -195,11 +199,13 @@ test_files = [ '$WEBKIT_DIR/port/platform/image-decoders/bmp/BMPImageDecoder_unittest.cpp', '$WEBKIT_DIR/port/platform/image-decoders/ico/ICOImageDecoder_unittest.cpp', '$WEBKIT_DIR/port/platform/image-decoders/xbm/XBMImageDecoder_unittest.cpp', + + '$V8_DIR/snapshot-empty$OBJSUFFIX', ] test_shell_tests = env.ChromeTestProgram(['test_shell_tests', 'test_shell_tests.ilk', 'test_shell_tests.pdb'], - components + resources + test_files) + resources + test_files) i = env.Install('$TARGET_ROOT', test_shell_tests) env.Alias('webkit', i) |