From 4418b5897335bf143ae6fbfda724f385265601a7 Mon Sep 17 00:00:00 2001 From: "erik.corry@gmail.com" Date: Tue, 13 Apr 2010 09:01:30 +0000 Subject: [PATCH] Fix cross compilation of snapshot builds using scons. With this change we also activate snapshots for ARM benchmarking builds. Review URL: http://codereview.chromium.org/1627019 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4394 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/SConscript | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/SConscript b/src/SConscript index 3eaa6cb456..5add9999d1 100755 --- a/src/SConscript +++ b/src/SConscript @@ -306,7 +306,12 @@ def ConfigureObjectFiles(): source_objs = context.ConfigureObject(env, source_files) non_snapshot_files = [dtoa_obj, source_objs] - # Create snapshot if necessary. + # Create snapshot if necessary. For cross compilation you should either + # do without snapshots and take the performance hit or you should build a + # host VM with the simulator=arm and snapshot=on options and then take the + # resulting snapshot.cc file from obj/release and put it in the src + # directory. Then rebuild the VM with the cross compiler and specify + # snapshot=nobuild on the scons command line. empty_snapshot_obj = context.ConfigureObject(env, 'snapshot-empty.cc') mksnapshot_env = env.Copy() mksnapshot_env.Replace(**context.flags['mksnapshot']) @@ -316,7 +321,7 @@ def ConfigureObjectFiles(): if context.build_snapshot: snapshot_cc = env.Snapshot('snapshot.cc', mksnapshot, LOGFILE=File('snapshot.log').abspath) else: - snapshot_cc = Command('snapshot.cc', [], []) + snapshot_cc = 'snapshot.cc' snapshot_obj = context.ConfigureObject(env, snapshot_cc, CPPPATH=['.']) else: snapshot_obj = empty_snapshot_obj