# check that the command has been called with an application
src.check_config_has_application( runner.cfg )
+ # write warning if platform is not declared as supported
+ src.check_platform_is_supported( runner.cfg, logger )
+
# Print some informations
logger.write(_('Executing the compile commands in the build '
'directories of the products of '
product_pyconf_cfg[section].archive_info.archive_name =\
p_info.name + ".tgz"
- if (with_vcs) and src.product.product_is_vcs(p_info):
+ # save git repositories for vcs products, even if archive is not in VCS mode
+ # in this case the user will be able to change get_source flag and work with git
+ if src.product.product_is_vcs(p_info):
# in vcs mode we must replace explicitely the git server url
# (or it will not be found later because project files are not exported in archives)
for section in product_pyconf_cfg:
# check that the command has been called with an application
src.check_config_has_application( runner.cfg )
+ # write warning if platform is not declared as supported
+ src.check_platform_is_supported( runner.cfg, logger )
+
products_infos = src.product.get_products_list(options, runner.cfg, logger)
# Construct the arguments to pass to the clean, source and patch commands
details.append(message)
raise SatException( message )
+def check_platform_is_supported( config, logger ):
+ """check that the platform is supported, write warning if not.
+
+ :param config class 'common.pyconf.Config': The config.
+ """
+ if 'platform' in config.APPLICATION and config.VARS.dist not in config.APPLICATION.platform:
+ msg = "WARNING: Your application configuration is not supported on this platform (%s)\n"\
+ " Please consider using the native application!" % config.VARS.dist
+ logger.write("\n%s\n\n" % printcolors.printcWarning(msg), 1)
+ return
+
def check_config_has_profile( config, details = None ):
"""\
check that the config has the key APPLICATION.profile.