--- /dev/null
+Here you find examples of use of YACSGEN for every type of component.
+
+In order to build and test the examples, you have to:
+- change the SALOME installation directory in exec.sh (SALOME_DIR)
+- run "build.sh"
+
+Every example contains a "build.sh" script which shows you how to build and
+test it. In the main directory, it builds and tests all the examples.
#/bin/bash
+# clean all examples
+
script_dir=`dirname $0`
cd $script_dir
A C++ component dynamically loadable
=========================================
-To build this example, modify the ../context.py file
-to take into account your configuration.
-
-1- your prerequisite file
-2- your KERNEL_ROOT_DIR
-
-Then set the environment (including PYTHONPATH for YACSGEN, ../.. from here and execute components.py ::
-
- source <your prerequisite file>
- python components.py
+To build this example, modify the ../exec.sh file to take into account your configuration.
+Run build.sh to build and test the component.
You should get a SALOME module in source form (cppcompos_SRC), its installation (install) and
a SALOME application (appli) composed of modules KERNEL, GUI, YACS and the new module cppcompos.
A C++ standalone component (executable form)
=================================================
-To build this example, modify the ../context.py file
-to take into account your configuration.
-
-1- your prerequisite file
-2- your KERNEL_ROOT_DIR
-
-Then set the environment (including PYTHONPATH for YACSGEN, ../.. from here and execute components.py ::
-
- source <your prerequisite file>
- python components.py
+To build this example, modify the ../exec.sh file to take into account your configuration.
+Run build.sh to build and test the component.
You should get a SALOME module in source form (cppcompos_SRC), its installation (install) and
a SALOME application (appli) composed of modules KERNEL, GUI, YACS and the new module cppcompos.
-
-To build the standalone component (executable named prog), execute the Makefile in the SALOME application environment::
-
- ./appli/runSession make
+You also get the standalone component (executable named prog).
To run a coupling:
A Fortran component dynamically loadable
=============================================
-To build this example, modify the ../context.py, ../makefile.inc and Makefile files
-to take into account your configuration.
-
-1- your prerequisite file
-2- your KERNEL_ROOT_DIR
-3- your FORTRAN compiler
-
-Then set the environment (including PYTHONPATH for YACSGEN, ../.. from here)::
-
- source <your prerequisite file>
-
-Build the code1 et code2 libraries ::
-
- make
-
-and process components.py ::
-
- python components.py
+To build this example, modify the ../exec.sh file to take into account your configuration.
+Run build.sh to build and test the component.
You should get a SALOME module in source form (fcompos_SRC), its installation (install) and
a SALOME application (appli) composed of modules KERNEL, GUI, YACS and the new module fcompos.
A Fortran standalone component
=================================
-To build this example, modify the ../context.py, ../makefile.inc and Makefile files
-to take into account your configuration.
-
-1- your prerequisite file
-2- your KERNEL_ROOT_DIR
-3- your FORTRAN compiler
-
-Then set the environment (including PYTHONPATH for YACSGEN, ../.. from here)::
-
- source <your prerequisite file>
-
-and process components.py ::
-
- python components.py
+To build this example, modify the ../exec.sh file to take into account your configuration.
+Run build.sh to build and test the component.
You should get a SALOME module in source form (fcompos_SRC), its installation (install) and
a SALOME application (appli) composed of modules KERNEL, GUI, YACS and the new module fcompos.
-
-Build the code1 et code2 executables under the SALOME application environment::
-
- ./appli/runSession make
+You also get the code1 et code2 executables.
To run a coupling:
A Python component dynamically loadable
===============================================
-To build this example, modify the ../context.py file
-to take into account your configuration.
-
-1- your prerequisite file
-2- your KERNEL_ROOT_DIR
-
-Then set the environment (including PYTHONPATH for YACSGEN, ../.. from here and execute components.py ::
-
- source <your prerequisite file>
- python components.py
+To build this example, modify the ../exec.sh file to take into account your configuration.
+Run build.sh to build the component.
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 the new module pycompos.
A Python component dynamically loadable
===============================================
-To build this example, modify the ../context.py file
-to take into account your configuration.
-
-1- your prerequisite file
-2- your KERNEL_ROOT_DIR
-
-Then set the environment (including PYTHONPATH for YACSGEN, ../.. from here and execute components.py ::
-
- source <your prerequisite file>
- python components.py
+To build this example, modify the ../exec.sh file to take into account your configuration.
+Run build.sh to build and test the component.
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 the new module pycompos.
A Python standalone component (in executable form)
=======================================================
-To build this example, modify the ../context.py file
-to take into account your configuration.
-
-1- your prerequisite file
-2- your KERNEL_ROOT_DIR
-
-Then set the environment (including PYTHONPATH for YACSGEN, ../.. from here and execute components.py ::
-
- source <your prerequisite file>
- python components.py
+To build this example, modify the ../exec.sh file to take into account your configuration.
+Run build.sh to build and test the component.
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 the new module pycompos.
#! /usr/bin/env python
# -*- coding: utf-8 -*-
+# This test executes the coupling.xml schema found in the current directory
+# and verifies the execution state.
import unittest
import os
A test for several YACS types SALOME_TYPES and others
=========================================================
-To build this example, modify the ../context.py file
-to take into account your configuration.
-
-1- your prerequisite file
-2- your KERNEL_ROOT_DIR
-
-Then set the environment (including PYTHONPATH for YACSGEN, ../.. from here and execute components.py ::
-
- source <your prerequisite file>
- python components.py
+To build this example, modify the ../exec.sh file to take into account your configuration.
+Run build.sh to build and test the component.
You should get a SALOME module in source form (module_SRC), its installation (install) and
a SALOME application (appli) composed of modules KERNEL, GUI, YACS and the new module module.