]> SALOME platform Git repositories - tools/sat.git/commitdiff
Salome HOME
bug fix in generate command
authorS. Pomarede <support-salome@cea.fr>
Tue, 4 Oct 2016 12:59:26 +0000 (14:59 +0200)
committerS. Pomarede <support-salome@cea.fr>
Tue, 4 Oct 2016 12:59:26 +0000 (14:59 +0200)
commands/generate.py
src/environment.py

index d0e3cf4668af7d54cf00e73b41f31c665b707c4d..b7d53f8a083572e1a04fa71b95fea15dc47dc210 100644 (file)
@@ -79,7 +79,7 @@ def generate_component(config, compo, product_info, context, header, logger):
     builder.header = header
 
     # generate the component
-    # create GENERETE dir if necessary
+    # create GENERATE dir if necessary
     if not os.path.exists(generate_dir):
         os.mkdir(generate_dir)
 
index a8152b0a7a658ffa9ba871597f643d3bc245146f..2d2a83588f0c00fd62064c20c3515f16ed8e55b4 100644 (file)
@@ -539,6 +539,9 @@ class SalomeEnviron:
                 if "component_name" in pi:
                     # hack the source and install directories in order to point  
                     # on the generated product source install directories
+                    install_dir_save = pi.install_dir
+                    source_dir_save = pi.source_dir
+                    name_save = pi.name
                     pi.install_dir = os.path.join(self.cfg.APPLICATION.workdir,
                                                   "INSTALL",
                                                   pi.component_name)
@@ -549,6 +552,10 @@ class SalomeEnviron:
                     self.set_salome_minimal_product_env(pi, logger)
                     self.set_salome_generic_product_env(pi)
                     
+                    # Put original values
+                    pi.install_dir = install_dir_save
+                    pi.source_dir = source_dir_save
+                    pi.name = name_save
         
         # Put the environment define in the configuration of the product
         if "environ" in pi: