Changeset 8a26f82 in mainline for tools/ew.py
- Timestamp:
- 2013-03-24T17:31:12Z (12 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- b2fa2d86
- Parents:
- b183ce0a
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tools/ew.py
rb183ce0a r8a26f82 36 36 import subprocess 37 37 import autotool 38 import platform 38 39 39 40 def run_in_console(cmd, title): … … 42 43 subprocess.call(cmdline, shell = True); 43 44 44 def pc_options(): 45 return '-enable-kvm' 45 def get_host_native_width(): 46 return int(platform.architecture()[0].strip('bit')) 47 48 def pc_options(guest_width): 49 opts = '' 50 51 # Do not enable KVM if running 64 bits HelenOS 52 # on 32 bits host 53 host_width = get_host_native_width() 54 if guest_width <= host_width: 55 opts = opts + ' -enable-kvm' 56 57 # Remove the leading space 58 return opts[1:] 46 59 47 60 def malta_options(): … … 50 63 def platform_to_qemu_options(platform, machine): 51 64 if platform == 'amd64': 52 return 'system-x86_64', pc_options( )65 return 'system-x86_64', pc_options(64) 53 66 elif platform == 'arm32': 54 67 return 'system-arm', '' 55 68 elif platform == 'ia32': 56 return 'system-i386', pc_options( )69 return 'system-i386', pc_options(32) 57 70 elif platform == 'mips32': 58 71 if machine == 'lmalta':
Note:
See TracChangeset
for help on using the changeset viewer.