]> SALOME platform Git repositories - tools/eficas.git/commitdiff
Salome HOME
ajout des fichiers necessaires pour la construction de la distrib Aster
authoreficas <>
Tue, 26 Mar 2002 12:12:43 +0000 (12:12 +0000)
committereficas <>
Tue, 26 Mar 2002 12:12:43 +0000 (12:12 +0000)
Aster/INSTALL [new file with mode: 0644]
Aster/LICENSE.TERMS [new file with mode: 0644]
Aster/README [new file with mode: 0644]
Aster/sdist.py [new file with mode: 0644]

diff --git a/Aster/INSTALL b/Aster/INSTALL
new file mode 100644 (file)
index 0000000..044599c
--- /dev/null
@@ -0,0 +1,33 @@
+
+
+1- Installation standard
+
+Pour installer EFICAS a partir de la distribution : Eficas.tgz
+faire :
+       tar xzvf Eficas.tgz
+
+ce qui a pour effet de créer un répertoire Eficas
+Tel que Eficas est prêt à etre executé.
+
+ATTENTION : 
+Si Eficas est installé dans un répertoire particulier d'administration 
+dans lequel les utilisateurs n'ont pas le droit d'écriture, il faut que
+l'administrateur lance Eficas avec les deux versions 5 et 6 pour générer
+les fichiers et catalogues compilés .pyc et _pickled.py
+
+2- Utilisation d'Eficas
+
+Pour utiliser Eficas, aller dans le répertoire Aster et faire :
+       python eficas_aster.py
+
+3- Installation avec un noyau pré-installé
+
+Aller dans le répertoire Aster du répertoire Eficas
+et modifier le fichier prefs.py comme suit :
+Mettre dans la variable CODE_PATH le chemin absolu vers
+le répertoire contenant les deux répertoires Noyau et Validation que vous voulez
+utiliser à la place de ceux fournis dans la livraison d'Eficas
+
+Pour changer les catalogues, modifier le fichier editeur.ini dans le répertoire Aster
+
+
diff --git a/Aster/LICENSE.TERMS b/Aster/LICENSE.TERMS
new file mode 100644 (file)
index 0000000..8c88a1e
--- /dev/null
@@ -0,0 +1,21 @@
+ ======================================================================
+ THIS PROGRAM IS FREE SOFTWARE. YOU CAN REDISTRIBUTE IT AND/OR MODIFY  
+ IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY  
+ THE FREE SOFTWARE FOUNDATION, EITHER VERSION 2 OF THE LICENSE, AND 
+ ANY LATER VERSION.                   
+ THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT   
+ WITHOUT ANY WARRANTY, WITHOUT EVEN THE IMPLIED WARRANTY OF          
+ MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.             
+ SEE THE GNU GENERAL PUBLIC LICENSE FOR MORE DETAILS.             
+ ======================================================================
+          TRADUCTION EDF ( POUR INFORMATION )         
+ ======================================================================
+ CE PROGRAMME EST UN LOGICIEL LIBRE. VOUS POUVEZ LE DIFFUSER ET/OU LE  
+ MODIFIER SELON LES DISPOSITIONS DE LA LICENCE GRAND PUBLIC GNU (GPL)  
+ TELLE QU'ELLE EST PUBLIEE PAR LA FREE SOFTWARE FOUNDATION, VERSION 2  
+ DE LA LICENCE ET TOUTE VERSION ULTERIEURE.          
+ CE PROGRAMME EST DIFFUSE AVEC L'ESPOIR QU'IL SERA UTILE, MAIS SANS    
+ GARANTIE, SANS MEME LA GARANTIE IMPLICITE DE QUALIFICATION DE MISE SUR
+ LE MARCHE OU D'ADAPTATION A UNE UTILISATION PARTICULIERE.        
+ VOIR POUR DE PLUS AMPLES DETAILS LA LICENCE GRAND PUBLIC GNU (GPL)    
+ ======================================================================
diff --git a/Aster/README b/Aster/README
new file mode 100644 (file)
index 0000000..0597ecb
--- /dev/null
@@ -0,0 +1,2 @@
+
+Pour installer EFICAS voir dans le fichier INSTALL
diff --git a/Aster/sdist.py b/Aster/sdist.py
new file mode 100644 (file)
index 0000000..c992f40
--- /dev/null
@@ -0,0 +1,115 @@
+"""
+     Ce module sert à construire les distributions d'EFICAS en fonction
+     du tag CVS courant
+     Les distributions sont :
+      - un tar.gz pour UNIX ne contenant pas mxTextTools
+      - un zip pour Windows contenant mx TextTools préinstallé
+     L'utilisation de ce module est la suivante :
+      1- Se mettre dans un répertoire de travail
+      2- Configurer son environnement pour utiliser le référentiel CVS EFICAS
+      3- Exporter les sources d'EficasV1 par la commande :
+            cvs export -r TAG -d Eficas_export EficasV1
+         ou TAG est le tag CVS de la version que l'on veut distribuer (par exemple V1_1p1)
+      4- Copier le répertoire fourni par Aster (ACCAS6.2.0) au meme niveau que Eficas_export
+      5- Aller dans le répertoire Eficas_export
+      6- Executer le script sdist.py
+             python sdist.py
+         Ce qui a pour effet de creer un repertoire dist contenant les 2 distributions
+         et de les copier dans le répertoire indiqué par dir_download s'il est accessible
+
+"""
+import os,shutil,glob,sys
+import types
+
+version="$Name:  $"[7:-2] or 'Test'
+
+path_Noyau="../../../Tutorial/Superv"
+nom_distrib="Eficas"+version+"AsterSTA6"
+path_distrib=os.path.join("dist",nom_distrib)
+path_TextTools="/home/eficas/pkg/mxTools/egenix2.0.2pourWindows/mx/TextTools"
+dir_download= "/home/eficas/WWW/telechargement/eficas"
+
+def main():
+   if os.path.isdir('dist'):shutil.rmtree('dist')
+
+   copyfiles('.',path_distrib,['README','LICENSE.TERMS','INSTALL'])
+
+   copyfiles('../Editeur',os.path.join(path_distrib,'Editeur'),['*.py','faqs.txt'])
+   copyfiles('../Ihm',os.path.join(path_distrib,'Ihm'),['*.py'])
+   copyfiles('../Extensions',os.path.join(path_distrib,'Extensions'),['*.py'])
+   copyfiles('../Accas',os.path.join(path_distrib,'Accas'),['*.py'])
+   copyfiles('../Aster',os.path.join(path_distrib,'Aster'),['prefs.py',
+                                                            'editeur.ini',
+                                                            'eficas_aster.py',
+                                                           ])
+   copyfiles('../convert',os.path.join(path_distrib,'convert'),['*.py'])
+   copyfiles('../convert/Parserv5',os.path.join(path_distrib,'convert','Parserv5'),['*.py'])
+
+   copyfiles('../generator',os.path.join(path_distrib,'generator'),['*.py'])
+
+   copyfiles('../Editeur/icons',os.path.join(path_distrib,'Editeur','icons'),['*.gif'])
+
+   copyfiles(os.path.join(path_Noyau,'Noyau'),os.path.join(path_distrib,'Noyau'),['*.py'])
+   copyfiles(os.path.join(path_Noyau,'Validation'),os.path.join(path_distrib,'Validation'),['*.py'])
+   copyfiles(os.path.join(path_Noyau,'Cata'),os.path.join(path_distrib,'Aster','Cata'),['*.py',
+                                                                                       ])
+
+   copyfiles('../Tools',os.path.join(path_distrib,'Tools'),['*.py'])
+   copyfiles('../Tools/foztools',os.path.join(path_distrib,'Tools','foztools'),['*.py'])
+
+   tarball= maketarball('dist',nom_distrib,nom_distrib)
+   try:
+      shutil.copy(tarball,dir_download)
+   except:
+      print "Repertoire de download inconnu : ",dir_download
+
+   try:
+      shutil.copytree(path_TextTools,os.path.join(path_distrib,'Tools','TextTools'))
+   except:
+      print "Impossible de recuperer mxTextTools : ",dir_download
+      sys.exit(1)
+
+   zipfile= makezipfile('dist',nom_distrib,nom_distrib)
+   try:
+      shutil.copy(zipfile,dir_download)
+   except:
+      print "Repertoire de download inconnu : ",dir_download
+
+def make_dir(dir_cible):
+   if type(dir_cible) is not types.StringType:
+      raise "make_dir : dir_cible doit etre une string (%s)" % `dir_cible`
+   head,tail=os.path.split(dir_cible)
+   tails=[tail]
+   while head and tail and not os.path.isdir(head):
+      head,tail=os.path.split(head)
+      tails.insert(0, tail)
+
+   for d in tails:
+      head = os.path.join(head, d)
+      if not os.path.isdir(head):os.mkdir(head)
+
+
+def copyfiles(dir_origin,dir_cible,listfiles):
+   if not os.path.isdir(dir_cible):make_dir(dir_cible)
+   for glob_files in listfiles:
+      for file in glob.glob(os.path.join(dir_origin,glob_files)):
+         shutil.copy(file,dir_cible)
+
+def maketarball(dir_trav,dir_cible,nom_tar):
+   prev=os.getcwd()
+   print prev
+   os.chdir(dir_trav)
+   os.system("tar -cf "+nom_tar+".tar "+dir_cible)
+   os.system("gzip -f9 "+nom_tar+".tar ")
+   os.chdir(prev)
+   return os.path.join(dir_trav,nom_tar+".tar.gz")
+
+def makezipfile(dir_trav,dir_cible,nom_tar):
+   prev=os.getcwd()
+   os.chdir(dir_trav)
+   os.system("zip -rq "+nom_tar+".zip "+dir_cible)
+   os.chdir(prev)
+   return os.path.join(dir_trav,nom_tar+".zip")
+
+main()
+