Index: SConstruct |
diff --git a/SConstruct b/SConstruct |
index 82b83ceafa0c0dfd87dff352b5cda7ea63151dbc..ed9ddd4b11c450f89b9d3fafb18c8508cb3e839b 100644 |
--- a/SConstruct |
+++ b/SConstruct |
@@ -201,6 +201,9 @@ LIBRARY_FLAGS = { |
}, |
'gdbjit:on': { |
'CPPDEFINES': ['ENABLE_GDB_JIT_INTERFACE'] |
+ }, |
+ 'compress_startup_data:bz2': { |
+ 'CPPDEFINES': ['COMPRESS_STARTUP_DATA_BZ2'] |
} |
}, |
'msvc': { |
@@ -338,6 +341,9 @@ MKSNAPSHOT_EXTRA_FLAGS = { |
'os:win32': { |
'LIBS': ['winmm', 'ws2_32'], |
}, |
Søren Thygesen Gjesse
2011/04/29 06:50:29
As this is Linux only I think this should be eithe
mnaganov (inactive)
2011/04/29 12:07:58
Done.
|
+ 'compress_startup_data:bz2': { |
+ 'LIBS': ['bz2'] |
+ }, |
}, |
'msvc': { |
'all': { |
@@ -478,6 +484,10 @@ SAMPLE_FLAGS = { |
'CCFLAGS': ['-g', '-O0'], |
'CPPDEFINES': ['DEBUG'] |
}, |
+ 'compress_startup_data:bz2': { |
+ 'CPPDEFINES': ['COMPRESS_STARTUP_DATA_BZ2'], |
Søren Thygesen Gjesse
2011/04/29 06:50:29
Ditto for the LIBS part.
mnaganov (inactive)
2011/04/29 12:07:58
Done.
|
+ 'LIBS': ['bz2'] |
+ }, |
}, |
'msvc': { |
'all': { |
@@ -919,7 +929,12 @@ SIMPLE_OPTIONS = { |
'values': ['mips32r2', 'mips32r1'], |
'default': 'mips32r2', |
'help': 'mips variant' |
- } |
+ }, |
+ 'compress_startup_data': { |
+ 'values': ['off', 'bz2'], |
+ 'default': 'off', |
+ 'help': 'compress startup data (snapshot) [Linux only]' |
+ }, |
} |
ALL_OPTIONS = dict(PLATFORM_OPTIONS, **SIMPLE_OPTIONS) |
@@ -1042,6 +1057,8 @@ def VerifyOptions(env): |
print env['arch'] |
print env['simulator'] |
Abort("Option unalignedaccesses only supported for the ARM architecture.") |
+ if env['os'] != 'linux' and env['compress_startup_data'] != 'off': |
+ Abort("Startup data compression is only available on Linux") |
for (name, option) in ALL_OPTIONS.iteritems(): |
if (not name in env): |
message = ("A value for option %s must be specified (%s)." % |