Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
6.0.0 - Русский

Change language to:
English - Français - 日本語 - Português -

Please note that the recommended version of Scilab is 2025.0.0. This page might be outdated.
See the recommended documentation of this function

Справка Scilab >> Modules manager > tbx_builder_src

tbx_builder_src

Builds the user source code (non-gateway) in src/ subdirectory.

Syntax

tbx_builder_src(toolbox_path)

Arguments

toolbox_path

Root directory of toolbox sources; builder scripts will be searched in the src subdirectory of this directory.

Description

tbx_builder_src is used for compiling the non-gateway code of a toolbox.

The compilation of sources in src/ directory follows this convention and priority order:

  • looks for a toolbox_path/src/builder*.sce script, if found, executes it;
  • otherwize, looks for a builder script in each subdirectory of src/ and executes them;
  • for c, cpp, java, fortran subdirectories, if no builder script is found, a default compilation process is done:

    c compilation is done for all *.c files, headers must be present in the c/ directory, function names must have the name of the file (without the .c extension)
    cpp compilation is done for all *.cpp or *.cxx files, headers must be present in the cpp directory, function names must have the name of the file (without the .cpp or .cxx extension)
    java compilation is done for all *.java files under org/scilab/contrib/package_name directories where package_name is given by the user
    fortran compilation is done for all *.f files

The function exits silently if the src directory is absent.

Little automation is done for tbx_builder_src and is only specified for c, cpp, java, fortran because source compiling is a very specific process. Toolbox developers willing to have a more specific compilation process still need to define what the build scripts must perform for compilation.

Examples

// Recommended usage
tbx_builder_src(get_absolute_file_path('builder.sce'))

History

ВерсияОписание
6.0.0

No longer restricts the build scripts to builder_src.sce. Now any scripts called builder*.sce is valid for source compilation.

Automatically scans for builder scripts in subdirectories if no builder script is found in src

A default compilation process is introduced for c/, cpp/, fortran/, java/

Report an issue
<< tbx_builder_macros Modules manager tbx_make >>

Copyright (c) 2022-2024 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Tue Feb 14 15:13:37 CET 2017