]> SALOME platform Git repositories - tools/yacsgen.git/commitdiff
Salome HOME
CCAR: update standalone ASTER component example with changes in version 5.1.3
authorcaremoli <caremoli>
Tue, 24 Nov 2009 09:01:01 +0000 (09:01 +0000)
committercaremoli <caremoli>
Tue, 24 Nov 2009 09:01:01 +0000 (09:01 +0000)
Examples/ast2/README.txt
Examples/ast2/components.py
Examples/ast2/coupling.xml
Examples/ast2/exeaster [new file with mode: 0755]
Examples/ast2/f.comm
Examples/ast2/fcompo/Makefile
Examples/ast2/myaster/Makefile
Examples/ast2/myaster/config.txt
Examples/ast2/myaster/make_exec

index d117e11bc24b0915b356ba788718c46bc0c4edcb..ae400959249b38bcc940390cabbc9b3aa7300a65 100644 (file)
@@ -17,7 +17,7 @@ process components.py ::
   python components.py
 
 You should get a SALOME module in source form (pycompos_SRC), its installation (install) and
-a SALOME application (appli) composed of modules KERNEL, GUI, YACS and pycompos.
+a SALOME application (appli) composed of modules KERNEL, GUI, YACS and astmod_SRC.
 
 Build the fcompo library ::
 
@@ -35,5 +35,5 @@ To run a coupling:
  2. start a SALOME session : ./appli/runSession
  3. start YACS coupler with coupling file : driver coupling.xml
  4. examine output files in /tmp
- 5. shutdown SALOME : shutdowSalome.py
+ 5. shutdown SALOME : shutdownSalome.py
  6. exit session : CTRL-D (or exit)
index 5f26dc77d83c8400aab5b0f3b4008b5ebdde9693..d9f8970d2f562666359b5f0490d3f5806d6da9ae 100644 (file)
@@ -4,22 +4,24 @@
 import os
 from module_generator import Generator,Module,ASTERComponent,Service,F77Component
 
-context={'update':1,"prerequisites":"/local/cchris/.packages.d/envSalome50",
-          "kernel":"/local/chris/SALOME2/RELEASES/Install/KERNEL_V5"}
-aster_home="/local/chris/ASTER/instals"
-aster_root=os.path.join(aster_home,"NEW9")
-asrun=os.path.join(aster_home,"ASTK/ASTK_SERV/bin/as_run")
+context={'update':1,
+         "prerequisites":"/local/cchris/.packages.d/envSalome5",
+         "kernel":"/local/cchris/Salome/Install/KERNEL_V5"
+        }
+
+aster_home="/local/cchris/Aster/V10/Install"
+aster_version="STA10.0"
+
+aster_root=os.path.join(aster_home,aster_version)
 
 fcompodir=os.path.join(os.getcwd(),"fcompo")
 myasterdir=os.path.join(os.getcwd(),"myaster","bibpyt")
+
 install_prefix="./install"
 appli_dir="appli"
