SConscript (3499:597f3f6c9775) SConscript (3515:98655e4fd9f1)
1# -*- mode:python -*-
2
3# Copyright (c) 2004-2005 The Regents of The University of Michigan
4# All rights reserved.
5#
6# Redistribution and use in source and binary forms, with or without
7# modification, are permitted provided that the following conditions are
8# met: redistributions of source code must retain the above copyright

--- 385 unchanged lines hidden (view full) ---

394 stripped_bin = bin + '.stripped'
395 newEnv.Command(stripped_bin, bin, 'strip $SOURCE -o $TARGET')
396 bin = stripped_bin
397 targets = newEnv.Concat(exe, [bin, 'python/m5py.zip'])
398 newEnv.M5Binary = targets[0]
399 envList.append(newEnv)
400
401# Debug binary
1# -*- mode:python -*-
2
3# Copyright (c) 2004-2005 The Regents of The University of Michigan
4# All rights reserved.
5#
6# Redistribution and use in source and binary forms, with or without
7# modification, are permitted provided that the following conditions are
8# met: redistributions of source code must retain the above copyright

--- 385 unchanged lines hidden (view full) ---

394 stripped_bin = bin + '.stripped'
395 newEnv.Command(stripped_bin, bin, 'strip $SOURCE -o $TARGET')
396 bin = stripped_bin
397 targets = newEnv.Concat(exe, [bin, 'python/m5py.zip'])
398 newEnv.M5Binary = targets[0]
399 envList.append(newEnv)
400
401# Debug binary
402# Solaris seems to have some issue with DWARF2 debugging information, it's ok
403# with stabs though
404if sys.platform == 'sunos5':
405 debug_flag = '-gstabs+'
406else:
407 debug_flag = '-ggdb3'
408
402makeEnv('debug', '.do',
409makeEnv('debug', '.do',
403 CCFLAGS = Split('-g3 -gdwarf-2 -O0'),
410 CCFLAGS = Split('%s -O0' % debug_flag),
404 CPPDEFINES = 'DEBUG')
405
406# Optimized binary
407makeEnv('opt', '.o',
408 CCFLAGS = Split('-g -O3'))
409
410# "Fast" binary
411makeEnv('fast', '.fo', strip = True,
412 CCFLAGS = Split('-O3'),
413 CPPDEFINES = 'NDEBUG')
414
415# Profiled binary
416makeEnv('prof', '.po',
417 CCFLAGS = Split('-O3 -g -pg'),
418 LINKFLAGS = '-pg')
419
420Return('envList')
411 CPPDEFINES = 'DEBUG')
412
413# Optimized binary
414makeEnv('opt', '.o',
415 CCFLAGS = Split('-g -O3'))
416
417# "Fast" binary
418makeEnv('fast', '.fo', strip = True,
419 CCFLAGS = Split('-O3'),
420 CPPDEFINES = 'NDEBUG')
421
422# Profiled binary
423makeEnv('prof', '.po',
424 CCFLAGS = Split('-O3 -g -pg'),
425 LINKFLAGS = '-pg')
426
427Return('envList')