-
Edward Brash authored
and SCons version checking (now checks for version 4.9.9 of SCons, which is the newly implemented version number in the local SCons installation (in podd). Note that this change will now require use of that updated local version as packaged with podd. 2. Change to SConstruct.py to add -DHALLC_MODS defines (now consistent with Makefile) for conditional compilation in certain parts of podd. 3. Improvement in configuration for 64bit/32bit compilation on Linux.
Edward Brash authoredand SCons version checking (now checks for version 4.9.9 of SCons, which is the newly implemented version number in the local SCons installation (in podd). Note that this change will now require use of that updated local version as packaged with podd. 2. Change to SConstruct.py to add -DHALLC_MODS defines (now consistent with Makefile) for conditional compilation in certain parts of podd. 3. Improvement in configuration for 64bit/32bit compilation on Linux.
configure.py 2.14 KiB
import platform
import os
def config(env,args):
if env['PLATFORM'] == 'posix':
if (platform.machine() == 'x86_64'):
print "Got a 64-bit processor, I can do a 64-bit build in theory..."
for element in platform.architecture():
if (element == '32bit'):
print '32-bit Linux build'
env['MEMORYMODEL'] = '32bit'
import linux32
linux32.config(env, args)
break
elif (element == '64bit'):
print '64-bit Linux build'
env['MEMORYMODEL'] = '64bit'
import linux64
linux64.config(env, args)
break
else:
print 'Memory model not specified, so I\'m building 32-bit...'
env['MEMORYMODEL'] = '32bit'
import linux32
linux32.config(env, args)
else:
print '32-bit Linux Build.'
env['MEMORYMODEL'] = '32bit'
import linux32
linux32.config(env, args)
# elif env['PLATFORM'] == 'win32':
# if (os.environ['PROCESSOR_ARCHITECTURE'] == 'AMD64' or (os.environ.has_key('PROCESSOR_ARCHITEW6432') and os.environ['PROCESSOR_ARCHITEW6432'] == 'AMD64')):
# print "Got a 64-bit processor, I can do a 64-bit build in theory..."
# if args.get('32bit', 0):
# print '32-bit Windows build.'
# #import win6432
# #win6432.config(env, args)
# elif args.get('64bit', 0):
# print '64-bit Windows build.'
# #import win64
# #win64.config(env, args)
# else:
# print 'Memory model not specified, so I\'m building 32-bit.'
# #import win6432
# #win6432.config(env, args)
# else:
# print '32-bit Windows build.'
# #import win32
# #win32.config(env, args)
elif env['PLATFORM'] == 'darwin':
print 'OS X Darwin is a 64-bit build.'
env['MEMORYMODEL'] = '64bit'
import darwin64
darwin64.config(env, args)
else:
print 'ERROR! unrecognized platform. Twonk.'
#end configure.py