SConscript (8737:770ccf3af571) SConscript (8946:fb6c89334b86)
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

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

27# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28#
29# Authors: Nathan Binkert
30
31import os, subprocess
32
33Import('main')
34
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

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

27# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28#
29# Authors: Nathan Binkert
30
31import os, subprocess
32
33Import('main')
34
35from m5.util import compareVersions
36
35elf_files = []
36def ElfFile(filename):
37 elf_files.append(File(filename))
38
39ElfFile('elf_begin.c')
40ElfFile('elf_cntl.c')
41ElfFile('elf_data.c')
42ElfFile('elf_end.c')

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

86ElfFile('libelf_xlate.c')
87
88ElfFile('libelf_convert.c')
89ElfFile('libelf_fsize.c')
90ElfFile('libelf_msize.c')
91
92m4env = main.Clone()
93if m4env['GCC']:
37elf_files = []
38def ElfFile(filename):
39 elf_files.append(File(filename))
40
41ElfFile('elf_begin.c')
42ElfFile('elf_cntl.c')
43ElfFile('elf_data.c')
44ElfFile('elf_end.c')

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

88ElfFile('libelf_xlate.c')
89
90ElfFile('libelf_convert.c')
91ElfFile('libelf_fsize.c')
92ElfFile('libelf_msize.c')
93
94m4env = main.Clone()
95if m4env['GCC']:
94 major,minor,dot = [int(x) for x in m4env['GCC_VERSION'].split('.')]
95 if major >= 4:
96 if compareVersions(m4env['GCC_VERSION'], '4') >= 0:
96 m4env.Append(CCFLAGS=['-Wno-pointer-sign'])
97 m4env.Append(CCFLAGS=['-Wno-pointer-sign'])
98 if compareVersions(m4env['GCC_VERSION'], '4.6') >= 0:
99 m4env.Append(CCFLAGS=['-Wno-unused-but-set-variable',
100 '-Wno-implicit-function-declaration'])
97if m4env['CLANG']:
98 m4env.Append(CCFLAGS=['-Wno-initializer-overrides', '-Wno-pointer-sign'])
99m4env.Append(CCFLAGS=['-Wno-implicit'])
100del m4env['CPPPATH']
101
102# If we have gm4 use it
103if m4env.Detect('gm4'):
104 m4env['M4'] = 'gm4'

--- 25 unchanged lines hidden ---
101if m4env['CLANG']:
102 m4env.Append(CCFLAGS=['-Wno-initializer-overrides', '-Wno-pointer-sign'])
103m4env.Append(CCFLAGS=['-Wno-implicit'])
104del m4env['CPPPATH']
105
106# If we have gm4 use it
107if m4env.Detect('gm4'):
108 m4env['M4'] = 'gm4'

--- 25 unchanged lines hidden ---