Salome HOME
sat launcher: Put a relative link instead of an absolute link in the
[tools/sat.git] / commands / makeinstall.py
index 74ab9476afa5e1171d0a391503e6d7c651074818..2e8e8fd7b26b0a3e5653e9e3c6cbe3b5fb6619c6 100644 (file)
@@ -20,11 +20,11 @@ import os
 
 import src
 
-# Define all possible option for the makeinstall command :  sat makeinstall <options>
+# Define all possible option for the makeinstall command : sat makeinstall <options>
 parser = src.options.Options()
 parser.add_option('p', 'products', 'list2', 'products',
-    _('products to configure. This option can be'
-    ' passed several time to configure several products.'))
+    _('Optional: products to install. This option can be'
+    ' passed several time to install several products.'))
 
 def get_products_list(options, cfg, logger):
     '''method that gives the product list with their informations from 
@@ -108,12 +108,19 @@ def makeinstall_product(p_name_info, config, logger):
     # Logging
     logger.write("\n", 4, False)
     logger.write("################ ", 4)
-    header = _("Make of %s") % src.printcolors.printcLabel(p_name)
+    header = _("Make install of %s") % src.printcolors.printcLabel(p_name)
     header += " %s " % ("." * (20 - len(p_name)))
     logger.write(header, 3)
     logger.write("\n", 4, False)
     logger.flush()
-    
+
+    # Do nothing if he product is not compilable
+    if ("properties" in p_info and "compilation" in p_info.properties and 
+                                        p_info.properties.compilation == "no"):
+        log_step(logger, header, "ignored")
+        logger.write("\n", 3, False)
+        return 0
+
     # Instantiate the class that manages all the construction commands
     # like cmake, make, make install, make test, environment management, etc...
     builder = src.compilation.Builder(config, logger, p_info)
@@ -157,7 +164,10 @@ def description():
     :rtype: str
     '''
     return _("The makeinstall command executes the \"make install\" command in"
-             " the build directory")
+             " the build directory.\nIn case of  product that is constructed "
+             "using a script (build_source :  \"script\"), then the "
+             "makeinstall command do nothing.\n\nexample:\nsat makeinstall "
+             "SALOME-master --products KERNEL,GUI")
   
 def run(args, runner, logger):
     '''method that is called when salomeTools is called with makeinstall parameter.