from os import popen
import os
import sys
def bfs10122():
  return (sys.platform in ('win32', 'cygwin'))

def bfs10124():
  return (sys.platform == 'darwin')

def bfs10123():
  return sys.platform.startswith('linux')

def bfs10125():
  if bfs10122():
    return 'win'
  elif bfs10124():
    return 'macosx'
  elif bfs10123():
    return 'linux'


def bfs10126():
  if bfs10122():
    return ('PROGRAMFILES(X86)' not in os.environ)

  assert (bfs10123() or bfs10124())
  return (bfs10127() in ('i386', 'i686'))

def bfs10127():
  return popen('uname -m').read().strip()

def bfs10130():
  if bfs10122():
    return ('PROGRAMFILES(X86)' in os.environ)

  assert (bfs10123() or bfs10124())
  return (bfs10127() in ('x86_64', 'ia64', 'amd64'))

