diff options
author | mpcomplete@google.com <mpcomplete@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-10-20 18:49:49 +0000 |
---|---|---|
committer | mpcomplete@google.com <mpcomplete@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-10-20 18:49:49 +0000 |
commit | 8f643b7837cee97b2be71efd0e206568d922d291 (patch) | |
tree | b7b3ecacd650d8e31f1230af7c8a1f9625edd6dc | |
parent | fed158a8addc9742511d2ce8925a9c29e94c003d (diff) | |
download | chromium_src-8f643b7837cee97b2be71efd0e206568d922d291.zip chromium_src-8f643b7837cee97b2be71efd0e206568d922d291.tar.gz chromium_src-8f643b7837cee97b2be71efd0e206568d922d291.tar.bz2 |
Gears SConscript now build vista_broker and crash_sender.
Review URL: http://codereview.chromium.org/7393
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@3614 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | gears/SConscript | 14 | ||||
-rw-r--r-- | gears/SConscript.common | 25 | ||||
-rw-r--r-- | gears/SConscript.dll | 42 |
3 files changed, 76 insertions, 5 deletions
diff --git a/gears/SConscript b/gears/SConscript index 9b9c562..fd96489 100644 --- a/gears/SConscript +++ b/gears/SConscript @@ -242,6 +242,7 @@ env.Replace( CCFLAGS = [], CPPDEFINES = [], LIBS = [], + ARFLAGS = [], LINKFLAGS = [], ) @@ -360,11 +361,15 @@ if env['OS'] in ['win32', 'wince']: # Do not export UTF functions. 'U_STATIC_IMPLEMENTATION', ], +# Static lib flags. + ARFLAGS = [ + '/NOLOGO', + ], +# Shared lib and exe flags. LINKFLAGS = [ '/NOLOGO', '/DEBUG', '/RELEASE', - '/PDB:${TARGET.base}.pdb', # Set the preferred base address. This value was chosen because (a) it's near # the top of the valid address range, and (b) it doesn't conflict with other @@ -379,6 +384,7 @@ if env['OS'] in ['win32', 'wince']: '/W3', '/WX', '/GR-', + '/Fd"${TARGET.base}.pdb"', ], CXXFLAGS = [ '/TP', @@ -413,6 +419,9 @@ if env['OS'] in ['win32', 'wince']: 'BREAKPAD_AVOID_STREAMS', 'XP_WIN', ], + ARFLAGS = [ + '/MACHINE:X86', + ], LINKFLAGS = [ '/MACHINE:X86', '/NODEFAULTLIB:msvcrt', @@ -455,6 +464,9 @@ if env['OS'] in ['win32', 'wince']: '_CE_ALLOW_SINGLE_THREADED_OBJECTS_IN_MTA', '_CE_CRT_ALLOW_WIN_MINMAX', ], + ARFLAGS = [ + '/MACHINE:THUMB', + ], LINKFLAGS = [ '/MACHINE:THUMB', '/NODEFAULTLIB:secchk.lib', diff --git a/gears/SConscript.common b/gears/SConscript.common index 3946f6f..cfb7364 100644 --- a/gears/SConscript.common +++ b/gears/SConscript.common @@ -37,9 +37,22 @@ env.Prepend( m4srcs = [] binsrcs = [] +crash_sender_srcs = [] ipc_test_srcs = [] #----------------------------------------------------------------------------- +# crash_sender + +if env['OS'] == 'win32': + crash_sender_srcs += [ + '$OPEN_DIR/crash_sender/crash_sender_win32.cc', + '$THIRD_PARTY_DIR/breakpad/src/client/windows/sender/crash_report_sender.cc', + '$THIRD_PARTY_DIR/breakpad/src/common/windows/http_upload.cc', + ] +elif env['OS'] == 'osx': + print 'TODO: crash_sender' + +#----------------------------------------------------------------------------- # ipc_test m4srcs += [ @@ -135,3 +148,15 @@ common_targets['src'] = [env.SharedObject(bin) for bin in bins] Export('common_targets') env.Program('ipc_test', ipc_test_srcs) + +# Note: crash_sender.exe name needs to stay in sync with name used in +# exception_handler_win32.cc and exception_handler_osx/google_breakpad.mm. +crash_sender = None +if env['OS'] == 'win32': + crash_sender = env.Program('crash_sender', crash_sender_srcs, + LIBS = Split('advapi32.lib shell32.lib wininet.lib')) +elif env['OS'] == 'osx': + crash_sender = env.Program('crash_sender', crash_sender_srcs, + FRAMEWORKS = Split('Carbon Cocoa Foundation IOKit SystemConfiguration'), + LIBS='stdc++') +env.Alias('gears', crash_sender) diff --git a/gears/SConscript.dll b/gears/SConscript.dll index 0d0ddbf..cdefdca 100644 --- a/gears/SConscript.dll +++ b/gears/SConscript.dll @@ -33,7 +33,7 @@ env.Tool('midl') if env['BROWSER'] == 'IE': env.Replace( SCONS_DIR = '../../../..', # the scons dir relative to OPEN_DIR - IDLINCPREFIX = '/I$SCONS_DIR', + IDLINCPREFIX = '/I$SCONS_DIR/', IDLINCSUFFIX = '', _IDLINCFLAGS = ('${_concat(IDLINCPREFIX, CPPPATH, IDLINCSUFFIX, ' '__env__, RDirs, TARGET, SOURCE)}'), @@ -250,6 +250,9 @@ env_res.Replace( CPPDEFINES = [ '_UNICODE', 'UNICODE', + '$EXTRA_DEFINES', + ], + EXTRA_DEFINES = [ 'BROWSER_${BROWSER}=1', ], CPPPATH = [ @@ -547,7 +550,6 @@ if env['OS'] == 'win32': '$OPEN_DIR/base/common/file_win32.cc', '$OPEN_DIR/base/common/message_queue_cr.cc', '$OPEN_DIR/base/common/time_utils_win32.cc', - '$OPEN_DIR/base/common/vista_utils.cc', '$OPEN_DIR/base/ie/ie_version.cc', ] @@ -1031,6 +1033,21 @@ if not env['OFFICIAL_BUILD']: ] #----------------------------------------------------------------------------- +# vista_broker + +vista_broker_srcs = [ + '$OPEN_DIR/base/common/process_utils_win32.cc', + '$OPEN_DIR/base/common/string16.cc', + '$OPEN_DIR/base/common/string_utils.cc', + '$OPEN_DIR/desktop/shortcut_utils_win32.cc', + '$OPEN_DIR/vista_broker/vista_broker.cc', +] + +vista_broker_srcs += [ + '$THIRD_PARTY_DIR/convert_utf/ConvertUTF.c' +] + +#----------------------------------------------------------------------------- # resources dll_resources = [] @@ -1051,6 +1068,14 @@ if env['OS'] in ['win32', 'wince']: if env['OS'] == 'wince': dll_resources += [env_res.RES('$GENFILES_DIR/setup.rc')] + vista_broker_resources = env_res.RES( + '$GENFILES_DIR/vista_broker_string_table.res', + '$GENFILES_DIR/string_table.rc', + EXTRA_DEFINES = 'VISTA_BROKER=1') + vista_broker_resources += env_res.RES( + '$OPEN_DIR/vista_broker/vista_broker.rc', + EXTRA_DEFINES = 'VISTA_BROKER=1') + #----------------------------------------------------------------------------- # libs @@ -1079,9 +1104,8 @@ elif env['BROWSER'] == 'IE': # - spidermonkey # - libspeex # - libtremor -# - vista broker # TODO: other targets -# - installer (safari, android, iemobile ...) +# - installer (safari, android, ...) # Now build the dependency tree. def PatternRule(t, s): return utils.PatternRule(t, s, env) @@ -1161,3 +1185,13 @@ env.Alias('gears', module) if env['OS'] == 'wince': wince_setup = env.ChromeSharedLibrary('setup', wince_setup_srcs) + +if env['OS'] == 'win32' and env['BROWSER'] == 'IE': +# Note: We use IE_OUTDIR so that relative path from gears.dll is same in +# development environment as deployment environment. +# Note: vista_broker.exe needs to stay in sync with name used in +# desktop_win32.cc. +# TODO(aa): This can move to common_outdir like crash_sender.exe + vista_broker = env.Program('vista_broker', + vista_broker_srcs + vista_broker_resources) + env.Alias('gears', vista_broker) |