From: Serge Rehbinder Date: Wed, 21 Sep 2016 13:04:32 +0000 (+0200) Subject: bug fix: do not expect a product that do not compile when compiling a product that... X-Git-Tag: 5.0.0a1~106 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=46ab36d0a9970a26f0f8c28af83c7f8c1d21e3f6;p=tools%2Fsat.git bug fix: do not expect a product that do not compile when compiling a product that has the first product in its dependencies --- diff --git a/src/product.py b/src/product.py index f3e2682..05db3a0 100644 --- a/src/product.py +++ b/src/product.py @@ -427,7 +427,9 @@ def check_installation(product_info): the product :return: True if it is well installed :rtype: boolean - ''' + ''' + if not product_compiles(product_info): + return True install_dir = product_info.install_dir if not os.path.exists(install_dir): return False @@ -579,6 +581,19 @@ def product_is_cpp(product_info): "cpp" in product_info.properties and product_info.properties.cpp == "yes") +def product_compiles(product_info): + '''Know if a product compiles or not (some products do not have a + compilation procedure) + + :param product_info Config: The configuration specific to + the product + :return: True if the product compiles, else False + :rtype: boolean + ''' + return not("properties" in product_info and + "compilation" in product_info.properties and + product_info.properties.compilation == "no") + def product_has_script(product_info): '''Know if a product has a compilation script