CMake modules defining settings for BASIS. More...
Files | |
file | BasisConfigSettings.cmake |
Sets basic variables used in CMake package configuration. | |
file | BasisProject.cmake |
Meta-data of this BASIS project. | |
file | BasisSettings.cmake |
Default project-independent settings. | |
file | ConfigSettings.cmake |
Sets variables used in CMake package configuration. | |
file | CTestCustom.cmake |
Custom testing configuration. | |
file | Depends.cmake |
Find additional dependencies. | |
file | ProjectSettings.cmake |
Default project-dependent settings. | |
file | Settings.cmake |
Non-default project settings. | |
Variables | |
BASIS_AUTO_PREFIX_INCLUDES | |
Enable/Disable copying of all public header files to the build tree. | |
option | BASIS_COMPILE_SCRIPTS |
Enable compilation of scripts if supported by the language. | |
option | BASIS_DEBUG |
Request debugging messages from BASIS functions. | |
BASIS_INCLUDES_CHECK_EXCLUDE | |
Specify public header files which are excluded from check whether their path is prefixed by the INCLUDE_PREFIX . | |
BASIS_INSTALL_PUBLIC_HEADERS_OF_CXX_UTILITIES | |
Force installation of public header files of BASIS C++ utilities. | |
BASIS_LIBRARY_COMPONENT | |
Default component used for library targets when no component is specified. | |
BASIS_MCC_FLAGS | |
Compile flags used to build MATLAB Compiler targets. | |
option | BASIS_MCC_MATLAB_MODE |
Enable/Disable invocation of MATLAB Compiler in MATLAB mode. | |
BASIS_MCC_RETRY_ATTEMPTS | |
Maximum number of retries on MATLAB Compiler license checkout. | |
BASIS_MCC_RETRY_DELAY | |
Delay between retries to build MATLAB Compiler compiled targets on license checkout errors. | |
BASIS_MCC_TIMEOUT | |
Timeout for building MATLAB Compiler targets. | |
BASIS_MEX_FLAGS | |
Compile flags used to build MEX-files using the MEX script. | |
BASIS_MEX_TIMEOUT | |
Timeout for building MEX-file targets. | |
BASIS_NAMESPACE | |
Global namespace of BASIS projects. | |
BASIS_NO_BASIS_UTILITIES | |
Specifies that the BASIS C++ utilities shall by default not be added as dependency of an executable. | |
BASIS_PROJECT_NAMESPACE_CMAKE | |
CMake namespace of top-level project. | |
BASIS_PROPERTIES_ON_TARGETS | |
Names of recognized properties on targets. | |
BASIS_RESERVED_TARGET_NAMES | |
List of names used for special purpose targets. | |
BASIS_RUNTIME_COMPONENT | |
Default component used for executables when no component is specified. | |
BASIS_SCRIPT_CONFIG_FILE | |
Default script configuration template. | |
BASIS_SCRIPT_EXECUTE_PROCESS | |
Script used to execute a process in CMake script mode. | |
BASIS_SCRIPT_MCC | |
Script used to invoke the MATLAB Compiler in MATLAB mode. | |
BASIS_SVN_USERS_FILE | |
File used by default as --authors file to svn2cl . | |
BASIS_USE_FULLY_QUALIFIED_UIDS | |
Whether BASIS shall use fully-qualified target UIDs. | |
BASIS_USE_MODULE_NAMESPACES | |
Whether BASIS should use a separate namespace for each module. | |
option | BASIS_VERBOSE |
Request verbose messages from BASIS functions. | |
option | BUILD_DOCUMENTATION |
Request build/installation of documentation. | |
option | BUILD_EXAMPLE |
Request build/installation of example. | |
CPACK_SOURCE_IGNORE_FILES | |
Patterns to be ignored when creating source package. | |
INCLUDE_PREFIX | |
Prefix for public header files. | |
option | INSTALL_LINKS |
Request installation of symbolic links. | |
PROJECT_NAMESPACE_CMAKE | |
CMake namespace of project. | |
PROJECT_NAMESPACE_JAVA | |
CMake variable of Java package name of project. | |
PROJECT_NAMESPACE_MATLAB | |
CMake variable of MATLAB package name of project. |
CMake modules defining settings for BASIS.
Enable/Disable copying of all public header files to the build tree.
If enabled, BASIS copies the public header files which were found in the PROJECT_INCLUDE_DIR
to the corresponding include directory in the build tree using the same relative paths as will be used for the installation. Moreover, header files with the .in suffix are configured using CMake's configure_file() command with the @ONLY
option.
As the copying of header files adds some additional complexity and results in the file path reported by the compiler in error messages and warnings which will name the corresponding copy of the header file in the build tree, causing potential confusion and editing of the copy by mistake, this feature was made optional. Further, the inclusion of uncovered files works only if the file is in the source tree, not the build tree. This is a restriction of CTest. A bug report has been submitted (#12910). A project can enable the copying of public header files in the Settings.cmake file by setting this CMake variable to TRUE. The advantage is that the files in the source tree need not to be organized in subdirectories.
If disabled, the relative path of header files is not adjusted to match the actual installation. Therefore, in this case, the project developer themself must maintain the sbia/<:project>
subdirectory structure in the PROJECT_INCLUDE_DIR
directory tree, where <project> is the project name in lower case only.
Definition at line 365 of file BasisSettings.cmake.
option BASIS_COMPILE_SCRIPTS |
Enable compilation of scripts if supported by the language.
In particular, Python modules are compiled if this option is enabled and only the compiled modules are installed.
Definition at line 301 of file BasisSettings.cmake.
Specify public header files which are excluded from check whether their path is prefixed by the INCLUDE_PREFIX
.
If BASIS_AUTO_PREFIX_INCLUDES
is FALSE
and a public header file is encountered whose path is not prefixed by INCLUDE_PREFIX
, a warning is output by BASIS. This warning can be suppressed for certain public header files using this variable. If the path of the public header file relative to PROJECT_INCLUDE_DIR
matches either one of the listed regular expressions, the warning is not displayed. Note that special characters in the regular expressions will have to be escaped twice, e.g., "\\\\." corresponds to the regular expression "\.", i.e., matches a dot (.).
Definition at line 378 of file BasisSettings.cmake.
Force installation of public header files of BASIS C++ utilities.
If this variable is set to FALSE, each header file in the PROJECT_INCLUDE_DIR
is scanned for an include statement which includes one of the public header files of the BASIS C++ utilities. If such include statement was found in a public header file of the project, the public header files of the BASIS C++ utilities are also installed as the project's public header files depend on them. You can set this variable to TRUE in the Settings.cmake file of your project to force the installation of the public header files of the project-specific BASIS C++ utilities.
Definition at line 339 of file BasisSettings.cmake.
Default component used for library targets when no component is specified.
The default component a library target and its auxiliary files are associated with if no component was specified, explicitly.
Definition at line 283 of file BasisSettings.cmake.
CMake namespace of top-level project.
This is the common namespace of a BASIS project and its modules. It is the part of the namespace which is only required if the project's targets are referenced from another project, but not within the project.
Definition at line 93 of file ProjectSettings.cmake.
Names of recognized properties on targets.
Unfortunately, the ARGV
and ARGN
arguments of a CMake function() or macro() does not preserve values which themselves are lists. Therefore, it is not possible to distinguish between property names and their values in the arguments passed to set_target_properties() or basis_set_target_properties(). To overcome this problem, this list specifies all the possible property names. Everything else is considered to be a property value except the first argument follwing right after the PROPERTIES
keyword. Alternatively, basis_set_property() can be used as here no disambiguity exists.
Definition at line 153 of file BasisSettings.cmake.
List of names used for special purpose targets.
Contains a list of target names that are used by the BASIS functions for special purposes and are hence not to be used for project targets.
Definition at line 35 of file BasisSettings.cmake.
Default component used for executables when no component is specified.
The default component an executable target and its auxiliary files are associated with if no component was specified, explicitly.
Definition at line 289 of file BasisSettings.cmake.
Default script configuration template.
This is the default template used by basis_add_script() to configure the script during the build step. If the file PROJECT_CONFIG_DIR/ScriptConfig.cmake.in
exists, the value of this variable is set to its path by basis_project_initialize().
Definition at line 318 of file BasisSettings.cmake.
Script used to execute a process in CMake script mode.
In order to be able to assign a timeout to the execution of a custom command and to add some error message parsing, this script is used by some build rules to actually perform the build step. See for example, the build of executables using the MATLAB Compiler.
Definition at line 310 of file BasisSettings.cmake.
File used by default as --authors
file to svn2cl
.
This file lists all Subversion users at SBIA and is used by default for the mapping of Subversion user names to real names during the generation of changelogs.
Definition at line 325 of file BasisSettings.cmake.
Whether BASIS shall use fully-qualified target UIDs.
If this option is OFF, the namespace of the top-level BASIS project is not prepended to the actual CMake build target names.
For example, instead of the fully-qualified target UID "sbia.basis.target", the CMake target name will simply be "target". Only when the target is referenced from another project, the fully-qualified target UID is usually required.
Definition at line 70 of file ProjectSettings.cmake.
Whether BASIS should use a separate namespace for each module.
If this option is ON, BASIS will use a separate namespace for each module. Otherwise, all modules of a project reside dirctly in the namespace of the top-level project itself.
Definition at line 77 of file ProjectSettings.cmake.
Prefix for public header files.
The prefix used for the output directory of the configured public header files in the build tree and the installation of these under the INSTALL_INCLUDE_DIR
. The header files have to be included in a source file using the entire relative path, e.g.,
#include <sbia/basis/config.h>
This avoids name conflicts among projects in a more reliable way then only changing the order of paths in the include search path and is similar to prefixing the file name of header files, but at the time avoids the use of such prefixing of the file name itself for the developer.
If this project is a module of another project, it appends its name to the already set include prefix. Otherwise, the include prefix is set to the common default prefix of BASIS projects first, i.e., "sbia", and then the name of the project is appended.
PROJECT_CODE_DIR
instead of the PROJECT_INCLUDE_DIR
and therefore not installed, it can be included without the use of such relative path.Definition at line 333 of file ProjectSettings.cmake.
option INSTALL_LINKS |
Request installation of symbolic links.
Definition at line 396 of file BasisSettings.cmake.
CMake namespace of project.
The CMake namespace of a BASIS project is made up of its name in lower case only as well as the namespace the project belongs to, i.e., the namespace of the project this project is a module of.
Example:
basis_make_target_uid(TARGET_UID "mycmd") # sets TARGET_UID to "sbia.basis.mycmd"
Definition at line 119 of file ProjectSettings.cmake.
CMake variable of Java package name of project.
The Java package name of a BASIS project is made up of its name in lower case only as well as the package name of the project it belongs to.
Example:
package sbia.basis;
Definition at line 168 of file ProjectSettings.cmake.
CMake variable of MATLAB package name of project.
The MATLAB package name of a BASIS project is made up of its name in lower case only as well as the package name of the project it belongs to.
For information on MATLAB's package and class folders, visit the following web page from MathWorks:
Example:
import sbia.basis.cls
Definition at line 293 of file ProjectSettings.cmake.