############################################################################## # @file BasisScriptConfig.cmake # @brief BASIS script configuration. # # @note The file BasisScriptConfig.cmake is automatically generated by BASIS # from the template file ScriptConfig.cmake.in which is part of BASIS. # # This script configuration file is included before the default script # configuration file which is part of the package itself (ScriptConfig.cmake), # if such file exists in the @c PROJECT_CONFIG_DIR. # Therefore, the BASIS script configuration can be overwritten by the # default script configuration of the project, which in turn can be # overwritten specifically for each script target by specifying a # script target-specific script configuration using the @c CONFIG and/or # @c CONFIG_FILE option of the basis_add_executable() or basis_add_library() # command, respectively. # # @sa http://opensource.andreasschuh.com/cmake-basis/standard/scripttargets.html#script-configuration # # @ingroup BasisScriptConfig ############################################################################## ## @addtogroup BasisScriptConfig # @{ # ============================================================================ # script attributes # ============================================================================ # Note: The following set() commands are required for the API documentation. ## @brief Detected scripting language or UNKNOWN. set (LANGUAGE "${LANGUAGE}") ## @brief Directory of script file. # # @note Mainly used in script configuration itself to make relative paths # absolute. In particular, basis_set_script_path() uses this variable. set (__DIR__ "${__DIR__}") ## @brief Absolute path of script file. # # @note As this path is fixed after the build, it should be used only if # it is not otherwise possible to determine the path of the current # script file. It prohibits the relocation of the installation. set (__FILE__ "${__FILE__}") ## @brief Name of script file. set (__NAME__ "${__NAME__}") ## @brief Name of script file in uppercase only. string (TOUPPER "${__NAME__}" __NAME_U__) ## @brief Name of script file in lowercase only. string (TOLOWER "${__NAME__}" __NAME_L__) # ============================================================================ # aliases of script attributes for backward compatibility # ============================================================================ set (DIR ${__DIR__}) set (FILE ${__FILE__}) set (NAME ${__NAME__}) set (NAME_U ${__NAME_U__}) set (NAME_L ${__NAME_L__}) # ============================================================================ # directories # ============================================================================ # ---------------------------------------------------------------------------- # relative to script file # Example: # @code # #! /usr/bin/env bash # get_executable_directory exec_dir # libexec_dir=${exec_dir}/__LIBEXEC_DIR__ # @endcode ## @brief Installation prefix relative to script location. basis_set_script_path (PREFIX_DIR "@CMAKE_BINARY_DIR@" "@CMAKE_INSTALL_PREFIX@") ## @brief Directory of main executables relative to script location. basis_set_script_path (RUNTIME_DIR "@BINARY_RUNTIME_DIR@" "@INSTALL_RUNTIME_DIR@") ## @brief Directory of auxiliary executables relative to script location. basis_set_script_path (LIBEXEC_DIR "@BINARY_LIBEXEC_DIR@" "@INSTALL_LIBEXEC_DIR@") ## @brief Directory of shared and module libraries relative to script location. basis_set_script_path (LIBRARY_DIR "@BINARY_LIBRARY_DIR@" "@INSTALL_LIBRARY_DIR@") ## @brief Directory of static and import libraries relative to script location. basis_set_script_path (ARCHIVE_DIR "@BINARY_ARCHIVE_DIR@" "@INSTALL_ARCHIVE_DIR@") ## @brief Directory of auxiliary data files relative to script location. basis_set_script_path (DATA_DIR "@PROJECT_DATA_DIR@" "@INSTALL_DATA_DIR@") ## @brief Directory of Python modules relative to script location. basis_set_script_path (PYTHON_LIBRARY_DIR "@BINARY_PYTHON_LIBRARY_DIR@" "@INSTALL_PYTHON_LIBRARY_DIR@") ## @brief Directory of Jython modules relative to script location. basis_set_script_path (JYTHON_LIBRARY_DIR "@BINARY_JYTHON_LIBRARY_DIR@" "@INSTALL_JYTHON_LIBRARY_DIR@") ## @brief Directory of Perl modules relative to script location. basis_set_script_path (PERL_LIBRARY_DIR "@BINARY_PERL_LIBRARY_DIR@" "@INSTALL_PERL_LIBRARY_DIR@") ## @brief Directory of MATLAB modules relative to script location. basis_set_script_path (MATLAB_LIBRARY_DIR "@BINARY_MATLAB_LIBRARY_DIR@" "@INSTALL_MATLAB_LIBRARY_DIR@") ## @brief Directory of Bash modules relative to script location. basis_set_script_path (BASH_LIBRARY_DIR "@BINARY_BASH_LIBRARY_DIR@" "@INSTALL_BASH_LIBRARY_DIR@") # ---------------------------------------------------------------------------- # relative to installation prefix # Example: # @code # #! /usr/bin/env bash # get_executable_directory exec_dir # libexec_dir=${exec_dir}/__PREFIX_DIR__/__LIBEXEC_DIR_SUFFIX__ # @endcode basis_get_relative_path (RUNTIME_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${RUNTIME_DIR}") basis_get_relative_path (LIBEXEC_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${LIBEXEC_DIR}") basis_get_relative_path (LIBRARY_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${LIBRARY_DIR}") basis_get_relative_path (ARCHIVE_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${ARCHIVE_DIR}") basis_get_relative_path (DATA_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${DATA_DIR}") basis_get_relative_path (PYTHON_LIBRARY_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${PYTHON_LIBRARY_DIR}") basis_get_relative_path (JYTHON_LIBRARY_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${JYTHON_LIBRARY_DIR}") basis_get_relative_path (PERL_LIBRARY_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${PERL_LIBRARY_DIR}") basis_get_relative_path (MATLAB_LIBRARY_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${MATLAB_LIBRARY_DIR}") basis_get_relative_path (BASH_LIBRARY_DIR_SUFFIX "${__DIR__}/${PREFIX_DIR}" "${__DIR__}/${BASH_LIBRARY_DIR}") # Note: The following set() commands are needed for the API documentation. ## @brief Directory of main executables relative to installation prefix. set (RUNTIME_DIR_SUFFIX "${RUNTIME_DIR_SUFFIX}") ## @brief Directory of auxiliary executables relative to installation prefix. set (LIBEXEC_DIR_SUFFIX "${LIBEXEC_DIR_SUFFIX}") ## @brief Directory of shared and module libraries relative to installation prefix. set (LIBRARY_DIR_SUFFIX "${LIBRARY_DIR_SUFFIX}") ## @brief Directory of static and import libraries relative to installation prefix. set (ARCHIVE_DIR_SUFFIX "${ARCHIVE_DIR_SUFFIX}") ## @brief Directory of auxiliary data files relative to installation prefix. set (DATA_DIR_SUFFIX "${DATA_DIR_SUFFIX}") ## @brief Directory of Python modules relative to installation prefix. set (PYTHON_LIBRARY_DIR_SUFFIX "${PYTHON_LIBRARY_DIR_SUFFIX}") ## @brief Directory of Jython modules relative to installation prefix. set (JYTHON_LIBRARY_DIR_SUFFIX "${JYTHON_LIBRARY_DIR_SUFFIX}") ## @brief Directory of Perl modules relative to installation prefix. set (PERL_LIBRARY_DIR_SUFFIX "${PERL_LIBRARY_DIR_SUFFIX}") ## @brief Directory of MATLAB modules relative to installation prefix. set (MATLAB_LIBRARY_DIR_SUFFIX "${MATLAB_LIBRARY_DIR_SUFFIX}") ## @brief Directory of Bash modules relative to installation prefix. set (BASH_LIBRARY_DIR_SUFFIX "${BASH_LIBRARY_DIR_SUFFIX}") ## @} # end of Doxygen group