-export="""F exec %s D 0
-R cmde %s D 0
-""" % (os.path.join(os.getcwd(),"myaster","aster.exe"),os.path.join(os.getcwd(),"myaster","commande"))
 
 c1=ASTERComponent("caster",services=[
-          Service("s1",inport=[("argv","string"),("a","double"),("b","long"),("c","string")],
+          Service("s1",inport=[("jdc","file"),("a","double"),("b","long"),("c","string")],
                        outport=[("d","double")],
                        instream=[("aa","CALCIUM_double","T"),("ab","CALCIUM_double","I"),
                                  ("ac","CALCIUM_integer","I"),("ad","CALCIUM_real","I"),
@@ -30,12 +32,10 @@ c1=ASTERComponent("caster",services=[
                  ),
          ],
          aster_dir=aster_root,
-         exe_path=os.path.join(os.getcwd(),"exeaster"),
-         asrun=asrun,
          kind="exe",
-         export_extras=export,
+         exe_path=os.path.join(os.getcwd(),"exeaster"),
          )
-          
+
 c2=F77Component("cfort",services=[
           Service("s1",inport=[("a","double"),("b","long"),("c","string")],
                        outport=[("d","double"),("e","long"),("f","string")],
index 95d944c00196949a66494297c1f258a9898ce2bd..3625fc7800a90f274976ad8898bd45aa5bf696b9 100644 (file)
@@ -16,8 +16,7 @@
   <component>caster</component>
   <method>s1</method>
   <load container="A"/>
-  <inport name="jdc" type="string"/>
-  <inport name="argv" type="string"/>
+  <inport name="jdc" type="file"/>
   <inport name="a" type="double"/>
   <inport name="b" type="int"/>
   <inport name="c" type="string"/>
   <inport name="p1" type="double"/>
 </inline>
 
-<inline name="ljdc" >
-  <script>
-    <code>f=open(comm)</code>
-    <code>jdc=f.read()</code>
-    <code>f.close()</code>
-  </script>
-  <inport name="comm" type="string"/>
-  <outport name="jdc" type="string"/>
-</inline>
-
 <outnode name="dataout" >
   <parameter name="f1" type="file" ref="monfichier"/>
 </outnode>
    <fromnode>datain</fromnode><fromport>f1</fromport>
    <tonode>node2</tonode> <toport>a</toport>
 </datalink>
-<datalink>
-   <fromnode>ljdc</fromnode><fromport>jdc</fromport>
-   <tonode>node1</tonode> <toport>jdc</toport>
-</datalink>
 
 <parameter>
   <tonode>node1</tonode> <toport>a</toport>
 </parameter>
 
 <parameter>
-  <tonode>ljdc</tonode> <toport>comm</toport>
-  <value><string>f.comm</string> </value>
-</parameter>
-
-<parameter>
-  <tonode>node1</tonode> <toport>argv</toport>
-  <value><string>-memjeveux 4 </string> </value>
+  <tonode>node1</tonode> <toport>jdc</toport>
+  <value><objref>f.comm</objref></value>
 </parameter>
 
 </proc>
diff --git a/Examples/ast2/exeaster b/Examples/ast2/exeaster
new file mode 100755 (executable)
index 0000000..1d35279
--- /dev/null
@@ -0,0 +1,32 @@
+
+cat > temp.comm << END
+END
+
+cat > temp.export << END
+P actions make_etude
+P version STA10.0
+P nomjob salome
+P ncpus 1
+A memjeveux 4.000000
+P mem_aster 100
+A tpmax 60
+P memjob 32768
+P mpi_nbcpu 1
+P mpi_nbnoeud 1
+P tpsjob 1
+
+P mode batch
+
+P soumbtc oui
+P consbtc oui
+F conf /local/cchris/Salome/YACSGEN/V5/YACSGEN/Examples/ast2/install/share/salome/resources/astmod/caster_config.txt D 0
+F comm $PWD/temp.comm D 1
+F exec /local/cchris/Salome/YACSGEN/V5/YACSGEN/Examples/ast2/myaster/aster.exe D 0
+R cmde /local/cchris/Salome/YACSGEN/V5/YACSGEN/Examples/ast2/myaster/commande D 0
+F mess $PWD/messages R 6
+F resu $PWD/resu R 8
+F erre $PWD/erre R 9
+END
+
+/local/cchris/Aster/V10/Install/ASTK/ASTK_SERV/bin/as_run temp.export
+
index 0a8524d13d29291395bdf21c4d97ff7ef14582ed..f8a7a55b284475da62cf759a0ddc558125b26c65 100644 (file)
@@ -1,3 +1,4 @@
+DEBUT(PAR_LOT="NON")
 print a,b,c
 YACS_INIT(COMPO=component)
 
@@ -6,3 +7,4 @@ LECTURE_FORCE()
 
 d=36.5
 
+FIN()
index fb7aa91ffe1052e2cd302f92b242dcf239e60e5c..bcf2bbab855cca8931b303b373f45f85f542113a 100644 (file)
@@ -1,7 +1,7 @@
 
-FC=g77
+FC=gfortran
 
-KERNEL_ROOT_DIR=/local/chris/SALOME2/RELEASES/Install/KERNEL_V5
+KERNEL_ROOT_DIR=/local/cchris/Salome/Install/KERNEL_V5
 
 all:prog
 prog:compo.o
index 7a7ea2c2ed77c45db82c7f2c684607beb1827235..e693a084a34c9d0b7b6b3b21ce6635e24aa049f3 100644 (file)
@@ -1,7 +1,7 @@
 
 #ASTER
-ASTER_ROOT=/local/chris/ASTER/instals
+ASTER_ROOT=/local/cchris/Aster/V10/Install
 
 aster.exe:
-       ./make_exec $(ASTER_ROOT)/ASTK/ASTK_SERV/bin/as_run
+       ./make_exec 
 
index b7cbc4f3be92e262064a08e147cea27482d36625..d1724771c90d89fef551dfbb496c89f036fc925c 100644 (file)
@@ -12,6 +12,8 @@
 #  LINK       : linker command
 #  OPTL       : linker options
 #  CC         : C compiler command
+#  DEFS       : pre-processor #define commands separated by space or comma
+#               they will be added to all compilation options OPTx_x
 #  OPTC_D     : C compiler options using DEBUG mode
 #  OPTC_O     : C compiler options using NODEBUG mode
 #  INCL       : C include flags
 #  REPOUT     : tools directory
 #  MAKE_SURCH_OFFI/MAKE_CAPY_OFFI : Python modules to compiling elements catalogs
 #  CRP / CRS  : tools to check source files and programming rules
+#  ID_PERF    : a label to identify a group of machines (use by TEST_TEMPS command)
 #
-ENV_SH         | env     | -     | /local/chris/ASTER/instals/NEW9/profile.sh
+ID_PERF        | id      | -     | claui2c6
+#
+ENV_SH         | env     | -     | /local/cchris/Aster/V10/Install/STA10.0/profile.sh
 #
 LIB            | ar      | ?     | /usr/bin/ar -rv
 #
-#BIBL           | python  | 2.4   | -L/usr/lib/python2.4/config -lpython2.4
-BIBL           | python  | 2.4   | -lpython2.4
-BIBL           | med     | 2.3.5 | -Wl,-R -Wl,/local/chris/pkg/med235/install/lib -L/local/chris/pkg/med235/install/lib -lmed
+BIBL           | python  | 2.4   | -lpython2.5
+BIBL           | med     | 2.3.5 | -Wl,-R -Wl,/local/cchris/pkg/med235/install/lib -L/local/cchris/pkg/med235/install/lib -lmed
 BIBL           | hdf5    | 1.6.5 | -lhdf5
-BIBL           | sys     | ?     | -Wl,--allow-multiple-definition -Wl,--export-dynamic -lieee -ldl -lpthread -lutil -lm /usr/lib/libz.a
-BIBL           | mpi     | 2     | -lmpi
-BIBL           | zmat    | 8.3   | 
-BIBL           | mumps   | 4.3.2 | 
-BIBL           | scotch  | 4.0   | -L/local/chris/ASTER/instals/public/scotch_4.0/bin -lscotch -lcommon -lscotcherr -lscotcherrcom
-BIBL           | math    | ?     | /usr/lib/liblapack.a /usr/lib/libblas.a /usr/lib/libg2c.a
-BIBL           | salome  | ?     | -L/local/chris/SALOME2/RELEASES/Install/KERNEL_V5/lib/salome -lCalciumC -lSalomeDSCSuperv -lSalomeDSCContainer -lSalomeDatastream -lSalomeDSCSupervBasic -Wl,--rpath -Wl,/local/chris/SALOME2/RELEASES/Install/KERNEL_V5/lib/salome
+BIBL           | zmat    | 8.4   | 
+BIBL           | mumps   | ?     | /local/cchris/Aster/V10/Install/public/mumps-4.7.3/lib/libdmumps.a /local/cchris/Aster/V10/Install/public/mumps-4.7.3/lib/libzmumps.a /local/cchris/Aster/V10/Install/public/mumps-4.7.3/lib/libpord.a /local/cchris/Aster/V10/Install/public/mumps-4.7.3/libseq/libmpiseq.a
+BIBL           | scotch  | 4.0   | 
+BIBL           | math    | ?     | /usr/lib/liblapack.a /usr/lib/libblas.a /usr/lib/gcc/x86_64-linux-gnu/4.3/libgfortran.a /usr/lib/gcc/x86_64-linux-gnu/4.3/libgfortran.a
+BIBL           | mpi     | 2     | 
+BIBL           | c++     | ?     | -L/usr/lib/gcc/x86_64-linux-gnu/4.3 -lstdc++ -lsupc++
+BIBL           | sys     | ?     | -Wl,--allow-multiple-definition -Wl,--export-dynamic -lieee -ldl -lpthread -lutil -lm -lz
+BIBL           | salome  | ?     | -L/local/cchris/Salome/Install/KERNEL_V5/lib/salome -lCalciumC -lSalomeDSCSuperv -lSalomeDSCContainer -lSalomeDatastream -lSalomeDSCSupervBasic -Wl,--rpath -Wl,/local/cchris/Salome/Install/KERNEL_V5/lib/salome
+#
+DEFS           | defined | ?     | LINUX64 _HAVE_MUMPS
 #
-NOBUILD        | option  | ?     |  bibfor/from_c
+NOBUILD        | option  | ?     |  bibfor/from_c bibc/scotch
 #
 PYTHON         | python  | 2.4   | /usr/bin/python
 #
-LINK           | link    | ?     | /usr/bin/g77
-OPTL           | link    | ?     | -v
+LINK           | link    | ?     | /usr/bin/gfortran
+OPTL           | link    | ?     |  -fopenmp
 #
 CC             | cc      | ?     | /usr/bin/gcc
-#OPTC_D         | cc      | ?     | -c -g -DP_LINUX  -D_USE_MPI
-OPTC_D         | cc      | ?     | -c -g -DP_LINUX 
-#OPTC_O         | cc      | ?     | -c -O2 -DP_LINUX -D_USE_MPI
-OPTC_O         | cc      | ?     | -c -O2 -DP_LINUX 
-INCL           | include | ?     | -I/local/chris/ASTER/instals/NEW9/bibc/include -I/usr/include/python2.4 -I/usr/include -I/usr/include/lam -I/local/chris/ASTER/instals/public/scotch_4.0/bin
-#
-F77            | f77     | ?     | /usr/bin/g77
-OPTF_D         | f77     | ?     | -c -g
-OPTF_O         | f77     | ?     | -c -O2 -I/usr/include/lam
-INCLF          | include | ?     | -I/local/chris/SALOME2/RELEASES/Install/KERNEL_V5/include/salome
-#
-F90            | f90     | ?     | 
-OPTF90_D       | f90     | ?     | -c -g
-OPTF90_O       | f90     | ?     | -c -O2
-INCLF90        | include | ?     | 
+OPTC_D         | cc      | ?     | -c -g  -fno-stack-protector
+OPTC_O         | cc      | ?     | -c -O2 -fno-stack-protector
+INCL           | include | ?     | -I/local/cchris/Aster/V10/Install/STA10.0/bibc/include -I/usr/include/python2.5 -I/local/cchris/Aster/V10/Install/public/hdf5-1.6.5/include
+#
+F77            | f77     | ?     | /usr/bin/gfortran
+OPTF_D         | f77     | ?     | -c -g  -fopenmp  -fdefault-double-8 -fdefault-integer-8 -fdefault-real-8
+OPTF_O         | f77     | ?     | -c -O2 -fopenmp  -fdefault-double-8 -fdefault-integer-8 -fdefault-real-8
+INCLF          | include | ?     | -I/local/cchris/Salome/Install/KERNEL_V5/include/salome
+#
+F90            | f90     | ?     | /usr/bin/gfortran
+OPTF90_D       | f90     | ?     | -c -g  -ffixed-line-length-0 -x f77-cpp-input  -fdefault-double-8 -fdefault-integer-8 -fdefault-real-8
+OPTF90_O       | f90     | ?     | -c -O2 -ffixed-line-length-0 -x f77-cpp-input  -fdefault-double-8 -fdefault-integer-8 -fdefault-real-8
+INCLF90        | include | ?     |  -I/local/cchris/Aster/V10/Install/STA10.0/bibf90/include_mumps-4.7.3
 #
 G77_AGLA       | g77     | ?     | unused
 #
 SRCFOR         | src     | 11-04 | bibfor
-#SRCF90         | src     | 11-04 | bibf90
+#Comment following line if you have no f90 compiler
+SRCF90         | src     | 11-04 | bibf90
 SRCFERM        | src     | 11-04 | fermetur
 SRCC           | src     | 11-04 | bibc
 SRCPY          | src     | 11-04 | bibpyt
@@ -107,22 +113,26 @@ ARGEXE         | exec    | 03-02 | -eficas_path ./Python
 MAKE_SURCH_OFFI | build  | 11-04 | Lecture_Cata_Ele/make_surch_offi.py
 MAKE_CAPY_OFFI  | build  | 11-04 | Lecture_Cata_Ele/make_capy_offi.py
 #
-REPOUT         | exec    | 11-04 | /local/chris/ASTER/instals/outils
-REPMAT         | exec    | 02-05 | /local/chris/ASTER/instals/NEW9/materiau
-REPDEX         | exec    | 02-05 | /local/chris/ASTER/instals/NEW9/datg
+REPOUT         | exec    | 11-04 | /local/cchris/Aster/V10/Install/outils
+REPMAT         | exec    | 02-05 | /local/cchris/Aster/V10/Install/STA10.0/materiau
+REPDEX         | exec    | 02-05 | /local/cchris/Aster/V10/Install/STA10.0/datg
 #
 SUPERV         | exec    | 03-02 | Accas
 SUPERV         | exec    | 03-02 | Build
+SUPERV         | exec    | 03-02 | Comportement
 SUPERV         | exec    | 03-02 | Execution
+SUPERV         | exec    | 03-02 | Intranet
 SUPERV         | exec    | 03-02 | Macro
-SUPERV         | exec    | 03-02 | Messages
+SUPERV         | exec    | 12-06 | Meidee
+SUPERV         | exec    | 09-06 | Messages
 SUPERV         | exec    | 03-02 | Noyau
-SUPERV         | exec    | 03-02 | Stanley
+SUPERV         | exec    | 05-04 | Outils
+SUPERV         | exec    | 01-07 | SD
+SUPERV         | exec    | 01-03 | Stanley
 SUPERV         | exec    | 03-02 | Utilitai
 SUPERV         | exec    | 03-02 | Validation
 #
 GZIP           | tool    | ?     | ?GZIP?
-CRP            | tool    | ?     | /local/chris/ASTER/instals/outils/CRPCRS/crp_aster.sh
-CRS            | tool    | ?     | /local/chris/ASTER/instals/outils/CRPCRS/crs.sh
 #
 I18N           | i18n    | -     | 
+
index 351c97a777641c1020863dc59486b2208c0221e1..ae00fde753361e0592b460885fc49b9fec856ca2 100755 (executable)
@@ -1,8 +1,9 @@
 #!/bin/sh
+
 cat >make-exe << END
 P actions make_exec
 P actions make_cmde
-P version NEW9
+P version STA10.0
 P nomjob forma01a
 P ncpus 1
 A memjeveux 4.000000
@@ -23,5 +24,4 @@ R capy ${PWD}/catalo D 0
 R cmde ${PWD}/commande DR 0
 END
 
-
-$1 make-exe
+/local/cchris/Aster/V10/Install/ASTK/ASTK_SERV/bin/as_run  make-exe