Deleted Added
sdiff udiff text old ( 4678:fd95d7ddd1ee ) new ( 4742:0936d7c23999 )
full compact
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

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

62# options as well.
63#
64###################################################
65
66import sys
67import os
68import subprocess
69
70from os.path import join as joinpath
71
72# Check for recent-enough Python and SCons versions. If your system's
73# default installation of Python is not recent enough, you can use a
74# non-default installation of the Python interpreter by either (1)
75# rearranging your PATH so that scons finds the non-default 'python'
76# first or (2) explicitly invoking an alternative interpreter on the
77# scons script, e.g., "/usr/local/bin/python2.4 `which scons` [args]".
78EnsurePythonVersion(2,4)

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

92ROOT = Dir('.').abspath
93
94# Path to the M5 source tree.
95SRCDIR = joinpath(ROOT, 'src')
96
97# tell python where to find m5 python code
98sys.path.append(joinpath(ROOT, 'src/python'))
99
100###################################################
101#
102# Figure out which configurations to set up based on the path(s) of
103# the target(s).
104#
105###################################################
106
107# Find default configuration & binary.

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

254if not env.has_key('SWIG'):
255 print 'Error: SWIG utility not found.'
256 print ' Please install (see http://www.swig.org) and retry.'
257 Exit(1)
258
259# Check for appropriate SWIG version
260swig_version = os.popen('swig -version').read().split()
261# First 3 words should be "SWIG Version x.y.z"
262if len(swig_version) < 3 or \
263 swig_version[0] != 'SWIG' or swig_version[1] != 'Version':
264 print 'Error determining SWIG version.'
265 Exit(1)
266
267min_swig_version = '1.3.28'
268if compare_versions(swig_version[2], min_swig_version) < 0:
269 print 'Error: SWIG version', min_swig_version, 'or newer required.'
270 print ' Installed version:', swig_version[2]
271 Exit(1)

--- 420 unchanged lines hidden ---