Beispiel #1
0
def get_msvc_versions(conf, eval_and_save=True):
	"""
	:return: list of compilers installed
	:rtype: list of string
	"""
	if conf.env['MSVC_INSTALLED_VERSIONS']:
		return conf.env['MSVC_INSTALLED_VERSIONS']

	# Gather all the compiler versions and targets. This phase can be lazy
	# per lazy detection settings.
	lst = []
	conf.gather_icl_versions(lst)
	conf.gather_intel_composer_versions(lst)
	conf.gather_wsdk_versions(lst)
	conf.gather_msvc_versions(lst)

	# Override lazy detection by evaluating after the fact.
	if eval_and_save:
		def checked_target(t):
			target,(arch,paths) = t
			try:
				paths.evaluate()
			except conf.errors.ConfigurationError:
				return None
			else:
				return t
		lst = [(version, list(filter(checked_target, targets))) for version, targets in lst]
		conf.env['MSVC_INSTALLED_VERSIONS'] = lst

	return lst
Beispiel #2
0
def get_msvc_versions(conf, eval_and_save=True):
    """
	:return: list of compilers installed
	:rtype: list of string
	"""
    if conf.env['MSVC_INSTALLED_VERSIONS']:
        return conf.env['MSVC_INSTALLED_VERSIONS']

    # Gather all the compiler versions and targets. This phase can be lazy
    # per lazy detection settings.
    lst = []
    conf.gather_icl_versions(lst)
    conf.gather_intel_composer_versions(lst)
    conf.gather_wsdk_versions(lst)
    conf.gather_msvc_versions(lst)

    # Override lazy detection by evaluating after the fact.
    if eval_and_save:

        def checked_target(t):
            target, (arch, paths) = t
            try:
                paths.evaluate()
            except conf.errors.ConfigurationError:
                return None
            else:
                return t

        lst = [(version, list(filter(checked_target, targets)))
               for version, targets in lst]
        conf.env['MSVC_INSTALLED_VERSIONS'] = lst

    return lst
Beispiel #3
0
def get_msvc_versions(conf):
	if not conf.env['MSVC_INSTALLED_VERSIONS']:
		lst=[]
		conf.gather_icl_versions(lst)
		conf.gather_intel_composer_versions(lst)
		conf.gather_wsdk_versions(lst)
		conf.gather_msvc_versions(lst)
		conf.env['MSVC_INSTALLED_VERSIONS']=lst
	return conf.env['MSVC_INSTALLED_VERSIONS']
Beispiel #4
0
def get_msvc_versions(conf):
    if not conf.env['MSVC_INSTALLED_VERSIONS']:
        lst = []
        conf.gather_icl_versions(lst)
        conf.gather_intel_composer_versions(lst)
        conf.gather_wsdk_versions(lst)
        conf.gather_msvc_versions(lst)
        conf.env['MSVC_INSTALLED_VERSIONS'] = lst
    return conf.env['MSVC_INSTALLED_VERSIONS']
def get_msvc_versions(conf):
    """
	:return: list of compilers installed
	:rtype: list of string
	"""
    if not conf.env['MSVC_INSTALLED_VERSIONS']:
        lst = []
        conf.gather_icl_versions(lst)
        conf.gather_intel_composer_versions(lst)
        conf.gather_wsdk_versions(lst)
        conf.gather_msvc_versions(lst)
        conf.env['MSVC_INSTALLED_VERSIONS'] = lst
    return conf.env['MSVC_INSTALLED_VERSIONS']
Beispiel #6
0
def get_msvc_versions(conf):
	"""
	:return: list of compilers installed
	:rtype: list of string
	"""
	if not conf.env['MSVC_INSTALLED_VERSIONS']:
		lst = []
		conf.gather_icl_versions(lst)
		conf.gather_intel_composer_versions(lst)
		conf.gather_wsdk_versions(lst)
		conf.gather_msvc_versions(lst)
		conf.env['MSVC_INSTALLED_VERSIONS'] = lst
	return conf.env['MSVC_INSTALLED_VERSIONS']
Beispiel #7
0
def get_msvc_versions(conf,eval_and_save=True):
	if conf.env['MSVC_INSTALLED_VERSIONS']:
		return conf.env['MSVC_INSTALLED_VERSIONS']
	lst=[]
	conf.gather_icl_versions(lst)
	conf.gather_intel_composer_versions(lst)
	conf.gather_wsdk_versions(lst)
	conf.gather_msvc_versions(lst)
	if eval_and_save:
		def checked_target(t):
			target,(arch,paths)=t
			try:
				paths.evaluate()
			except conf.errors.ConfigurationError:
				return None
			else:
				return t
		lst=[(version,list(filter(checked_target,targets)))for version,targets in lst]
		conf.env['MSVC_INSTALLED_VERSIONS']=lst
	return lst
Beispiel #8
0
def get_msvc_versions(conf, eval_and_save=True):
    if conf.env['MSVC_INSTALLED_VERSIONS']:
        return conf.env['MSVC_INSTALLED_VERSIONS']
    lst = []
    conf.gather_icl_versions(lst)
    conf.gather_intel_composer_versions(lst)
    conf.gather_wsdk_versions(lst)
    conf.gather_msvc_versions(lst)
    if eval_and_save:

        def checked_target(t):
            target, (arch, paths) = t
            try:
                paths.evaluate()
            except conf.errors.ConfigurationError:
                return None
            else:
                return t

        lst = [(version, filter(checked_target, targets))
               for version, targets in lst]
        conf.env['MSVC_INSTALLED_VERSIONS'] = lst
    return lst