def make_uplid(ctx): """Create the Uplid representing the current build platform. Args: ctx (ConfigurationContext): The waf configuration context. Returns: effective_ufid, actual_ufid """ os_type, os_name, cpu_type, os_ver = sysutil.get_os_info() comp_type, comp_ver = get_comp_info(ctx) actual_uplid = optiontypes.Uplid(os_type, os_name, cpu_type, os_ver, comp_type, comp_ver) env_uplid_str = os.getenv('BDE_WAF_UPLID') if env_uplid_str: effective_ufid = optiontypes.Uplid.from_str(env_uplid_str) else: effective_ufid = actual_uplid return effective_ufid, actual_uplid
def get_os_info(): platform_str = sysutil.unversioned_platform() if platform_str == 'cygwin': return sysutil.get_win32_os_info_from_cygwin() else: return sysutil.get_os_info()