Xcos toolbox skeleton: add a no-op C and Scilab 42/13442/4
Clément DAVID [Wed, 15 Jan 2014 13:34:19 +0000 (14:34 +0100)]
This block has parametrized inputs, outputs, simulation function.

Change-Id: I5a9517dcda798aaaa4b00e5013a70edded9dcd94

22 files changed:
scilab/contrib/Makefile.am
scilab/contrib/Makefile.in
scilab/contrib/toolbox_skeleton.iss
scilab/contrib/xcos_toolbox_skeleton/DESCRIPTION
scilab/contrib/xcos_toolbox_skeleton/DESCRIPTION-FUNCTIONS
scilab/contrib/xcos_toolbox_skeleton/images/gif/TBX_NOOP.gif [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/images/svg/TBX_NOOP.svg [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/macros/TBX_NOOP.sci [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/macros/TBX_NOOP_sci.sci [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/macros/TBX_NOOP_sim.sci [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/macros/buildmacros.sce
scilab/contrib/xcos_toolbox_skeleton/src/c/builder_c.sce
scilab/contrib/xcos_toolbox_skeleton/src/c/tbx_block_noop.c [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices.zcos [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices_c.tst [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices_scilab.tst [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar.zcos [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar_c.tst [new file with mode: 0644]
scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar_scilab.tst [new file with mode: 0644]
scilab/modules/modules_manager/tests/unit_tests/xcos_toolbox_skeleton.macosx.dia.ref
scilab/modules/modules_manager/tests/unit_tests/xcos_toolbox_skeleton.unix.dia.ref
scilab/modules/modules_manager/tests/unit_tests/xcos_toolbox_skeleton.win.dia.ref

index a345191..c36b65f 100644 (file)
@@ -1,83 +1,85 @@
 # Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
 # Copyright (C) 2008 - DIGITEO - Sylvestre LEDRU
+# Copyright (C) 2014 - Scilab Enterprises - Clement DAVID
 #
 # This file is distributed under the same license as the Scilab package.
 
 # Install the contrib_skeleton directory (the template)
 
-SKELETON_FILES=toolbox_skeleton/src/fortran/builder_fortran.sce \
-toolbox_skeleton/src/fortran/fsum.f \
-toolbox_skeleton/src/c/csum.c \
-toolbox_skeleton/src/c/builder_c.sce \
-toolbox_skeleton/src/c/multiplybypi.c \
-toolbox_skeleton/src/c/csub.c \
-toolbox_skeleton/src/c/multiplybypi.h \
-toolbox_skeleton/src/c/csub.h \
-toolbox_skeleton/src/c/csum.h \
-toolbox_skeleton/src/java/org/scilab/contrib/toolboxskeleton/Sum.java \
-toolbox_skeleton/src/java/builder_java.sce \
-toolbox_skeleton/src/cleaner_src.sce \
-toolbox_skeleton/src/builder_src.sce \
-toolbox_skeleton/etc/toolbox_skeleton.quit \
-toolbox_skeleton/etc/toolbox_skeleton.start \
-toolbox_skeleton/etc/toolbox_skeleton_preferences.xml \
-toolbox_skeleton/etc/toolbox_skeleton_preferences.xsl \
-toolbox_skeleton/license.txt \
-toolbox_skeleton/DESCRIPTION \
+SKELETON_FILES=loader.sce \
+toolbox_skeleton/builder.sce \
 toolbox_skeleton/changelog.txt \
+toolbox_skeleton/demos/cpp_find.dem.sce \
+toolbox_skeleton/demos/c_sum.dem.sce \
+toolbox_skeleton/demos/fortran_sum.dem.sce \
+toolbox_skeleton/demos/scilab_sum.dem.sce \
+toolbox_skeleton/demos/toolbox_skeleton.dem.gateway.sce \
+toolbox_skeleton/DESCRIPTION \
 toolbox_skeleton/DESCRIPTION-FUNCTIONS \
+toolbox_skeleton/etc/toolbox_skeleton_preferences.xml \
+toolbox_skeleton/etc/toolbox_skeleton_preferences.xsl \
+toolbox_skeleton/etc/toolbox_skeleton.quit \
+toolbox_skeleton/etc/toolbox_skeleton.start \
 toolbox_skeleton/help/builder_help.sce \
-toolbox_skeleton/help/fr_FR/scilab_sum.xml \
-toolbox_skeleton/help/fr_FR/c_sub.xml \
-toolbox_skeleton/help/fr_FR/fortran_sum.xml \
-toolbox_skeleton/help/fr_FR/c_sum.xml \
-toolbox_skeleton/help/fr_FR/build_help.sce \
-toolbox_skeleton/help/en_US/scilab_sum.xml \
-toolbox_skeleton/help/en_US/c_sub.xml \
-toolbox_skeleton/help/en_US/fortran_sum.xml \
-toolbox_skeleton/help/en_US/c_sum.xml \
+toolbox_skeleton/help/cleaner_help.sce \
 toolbox_skeleton/help/en_US/build_help.sce \
 toolbox_skeleton/help/en_US/c_multiplybypi.xml \
-toolbox_skeleton/demos/c_sum.dem.sce \
-toolbox_skeleton/demos/toolbox_skeleton.dem.gateway.sce \
-toolbox_skeleton/demos/cpp_find.dem.sce \
-toolbox_skeleton/demos/scilab_sum.dem.sce \
-toolbox_skeleton/demos/fortran_sum.dem.sce \
+toolbox_skeleton/help/en_US/c_sub.xml \
+toolbox_skeleton/help/en_US/c_sum.xml \
+toolbox_skeleton/help/en_US/fortran_sum.xml \
+toolbox_skeleton/help/en_US/scilab_sum.xml \
+toolbox_skeleton/help/fr_FR/build_help.sce \
+toolbox_skeleton/help/fr_FR/c_multiplybypi.xml \
+toolbox_skeleton/help/fr_FR/c_sub.xml \
+toolbox_skeleton/help/fr_FR/c_sum.xml \
+toolbox_skeleton/help/fr_FR/fortran_sum.xml \
+toolbox_skeleton/help/fr_FR/scilab_sum.xml \
+toolbox_skeleton/license.txt \
+toolbox_skeleton/locales/en_US.po \
+toolbox_skeleton/locales/fr_FR.po \
+toolbox_skeleton/macros/buildmacros.sce \
+toolbox_skeleton/macros/cleanmacros.sce \
+toolbox_skeleton/macros/scilab_error.sci \
+toolbox_skeleton/macros/scilab_sum.sci \
 toolbox_skeleton/readme.txt \
+toolbox_skeleton/sci_gateway/builder_gateway.sce \
+toolbox_skeleton/sci_gateway/c/builder_gateway_c.sce \
+toolbox_skeleton/sci_gateway/cpp/builder_gateway_cpp.sce \
+toolbox_skeleton/sci_gateway/cpp/sci_cpp_find.cxx \
+toolbox_skeleton/sci_gateway/c/sci_cerror.c \
+toolbox_skeleton/sci_gateway/c/sci_csub.c \
+toolbox_skeleton/sci_gateway/c/sci_csum.c \
+toolbox_skeleton/sci_gateway/c/sci_foo.c \
+toolbox_skeleton/sci_gateway/c/sci_multiplybypi.c \
+toolbox_skeleton/sci_gateway/fortran/builder_gateway_fortran.sce \
+toolbox_skeleton/sci_gateway/fortran/sci_fsum.c \
+toolbox_skeleton/src/builder_src.sce \
+toolbox_skeleton/src/c/builder_c.sce \
+toolbox_skeleton/src/c/csub.c \
+toolbox_skeleton/src/c/csub.h \
+toolbox_skeleton/src/c/csum.c \
+toolbox_skeleton/src/c/csum.h \
+toolbox_skeleton/src/cleaner_src.sce \
+toolbox_skeleton/src/c/multiplybypi.c \
+toolbox_skeleton/src/c/multiplybypi.h \
+toolbox_skeleton/src/fortran/builder_fortran.sce \
+toolbox_skeleton/src/fortran/fsum.f \
+toolbox_skeleton/src/java/builder_java.sce \
+toolbox_skeleton/src/java/org/scilab/contrib/toolboxskeleton/Sum.java \
+toolbox_skeleton/tests/unit_tests/c_sum.dia.ref \
 toolbox_skeleton/tests/unit_tests/c_sum.tst \
+toolbox_skeleton/tests/unit_tests/fortran_sum.dia.ref \
 toolbox_skeleton/tests/unit_tests/fortran_sum.tst \
+toolbox_skeleton/tests/unit_tests/java_sum.dia.ref \
+toolbox_skeleton/tests/unit_tests/java_sum.tst \
 toolbox_skeleton/tests/unit_tests/scilab_sum.dia.ref \
-toolbox_skeleton/tests/unit_tests/fortran_sum.dia.ref \
-toolbox_skeleton/tests/unit_tests/c_sum.dia.ref \
 toolbox_skeleton/tests/unit_tests/scilab_sum.tst \
-toolbox_skeleton/tests/unit_tests/java_sum.tst \
-toolbox_skeleton/tests/unit_tests/java_sum.dia.ref \
-toolbox_skeleton/sci_gateway/fortran/builder_gateway_fortran.sce \
-toolbox_skeleton/sci_gateway/fortran/sci_fsum.c \
-toolbox_skeleton/sci_gateway/c/sci_csub.c \
-toolbox_skeleton/sci_gateway/c/sci_multiplybypi.c \
-toolbox_skeleton/sci_gateway/c/sci_foo.c \
-toolbox_skeleton/sci_gateway/c/sci_cerror.c \
-toolbox_skeleton/sci_gateway/c/sci_csum.c \
-toolbox_skeleton/sci_gateway/c/builder_gateway_c.sce \
-toolbox_skeleton/sci_gateway/cpp/builder_gateway_cpp.sce \
-toolbox_skeleton/sci_gateway/cpp/sci_cpp_find.cxx \
-toolbox_skeleton/sci_gateway/builder_gateway.sce \
-toolbox_skeleton/builder.sce \
-toolbox_skeleton/locales/en_US.po \
-toolbox_skeleton/locales/fr_FR.po \
-toolbox_skeleton/macros/scilab_sum.sci \
-toolbox_skeleton/macros/scilab_error.sci \
-toolbox_skeleton/macros/buildmacros.sce \
-toolbox_skeleton/macros/cleanmacros.sce \
 toolbox_skeleton/toolbox_skeleton_redist.iss \
-toolbox_skeleton/toolbox_skeleton.iss \
 xcos_toolbox_skeleton/builder.sce \
 xcos_toolbox_skeleton/changelog.txt \
-xcos_toolbox_skeleton/cleaner.sce \
+xcos_toolbox_skeleton/demos/allSum.dem.sce \
 xcos_toolbox_skeleton/demos/Blocks.zcos \
 xcos_toolbox_skeleton/demos/xcos_toolbox_skeleton.dem.gateway.sce \
-xcos_toolbox_skeleton/demos/allSum.dem.sce \
 xcos_toolbox_skeleton/DESCRIPTION \
 xcos_toolbox_skeleton/DESCRIPTION-FUNCTIONS \
 xcos_toolbox_skeleton/etc/xcos_toolbox_skeleton.quit \
@@ -91,15 +93,20 @@ xcos_toolbox_skeleton/help/en_US/TBX_SUM_c.xml \
 xcos_toolbox_skeleton/help/en_US/tbx_sum.xml \
 xcos_toolbox_skeleton/help/fr_FR/build_help.sce \
 xcos_toolbox_skeleton/images/gif/TBX_MUT_STYLE.gif \
+xcos_toolbox_skeleton/images/gif/TBX_NOOP.gif \
 xcos_toolbox_skeleton/images/gif/TBX_SUM_c.gif \
 xcos_toolbox_skeleton/images/gif/TBX_SUM_sci.gif \
 xcos_toolbox_skeleton/images/svg/TBX_MUT_STYLE.svg \
+xcos_toolbox_skeleton/images/svg/TBX_NOOP.svg \
 xcos_toolbox_skeleton/images/svg/TBX_SUM_c.svg \
 xcos_toolbox_skeleton/images/svg/TBX_SUM_sci.svg \
 xcos_toolbox_skeleton/license.txt \
 xcos_toolbox_skeleton/macros/buildmacros.sce \
 xcos_toolbox_skeleton/macros/cleanmacros.sce \
 xcos_toolbox_skeleton/macros/TBX_MUT_STYLE.sci \
+xcos_toolbox_skeleton/macros/TBX_NOOP.sci \
+xcos_toolbox_skeleton/macros/TBX_NOOP_sci.sci \
+xcos_toolbox_skeleton/macros/TBX_NOOP_sim.sci \
 xcos_toolbox_skeleton/macros/TBX_SUM_c.sci \
 xcos_toolbox_skeleton/macros/TBX_SUM_sci.sci \
 xcos_toolbox_skeleton/macros/TBX_SUM_sim.sci \
@@ -113,9 +120,15 @@ xcos_toolbox_skeleton/src/c/builder_c.sce \
 xcos_toolbox_skeleton/src/c/business.h \
 xcos_toolbox_skeleton/src/c/business_sum.c \
 xcos_toolbox_skeleton/src/cleaner_src.sce \
-xcos_toolbox_skeleton/tests/unit_tests/tbx_sum.tst \
+xcos_toolbox_skeleton/src/c/tbx_block_noop.c \
+xcos_toolbox_skeleton/tests/benchmark/noop_matrices_c.tst \
+xcos_toolbox_skeleton/tests/benchmark/noop_matrices_scilab.tst \
+xcos_toolbox_skeleton/tests/benchmark/noop_matrices.zcos \
+xcos_toolbox_skeleton/tests/benchmark/noop_scalar_c.tst \
+xcos_toolbox_skeleton/tests/benchmark/noop_scalar_scilab.tst \
+xcos_toolbox_skeleton/tests/benchmark/noop_scalar.zcos \
 xcos_toolbox_skeleton/tests/unit_tests/tbx_sum.dia.ref \
-loader.sce
+xcos_toolbox_skeleton/tests/unit_tests/tbx_sum.tst
 
 install-data-local:
        $(mkinstalldirs) -m 755 $(DESTDIR)$(pkgdatadir)/contrib/; \
index f417244..d4a6413 100644 (file)
@@ -16,6 +16,7 @@
 
 # Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
 # Copyright (C) 2008 - DIGITEO - Sylvestre LEDRU
+# Copyright (C) 2014 - Scilab Enterprises - Clement DAVID
 #
 # This file is distributed under the same license as the Scilab package.
 
@@ -401,79 +402,80 @@ target_alias = @target_alias@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
-SKELETON_FILES = toolbox_skeleton/src/fortran/builder_fortran.sce \
-toolbox_skeleton/src/fortran/fsum.f \
-toolbox_skeleton/src/c/csum.c \
-toolbox_skeleton/src/c/builder_c.sce \
-toolbox_skeleton/src/c/multiplybypi.c \
-toolbox_skeleton/src/c/csub.c \
-toolbox_skeleton/src/c/multiplybypi.h \
-toolbox_skeleton/src/c/csub.h \
-toolbox_skeleton/src/c/csum.h \
-toolbox_skeleton/src/java/org/scilab/contrib/toolboxskeleton/Sum.java \
-toolbox_skeleton/src/java/builder_java.sce \
-toolbox_skeleton/src/cleaner_src.sce \
-toolbox_skeleton/src/builder_src.sce \
-toolbox_skeleton/etc/toolbox_skeleton.quit \
-toolbox_skeleton/etc/toolbox_skeleton.start \
-toolbox_skeleton/etc/toolbox_skeleton_preferences.xml \
-toolbox_skeleton/etc/toolbox_skeleton_preferences.xsl \
-toolbox_skeleton/license.txt \
-toolbox_skeleton/DESCRIPTION \
+SKELETON_FILES = loader.sce \
+toolbox_skeleton/builder.sce \
 toolbox_skeleton/changelog.txt \
+toolbox_skeleton/demos/cpp_find.dem.sce \
+toolbox_skeleton/demos/c_sum.dem.sce \
+toolbox_skeleton/demos/fortran_sum.dem.sce \
+toolbox_skeleton/demos/scilab_sum.dem.sce \
+toolbox_skeleton/demos/toolbox_skeleton.dem.gateway.sce \
+toolbox_skeleton/DESCRIPTION \
 toolbox_skeleton/DESCRIPTION-FUNCTIONS \
+toolbox_skeleton/etc/toolbox_skeleton_preferences.xml \
+toolbox_skeleton/etc/toolbox_skeleton_preferences.xsl \
+toolbox_skeleton/etc/toolbox_skeleton.quit \
+toolbox_skeleton/etc/toolbox_skeleton.start \
 toolbox_skeleton/help/builder_help.sce \
-toolbox_skeleton/help/fr_FR/scilab_sum.xml \
-toolbox_skeleton/help/fr_FR/c_sub.xml \
-toolbox_skeleton/help/fr_FR/fortran_sum.xml \
-toolbox_skeleton/help/fr_FR/c_sum.xml \
-toolbox_skeleton/help/fr_FR/build_help.sce \
-toolbox_skeleton/help/en_US/scilab_sum.xml \
-toolbox_skeleton/help/en_US/c_sub.xml \
-toolbox_skeleton/help/en_US/fortran_sum.xml \
-toolbox_skeleton/help/en_US/c_sum.xml \
+toolbox_skeleton/help/cleaner_help.sce \
 toolbox_skeleton/help/en_US/build_help.sce \
 toolbox_skeleton/help/en_US/c_multiplybypi.xml \
-toolbox_skeleton/demos/c_sum.dem.sce \
-toolbox_skeleton/demos/toolbox_skeleton.dem.gateway.sce \
-toolbox_skeleton/demos/cpp_find.dem.sce \
-toolbox_skeleton/demos/scilab_sum.dem.sce \
-toolbox_skeleton/demos/fortran_sum.dem.sce \
+toolbox_skeleton/help/en_US/c_sub.xml \
+toolbox_skeleton/help/en_US/c_sum.xml \
+toolbox_skeleton/help/en_US/fortran_sum.xml \
+toolbox_skeleton/help/en_US/scilab_sum.xml \
+toolbox_skeleton/help/fr_FR/build_help.sce \
+toolbox_skeleton/help/fr_FR/c_multiplybypi.xml \
+toolbox_skeleton/help/fr_FR/c_sub.xml \
+toolbox_skeleton/help/fr_FR/c_sum.xml \
+toolbox_skeleton/help/fr_FR/fortran_sum.xml \
+toolbox_skeleton/help/fr_FR/scilab_sum.xml \
+toolbox_skeleton/license.txt \
+toolbox_skeleton/locales/en_US.po \
+toolbox_skeleton/locales/fr_FR.po \
+toolbox_skeleton/macros/buildmacros.sce \
+toolbox_skeleton/macros/cleanmacros.sce \
+toolbox_skeleton/macros/scilab_error.sci \
+toolbox_skeleton/macros/scilab_sum.sci \
 toolbox_skeleton/readme.txt \
+toolbox_skeleton/sci_gateway/builder_gateway.sce \
+toolbox_skeleton/sci_gateway/c/builder_gateway_c.sce \
+toolbox_skeleton/sci_gateway/cpp/builder_gateway_cpp.sce \
+toolbox_skeleton/sci_gateway/cpp/sci_cpp_find.cxx \
+toolbox_skeleton/sci_gateway/c/sci_cerror.c \
+toolbox_skeleton/sci_gateway/c/sci_csub.c \
+toolbox_skeleton/sci_gateway/c/sci_csum.c \
+toolbox_skeleton/sci_gateway/c/sci_foo.c \
+toolbox_skeleton/sci_gateway/c/sci_multiplybypi.c \
+toolbox_skeleton/sci_gateway/fortran/builder_gateway_fortran.sce \
+toolbox_skeleton/sci_gateway/fortran/sci_fsum.c \
+toolbox_skeleton/src/builder_src.sce \
+toolbox_skeleton/src/c/builder_c.sce \
+toolbox_skeleton/src/c/csub.c \
+toolbox_skeleton/src/c/csub.h \
+toolbox_skeleton/src/c/csum.c \
+toolbox_skeleton/src/c/csum.h \
+toolbox_skeleton/src/cleaner_src.sce \
+toolbox_skeleton/src/c/multiplybypi.c \
+toolbox_skeleton/src/c/multiplybypi.h \
+toolbox_skeleton/src/fortran/builder_fortran.sce \
+toolbox_skeleton/src/fortran/fsum.f \
+toolbox_skeleton/src/java/builder_java.sce \
+toolbox_skeleton/src/java/org/scilab/contrib/toolboxskeleton/Sum.java \
+toolbox_skeleton/tests/unit_tests/c_sum.dia.ref \
 toolbox_skeleton/tests/unit_tests/c_sum.tst \
+toolbox_skeleton/tests/unit_tests/fortran_sum.dia.ref \
 toolbox_skeleton/tests/unit_tests/fortran_sum.tst \
+toolbox_skeleton/tests/unit_tests/java_sum.dia.ref \
+toolbox_skeleton/tests/unit_tests/java_sum.tst \
 toolbox_skeleton/tests/unit_tests/scilab_sum.dia.ref \
-toolbox_skeleton/tests/unit_tests/fortran_sum.dia.ref \
-toolbox_skeleton/tests/unit_tests/c_sum.dia.ref \
 toolbox_skeleton/tests/unit_tests/scilab_sum.tst \
-toolbox_skeleton/tests/unit_tests/java_sum.tst \
-toolbox_skeleton/tests/unit_tests/java_sum.dia.ref \
-toolbox_skeleton/sci_gateway/fortran/builder_gateway_fortran.sce \
-toolbox_skeleton/sci_gateway/fortran/sci_fsum.c \
-toolbox_skeleton/sci_gateway/c/sci_csub.c \
-toolbox_skeleton/sci_gateway/c/sci_multiplybypi.c \
-toolbox_skeleton/sci_gateway/c/sci_foo.c \
-toolbox_skeleton/sci_gateway/c/sci_cerror.c \
-toolbox_skeleton/sci_gateway/c/sci_csum.c \
-toolbox_skeleton/sci_gateway/c/builder_gateway_c.sce \
-toolbox_skeleton/sci_gateway/cpp/builder_gateway_cpp.sce \
-toolbox_skeleton/sci_gateway/cpp/sci_cpp_find.cxx \
-toolbox_skeleton/sci_gateway/builder_gateway.sce \
-toolbox_skeleton/builder.sce \
-toolbox_skeleton/locales/en_US.po \
-toolbox_skeleton/locales/fr_FR.po \
-toolbox_skeleton/macros/scilab_sum.sci \
-toolbox_skeleton/macros/scilab_error.sci \
-toolbox_skeleton/macros/buildmacros.sce \
-toolbox_skeleton/macros/cleanmacros.sce \
 toolbox_skeleton/toolbox_skeleton_redist.iss \
-toolbox_skeleton/toolbox_skeleton.iss \
 xcos_toolbox_skeleton/builder.sce \
 xcos_toolbox_skeleton/changelog.txt \
-xcos_toolbox_skeleton/cleaner.sce \
+xcos_toolbox_skeleton/demos/allSum.dem.sce \
 xcos_toolbox_skeleton/demos/Blocks.zcos \
 xcos_toolbox_skeleton/demos/xcos_toolbox_skeleton.dem.gateway.sce \
-xcos_toolbox_skeleton/demos/allSum.dem.sce \
 xcos_toolbox_skeleton/DESCRIPTION \
 xcos_toolbox_skeleton/DESCRIPTION-FUNCTIONS \
 xcos_toolbox_skeleton/etc/xcos_toolbox_skeleton.quit \
@@ -487,15 +489,20 @@ xcos_toolbox_skeleton/help/en_US/TBX_SUM_c.xml \
 xcos_toolbox_skeleton/help/en_US/tbx_sum.xml \
 xcos_toolbox_skeleton/help/fr_FR/build_help.sce \
 xcos_toolbox_skeleton/images/gif/TBX_MUT_STYLE.gif \
+xcos_toolbox_skeleton/images/gif/TBX_NOOP.gif \
 xcos_toolbox_skeleton/images/gif/TBX_SUM_c.gif \
 xcos_toolbox_skeleton/images/gif/TBX_SUM_sci.gif \
 xcos_toolbox_skeleton/images/svg/TBX_MUT_STYLE.svg \
+xcos_toolbox_skeleton/images/svg/TBX_NOOP.svg \
 xcos_toolbox_skeleton/images/svg/TBX_SUM_c.svg \
 xcos_toolbox_skeleton/images/svg/TBX_SUM_sci.svg \
 xcos_toolbox_skeleton/license.txt \
 xcos_toolbox_skeleton/macros/buildmacros.sce \
 xcos_toolbox_skeleton/macros/cleanmacros.sce \
 xcos_toolbox_skeleton/macros/TBX_MUT_STYLE.sci \
+xcos_toolbox_skeleton/macros/TBX_NOOP.sci \
+xcos_toolbox_skeleton/macros/TBX_NOOP_sci.sci \
+xcos_toolbox_skeleton/macros/TBX_NOOP_sim.sci \
 xcos_toolbox_skeleton/macros/TBX_SUM_c.sci \
 xcos_toolbox_skeleton/macros/TBX_SUM_sci.sci \
 xcos_toolbox_skeleton/macros/TBX_SUM_sim.sci \
@@ -509,9 +516,15 @@ xcos_toolbox_skeleton/src/c/builder_c.sce \
 xcos_toolbox_skeleton/src/c/business.h \
 xcos_toolbox_skeleton/src/c/business_sum.c \
 xcos_toolbox_skeleton/src/cleaner_src.sce \
-xcos_toolbox_skeleton/tests/unit_tests/tbx_sum.tst \
+xcos_toolbox_skeleton/src/c/tbx_block_noop.c \
+xcos_toolbox_skeleton/tests/benchmark/noop_matrices_c.tst \
+xcos_toolbox_skeleton/tests/benchmark/noop_matrices_scilab.tst \
+xcos_toolbox_skeleton/tests/benchmark/noop_matrices.zcos \
+xcos_toolbox_skeleton/tests/benchmark/noop_scalar_c.tst \
+xcos_toolbox_skeleton/tests/benchmark/noop_scalar_scilab.tst \
+xcos_toolbox_skeleton/tests/benchmark/noop_scalar.zcos \
 xcos_toolbox_skeleton/tests/unit_tests/tbx_sum.dia.ref \
-loader.sce
+xcos_toolbox_skeleton/tests/unit_tests/tbx_sum.tst
 
 all: all-am
 
index 79be267..575c581 100644 (file)
@@ -86,7 +86,14 @@ Source: contrib\{#XCOS_TOOLBOX_SKELETON}\src\c\block_sum.c; DestDir: {app}\contr
 Source: contrib\{#XCOS_TOOLBOX_SKELETON}\src\c\builder_c.sce; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\src\c; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
 Source: contrib\{#XCOS_TOOLBOX_SKELETON}\src\c\business.h; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\src\c; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
 Source: contrib\{#XCOS_TOOLBOX_SKELETON}\src\c\business_sum.c; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\src\c; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
+Source: contrib\{#XCOS_TOOLBOX_SKELETON}\src\c\tbx_block_noop.c; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\src\c; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
 Source: contrib\{#XCOS_TOOLBOX_SKELETON}\src\cleaner_src.sce; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\src; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
 Source: contrib\{#XCOS_TOOLBOX_SKELETON}\tests\unit_tests\tbx_sum.tst; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\tests\unit_tests; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
 Source: contrib\{#XCOS_TOOLBOX_SKELETON}\tests\unit_tests\tbx_sum.dia.ref; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\tests\unit_tests; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
+Source: contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark\noop_matrices.zcos; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
+Source: contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark\noop_matrices_c.tst; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
+Source: contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark\noop_matrices_scilab.tst; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
+Source: contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark\noop_scalar.zcos; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
+Source: contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark\noop_scalar_c.tst; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
+Source: contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark\noop_scalar_scilab.tst; DestDir: {app}\contrib\{#XCOS_TOOLBOX_SKELETON}\tests\benchmark; Flags: recursesubdirs; Components: {#COMPN_TOOLBOX_SKELETON} and {#COMPN_XCOS}
 ;--------------------------------------------------------------------------------------------------------------
index a377330..a41835d 100644 (file)
@@ -4,7 +4,7 @@ Title: Xcos toolbox skeleton
 
 Summary: Add some blocks to a palette
 
-Version: 1.0
+Version: 1.1
 
 Author: Clément DAVID <clement.david@scilab-enterprises.com>
 
@@ -18,11 +18,11 @@ WebSite: http://www.scilab.org
 
 License: CeCILL
 
-ScilabVersion: >= 5.4
+ScilabVersion: >= 5.5
 
 Depends: 
 
-Date: 2011-03-15
+Date: 2014-01-15
 
 Description: Example for an Xcos toolbox
  
index 5ca2fc7..df855fb 100644 (file)
@@ -1,3 +1,4 @@
 TBX_SUM_c - block which perform a basic sum of the inputs
 tbx_sum - Scilab native function which perform the same operation as TBX_SUM.
+TBX_NOOP - Scilab or C no-op with any number of inputs and outputs
 
diff --git a/scilab/contrib/xcos_toolbox_skeleton/images/gif/TBX_NOOP.gif b/scilab/contrib/xcos_toolbox_skeleton/images/gif/TBX_NOOP.gif
new file mode 100644 (file)
index 0000000..31bad09
Binary files /dev/null and b/scilab/contrib/xcos_toolbox_skeleton/images/gif/TBX_NOOP.gif differ
diff --git a/scilab/contrib/xcos_toolbox_skeleton/images/svg/TBX_NOOP.svg b/scilab/contrib/xcos_toolbox_skeleton/images/svg/TBX_NOOP.svg
new file mode 100644 (file)
index 0000000..b284849
--- /dev/null
@@ -0,0 +1 @@
+<svg/>
diff --git a/scilab/contrib/xcos_toolbox_skeleton/macros/TBX_NOOP.sci b/scilab/contrib/xcos_toolbox_skeleton/macros/TBX_NOOP.sci
new file mode 100644 (file)
index 0000000..5616d7f
--- /dev/null
@@ -0,0 +1,76 @@
+//
+// This file is part of the Xcos skeleton toolbox
+//
+// see license.txt for more licensing information
+
+function [x,y,typ]=TBX_NOOP(job,arg1,arg2)
+    x=[];y=[];typ=[]
+    select job
+    case "set" then
+        x=arg1;
+        model=arg1.model;
+        graphics=arg1.graphics;
+        exprs=graphics.exprs;
+
+        while %t do
+            [ok,sim,in1,in2,intyp,out1,out2,outyp,exprs]=scicos_getvalue(..
+            "Set no-operation parameters",..
+            ["(0=C, 1=Scilab)";
+            "Input rows sizes";
+            "Input columns sizes";
+            "Input types";
+            "Output rows sizes";
+            "Output columns sizes";
+            "Output types"],..
+            list("vec",1,"vec",-1,"vec",-1,"vec",-1,"vec",-2,"vec",-2,"vec",-2),..
+            exprs)
+            if ~ok then
+                break,
+            end //user cancel modification
+
+            if or(size(in1) <> size(in2)) | or(size(in1) <> size(intyp)) then
+                message(["Some specified values are inconsistent:";
+                " ";"All input parameters should have the same length"])
+                ok = %f;
+            end
+            if or(size(out1) <> size(out2)) | or(size(out1) <> size(outyp)) then
+                message(["Some specified values are inconsistent:";
+                " ";"All output parameters should have the same length"])
+                ok = %f;
+            end
+
+            if ok then
+                [model,graphics,ok]=set_io(model,graphics,list([in1,in2],intyp),list([out1,out2],outyp),1,[])
+            end
+
+            if ok then
+                if sim == 0 then
+                    model.sim=list("tbx_block_noop",4);
+                    graphics.style=["blockWithLabel;displayedLabel=""NOOP C"""]
+                else
+                    model.sim=list("TBX_NOOP_sim",5);
+                    graphics.style=["blockWithLabel;displayedLabel=""NOOP Scilab"""]
+                end
+
+                graphics.exprs=exprs;
+                x.graphics=graphics;
+                x.model=model;
+                break;
+            end
+        end
+
+    case "define" then
+        model=scicos_model()
+        model.sim=list("tbx_block_noop",4)
+
+        model.evtin=1
+        model.blocktype="d"
+        model.dep_ut=[%f %f]
+
+        exprs=["0";"";"";"";"";"";""];
+        gr_i=[]
+        x=standard_define([3 2],model,exprs,gr_i)
+        x.graphics.style=["blockWithLabel;displayedLabel=""NOOP C"""]
+    end
+endfunction
+
diff --git a/scilab/contrib/xcos_toolbox_skeleton/macros/TBX_NOOP_sci.sci b/scilab/contrib/xcos_toolbox_skeleton/macros/TBX_NOOP_sci.sci
new file mode 100644 (file)
index 0000000..9d2efc4
--- /dev/null
@@ -0,0 +1,61 @@
+//
+// This file is part of the Xcos skeleton toolbox
+//
+// see license.txt for more licensing information
+
+function [x,y,typ]=TBX_NOOP_sci(job,arg1,arg2)
+    x=[];y=[];typ=[]
+    select job
+    case "set" then
+        x=arg1;
+        model=arg1.model;
+        graphics=arg1.graphics;
+        exprs=graphics.exprs;
+
+        while %t do
+            [ok,in1,in2,intyp,exprs]=scicos_getvalue(..
+            "Set no-operation parameters",..
+            ["Input rows sizes";
+            "Input columns sizes";
+            "Input types"],..
+            list("vec",-1,"vec",-1,"vec",-1),..
+            exprs)
+            if ~ok then
+                break,
+            end //user cancel modification
+
+            if or(size(in1) <> size(in2)) | or(size(in1) <> size(in2)) then
+                message(["Some specified values are inconsistent:";
+                " ";"All parameters should have the same length"])
+                ok = %f;
+            end
+
+            if ok then
+                model.in1=in1;
+                model.in2=in2;
+                model.intyp=intyp;
+
+                graphics.pin=zeros(in1, 1);
+
+                graphics.exprs=exprs;
+                x.graphics=graphics;
+                x.model=model;
+                break;
+            end
+        end
+
+    case "define" then
+        model=scicos_model()
+        model.sim=list("TBX_NOOP_sim",5)
+
+        model.evtin=1
+        model.blocktype="d"
+        model.dep_ut=[%f %f]
+
+        exprs=["[]";"[]";"[]"];
+        gr_i=[]
+        x=standard_define([3 2],model,exprs,gr_i)
+        x.graphics.style=["blockWithLabel;displayedLabel=NOOP_sci"]
+    end
+endfunction
+
diff --git a/scilab/contrib/xcos_toolbox_skeleton/macros/TBX_NOOP_sim.sci b/scilab/contrib/xcos_toolbox_skeleton/macros/TBX_NOOP_sim.sci
new file mode 100644 (file)
index 0000000..fc1cf13
--- /dev/null
@@ -0,0 +1,9 @@
+//
+// This file is part of the Xcos skeleton toolbox
+//
+// see license.txt for more licensing information
+
+
+function block=TBX_NOOP_sim(block,flag)
+endfunction
+
index 54f7f57..8e66649 100644 (file)
@@ -3,7 +3,7 @@
 function buildmacros()
     macros_path = get_absolute_file_path("buildmacros.sce");
 
-    blocks = ["TBX_SUM_c" "TBX_MUT_STYLE", "TBX_SUM_sci"];
+    blocks = ["TBX_SUM_c" "TBX_MUT_STYLE", "TBX_SUM_sci", "TBX_NOOP"];
 
     tbx_build_macros(TOOLBOX_NAME, macros_path);
     tbx_build_blocks(toolbox_dir, blocks);
index f25318f..747e369 100644 (file)
@@ -28,15 +28,15 @@ function builder_c()
         end
     end
 
-    tbx_build_src(["block_sum", "business_sum"],        ..
-    ["block_sum.c", "business_sum.c"],    ..
-    "c",                                  ..
-    src_c_path,                           ..
-    "",                                   ..
-    LDFLAGS,                              ..
-    CFLAGS,                               ..
-    "",                                   ..
-    "",                                   ..
+    tbx_build_src(["block_sum", "business_sum", "tbx_block_noop"],          ..
+    ["block_sum.c", "business_sum.c" "tbx_block_noop.c"],                   ..
+    "c",                                                                    ..
+    src_c_path,                                                             ..
+    "",                                                                     ..
+    LDFLAGS,                                                                ..
+    CFLAGS,                                                                 ..
+    "",                                                                     ..
+    "",                                                                     ..
     "xcos_tbx_skel");
 endfunction
 
diff --git a/scilab/contrib/xcos_toolbox_skeleton/src/c/tbx_block_noop.c b/scilab/contrib/xcos_toolbox_skeleton/src/c/tbx_block_noop.c
new file mode 100644 (file)
index 0000000..94c32d6
--- /dev/null
@@ -0,0 +1,8 @@
+/* This file is released under the 3-clause BSD license. See COPYING-BSD. */
+
+#include <scicos_block4.h>
+
+void tbx_block_noop(scicos_block* block, scicos_flag flag)
+{
+}
+
diff --git a/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices.zcos b/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices.zcos
new file mode 100644 (file)
index 0000000..520b8cf
Binary files /dev/null and b/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices.zcos differ
diff --git a/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices_c.tst b/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices_c.tst
new file mode 100644 (file)
index 0000000..604ea8a
--- /dev/null
@@ -0,0 +1,17 @@
+// This file is released under the 3-clause BSD license. See COPYING-BSD.
+//=======================================================================
+
+loadXcosLibs();
+loadScicos();
+
+assert_checktrue(importXcosDiagram("tests/benchmark/noop_matrices.zcos"))
+
+context = struct();
+context.NOOP_mode = 0; // using a C simulation function
+
+// <-- BENCH START -->
+timer();
+scicos_simulate(scs_m, context);
+disp(timer());
+// <-- BENCH END -->
+
diff --git a/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices_scilab.tst b/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_matrices_scilab.tst
new file mode 100644 (file)
index 0000000..91cb941
--- /dev/null
@@ -0,0 +1,17 @@
+// This file is released under the 3-clause BSD license. See COPYING-BSD.
+//=======================================================================
+
+loadXcosLibs();
+loadScicos();
+
+assert_checktrue(importXcosDiagram("tests/benchmark/noop_matrices.zcos"))
+
+context = struct();
+context.NOOP_mode = 1; // using a Scilab simulation function
+
+// <-- BENCH START -->
+timer();
+scicos_simulate(scs_m, context);
+disp(timer());
+// <-- BENCH END -->
+
diff --git a/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar.zcos b/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar.zcos
new file mode 100644 (file)
index 0000000..dd167c9
Binary files /dev/null and b/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar.zcos differ
diff --git a/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar_c.tst b/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar_c.tst
new file mode 100644 (file)
index 0000000..377d271
--- /dev/null
@@ -0,0 +1,17 @@
+// This file is released under the 3-clause BSD license. See COPYING-BSD.
+//=======================================================================
+
+loadXcosLibs();
+loadScicos();
+
+assert_checktrue(importXcosDiagram("tests/benchmark/noop_scalar.zcos"))
+
+context = struct();
+context.NOOP_mode = 0; // using a C simulation function
+
+// <-- BENCH START -->
+timer();
+scicos_simulate(scs_m, context);
+disp(timer());
+// <-- BENCH END -->
+
diff --git a/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar_scilab.tst b/scilab/contrib/xcos_toolbox_skeleton/tests/benchmark/noop_scalar_scilab.tst
new file mode 100644 (file)
index 0000000..3f3e877
--- /dev/null
@@ -0,0 +1,17 @@
+// This file is released under the 3-clause BSD license. See COPYING-BSD.
+//=======================================================================
+
+loadXcosLibs();
+loadScicos();
+
+assert_checktrue(importXcosDiagram("tests/benchmark/noop_scalar.zcos"))
+
+context = struct();
+context.NOOP_mode = 1; // using a Scilab simulation function
+
+// <-- BENCH START -->
+timer();
+scicos_simulate(scs_m, context);
+disp(timer());
+// <-- BENCH END -->
+
index 76ac0aa..113e560 100644 (file)
@@ -17,6 +17,9 @@ exec("TMPDIR/xcos_toolbox_skeleton/builder.sce");
 Building macros...
 -- Creation of [xcos_toolbox_skeletonlib] (Macros) --
 genlib: Processing file: TBX_MUT_STYLE.sci
+genlib: Processing file: TBX_NOOP.sci
+genlib: Processing file: TBX_NOOP_sci.sci
+genlib: Processing file: TBX_NOOP_sim.sci
 genlib: Processing file: TBX_SUM_c.sci
 genlib: Processing file: TBX_SUM_sci.sci
 genlib: Processing file: TBX_SUM_sim.sci
@@ -28,6 +31,7 @@ Building sources...
    ilib_gen_Make: Copy compilation files (Makefile*, libtool...) to TMPDIR
    ilib_gen_Make: Copy block_sum.c to TMPDIR
    ilib_gen_Make: Copy business_sum.c to TMPDIR
+   ilib_gen_Make: Copy tbx_block_noop.c to TMPDIR
    ilib_gen_Make: configure : Generate Makefile.
    ilib_gen_Make: Modification of the Makefile in TMPDIR.
    Running the Makefile
index 76ac0aa..113e560 100644 (file)
@@ -17,6 +17,9 @@ exec("TMPDIR/xcos_toolbox_skeleton/builder.sce");
 Building macros...
 -- Creation of [xcos_toolbox_skeletonlib] (Macros) --
 genlib: Processing file: TBX_MUT_STYLE.sci
+genlib: Processing file: TBX_NOOP.sci
+genlib: Processing file: TBX_NOOP_sci.sci
+genlib: Processing file: TBX_NOOP_sim.sci
 genlib: Processing file: TBX_SUM_c.sci
 genlib: Processing file: TBX_SUM_sci.sci
 genlib: Processing file: TBX_SUM_sim.sci
@@ -28,6 +31,7 @@ Building sources...
    ilib_gen_Make: Copy compilation files (Makefile*, libtool...) to TMPDIR
    ilib_gen_Make: Copy block_sum.c to TMPDIR
    ilib_gen_Make: Copy business_sum.c to TMPDIR
+   ilib_gen_Make: Copy tbx_block_noop.c to TMPDIR
    ilib_gen_Make: configure : Generate Makefile.
    ilib_gen_Make: Modification of the Makefile in TMPDIR.
    Running the Makefile
index 71c2f9a..1fda524 100644 (file)
@@ -17,6 +17,9 @@ exec("TMPDIR/xcos_toolbox_skeleton/builder.sce");
 Building macros...
 -- Creation of [xcos_toolbox_skeletonlib] (Macros) --
 genlib: Processing file: TBX_MUT_STYLE.sci
+genlib: Processing file: TBX_NOOP.sci
+genlib: Processing file: TBX_NOOP_sci.sci
+genlib: Processing file: TBX_NOOP_sim.sci
 genlib: Processing file: TBX_SUM_c.sci
 genlib: Processing file: TBX_SUM_sci.sci
 genlib: Processing file: TBX_SUM_sim.sci
@@ -28,6 +31,7 @@ Building sources...
    Running the Makefile
    Compilation of block_sum.c
    Compilation of business_sum.c
+   Compilation of tbx_block_noop.c
    Building shared library (be patient)
    Generate a cleaner file
 Building gateway...