GNU Octave  3.8.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions | Variables
defaults.cc File Reference
#include <cstdlib>
#include <algorithm>
#include <iostream>
#include <string>
#include <sys/types.h>
#include <unistd.h>
#include "dir-ops.h"
#include "oct-env.h"
#include "file-stat.h"
#include "pathsearch.h"
#include "str-vec.h"
#include <defaults.h>
#include "defun.h"
#include "error.h"
#include "file-ops.h"
#include "gripes.h"
#include "help.h"
#include "input.h"
#include "load-path.h"
#include "oct-obj.h"
#include "ov.h"
#include "parse.h"
#include "toplev.h"
#include "unwind-prot.h"
#include "variables.h"
#include <version.h>
Include dependency graph for defaults.cc:

Go to the source code of this file.

Functions

OCTAVE_EXPORT octave_value_list FEDITOR (const octave_value_list &args, int nargout)
OCTAVE_EXPORT octave_value_list FEXEC_PATH (const octave_value_list &args, int nargout)
OCTAVE_EXPORT octave_value_list FIMAGE_PATH (const octave_value_list &args, int nargout)
OCTAVE_EXPORT octave_value_list FOCTAVE_HOME (const octave_value_list &args, int)
OCTAVE_EXPORT octave_value_list FOCTAVE_VERSION (const octave_value_list &args, int)
void install_defaults (void)
static void set_built_in_docstrings_file (void)
static void set_default_arch_lib_dir (void)
static void set_default_bin_dir (void)
static void set_default_data_dir (void)
static void set_default_doc_cache_file (void)
static void set_default_editor (void)
static void set_default_fcn_file_dir (void)
static void set_default_image_dir (void)
static void set_default_info_dir (void)
static void set_default_info_file (void)
static void set_default_info_prog (void)
static void set_default_libexec_dir (void)
static void set_default_local_api_arch_lib_dir (void)
static void set_default_local_api_fcn_file_dir (void)
static void set_default_local_api_oct_file_dir (void)
static void set_default_local_arch_lib_dir (void)
static void set_default_local_fcn_file_dir (void)
static void set_default_local_oct_file_dir (void)
static void set_default_local_ver_arch_lib_dir (void)
static void set_default_local_ver_fcn_file_dir (void)
static void set_default_local_ver_oct_file_dir (void)
static void set_default_oct_etc_dir (void)
static void set_default_oct_file_dir (void)
static void set_default_oct_locale_dir (void)
static void set_default_texi_macros_file (void)
void set_exec_path (const std::string &path_arg)
void set_image_path (const std::string &path)
static void set_local_site_defaults_file (void)
static void set_octave_home (void)
static void set_site_defaults_file (void)
std::string subst_octave_home (const std::string &s)

Variables

std::string Varch_lib_dir
std::string Vbin_dir
std::string Vbuilt_in_docstrings_file
std::string Vdata_dir
std::string VEDITOR
static std::string VEXEC_PATH
std::string Vfcn_file_dir
std::string Vimage_dir
static std::string VIMAGE_PATH
std::string Vinfo_dir
std::string Vlibexec_dir
std::string Vlocal_api_arch_lib_dir
std::string Vlocal_api_fcn_file_dir
std::string Vlocal_api_oct_file_dir
std::string Vlocal_arch_lib_dir
std::string Vlocal_fcn_file_dir
std::string Vlocal_oct_file_dir
std::string Vlocal_site_defaults_file
std::string Vlocal_ver_arch_lib_dir
std::string Vlocal_ver_fcn_file_dir
std::string Vlocal_ver_oct_file_dir
std::string Voct_etc_dir
std::string Voct_file_dir
std::string Voct_locale_dir
std::string Voctave_home
std::string Vsite_defaults_file

Function Documentation

OCTAVE_EXPORT octave_value_list FEDITOR ( const octave_value_list args,
int  nargout 
)

Definition at line 486 of file defaults.cc.

References SET_NONEMPTY_INTERNAL_STRING_VARIABLE.

OCTAVE_EXPORT octave_value_list FEXEC_PATH ( const octave_value_list args,
int  nargout 
)

Definition at line 519 of file defaults.cc.

References set_exec_path(), SET_NONEMPTY_INTERNAL_STRING_VARIABLE, and VEXEC_PATH.

OCTAVE_EXPORT octave_value_list FIMAGE_PATH ( const octave_value_list args,
int  nargout 
)

Definition at line 554 of file defaults.cc.

References SET_NONEMPTY_INTERNAL_STRING_VARIABLE.

OCTAVE_EXPORT octave_value_list FOCTAVE_HOME ( const octave_value_list args,
int   
)

Definition at line 577 of file defaults.cc.

References print_usage(), and Voctave_home.

OCTAVE_EXPORT octave_value_list FOCTAVE_VERSION ( const octave_value_list args,
int   
)

Definition at line 598 of file defaults.cc.

References octave_value::length(), OCTAVE_VERSION, and print_usage().

Referenced by install_defaults_fcns().

void install_defaults ( void  )
static void set_built_in_docstrings_file ( void  )
static
static void set_default_arch_lib_dir ( void  )
static

Definition at line 150 of file defaults.cc.

References OCTAVE_ARCHLIBDIR, subst_octave_home(), and Varch_lib_dir.

Referenced by install_defaults().

static void set_default_bin_dir ( void  )
static

Definition at line 240 of file defaults.cc.

References OCTAVE_BINDIR, subst_octave_home(), and Vbin_dir.

Referenced by install_defaults().

static void set_default_data_dir ( void  )
static

Definition at line 138 of file defaults.cc.

References OCTAVE_DATADIR, subst_octave_home(), and Vdata_dir.

Referenced by install_defaults().

static void set_default_doc_cache_file ( void  )
static
static void set_default_editor ( void  )
static

Definition at line 357 of file defaults.cc.

References octave_env::getenv(), and VEDITOR.

Referenced by install_defaults().

static void set_default_fcn_file_dir ( void  )
static

Definition at line 210 of file defaults.cc.

References OCTAVE_FCNFILEDIR, subst_octave_home(), and Vfcn_file_dir.

Referenced by install_defaults().

static void set_default_image_dir ( void  )
static

Definition at line 216 of file defaults.cc.

References OCTAVE_IMAGEDIR, subst_octave_home(), and Vimage_dir.

Referenced by install_defaults().

static void set_default_info_dir ( void  )
static

Definition at line 132 of file defaults.cc.

References OCTAVE_INFODIR, subst_octave_home(), and Vinfo_dir.

Referenced by install_defaults().

static void set_default_info_file ( void  )
static

Definition at line 330 of file defaults.cc.

References octave_env::getenv(), OCTAVE_INFOFILE, subst_octave_home(), and Vinfo_file.

Referenced by install_defaults().

static void set_default_info_prog ( void  )
static

Definition at line 343 of file defaults.cc.

References octave_env::getenv(), and Vinfo_program.

Referenced by install_defaults().

static void set_default_libexec_dir ( void  )
static

Definition at line 144 of file defaults.cc.

References OCTAVE_LIBEXECDIR, subst_octave_home(), and Vlibexec_dir.

Referenced by install_defaults().

static void set_default_local_api_arch_lib_dir ( void  )
static

Definition at line 162 of file defaults.cc.

References OCTAVE_LOCALAPIARCHLIBDIR, subst_octave_home(), and Vlocal_api_arch_lib_dir.

Referenced by install_defaults().

static void set_default_local_api_fcn_file_dir ( void  )
static

Definition at line 198 of file defaults.cc.

References OCTAVE_LOCALAPIFCNFILEDIR, subst_octave_home(), and Vlocal_api_fcn_file_dir.

Referenced by install_defaults().

static void set_default_local_api_oct_file_dir ( void  )
static

Definition at line 180 of file defaults.cc.

References OCTAVE_LOCALAPIOCTFILEDIR, subst_octave_home(), and Vlocal_api_oct_file_dir.

Referenced by install_defaults().

static void set_default_local_arch_lib_dir ( void  )
static

Definition at line 156 of file defaults.cc.

References OCTAVE_LOCALARCHLIBDIR, subst_octave_home(), and Vlocal_arch_lib_dir.

Referenced by install_defaults().

static void set_default_local_fcn_file_dir ( void  )
static

Definition at line 204 of file defaults.cc.

References OCTAVE_LOCALFCNFILEDIR, subst_octave_home(), and Vlocal_fcn_file_dir.

Referenced by install_defaults().

static void set_default_local_oct_file_dir ( void  )
static

Definition at line 186 of file defaults.cc.

References OCTAVE_LOCALOCTFILEDIR, subst_octave_home(), and Vlocal_oct_file_dir.

Referenced by install_defaults().

static void set_default_local_ver_arch_lib_dir ( void  )
static

Definition at line 168 of file defaults.cc.

References OCTAVE_LOCALVERARCHLIBDIR, subst_octave_home(), and Vlocal_ver_arch_lib_dir.

Referenced by install_defaults().

static void set_default_local_ver_fcn_file_dir ( void  )
static

Definition at line 192 of file defaults.cc.

References OCTAVE_LOCALVERFCNFILEDIR, subst_octave_home(), and Vlocal_ver_fcn_file_dir.

Referenced by install_defaults().

static void set_default_local_ver_oct_file_dir ( void  )
static

Definition at line 174 of file defaults.cc.

References OCTAVE_LOCALVEROCTFILEDIR, subst_octave_home(), and Vlocal_ver_oct_file_dir.

Referenced by install_defaults().

static void set_default_oct_etc_dir ( void  )
static

Definition at line 222 of file defaults.cc.

References OCTAVE_OCTETCDIR, subst_octave_home(), and Voct_etc_dir.

Referenced by install_defaults().

static void set_default_oct_file_dir ( void  )
static

Definition at line 234 of file defaults.cc.

References OCTAVE_OCTFILEDIR, subst_octave_home(), and Voct_file_dir.

Referenced by install_defaults().

static void set_default_oct_locale_dir ( void  )
static

Definition at line 228 of file defaults.cc.

References OCTAVE_OCTLOCALEDIR, subst_octave_home(), and Voct_locale_dir.

Referenced by install_defaults().

static void set_default_texi_macros_file ( void  )
static
void set_exec_path ( const std::string &  path_arg)
void set_image_path ( const std::string &  path)
static void set_local_site_defaults_file ( void  )
static
static void set_octave_home ( void  )
static

Definition at line 124 of file defaults.cc.

References octave_env::getenv(), OCTAVE_PREFIX, and Voctave_home.

Referenced by install_defaults().

static void set_site_defaults_file ( void  )
static
std::string subst_octave_home ( const std::string &  s)

Definition at line 100 of file defaults.cc.

References file_ops::dir_sep_char(), OCTAVE_PREFIX, replace(), and Voctave_home.

Variable Documentation

std::string Varch_lib_dir

Definition at line 64 of file defaults.cc.

Referenced by set_default_arch_lib_dir(), and set_exec_path().

std::string Vbin_dir

Definition at line 60 of file defaults.cc.

Referenced by set_default_bin_dir(), and set_exec_path().

std::string Vbuilt_in_docstrings_file

Definition at line 97 of file defaults.cc.

Referenced by install_built_in_docstrings(), and set_built_in_docstrings_file().

std::string Vdata_dir

Definition at line 62 of file defaults.cc.

Referenced by set_default_data_dir().

std::string VEDITOR

Definition at line 90 of file defaults.cc.

Referenced by do_edit_history(), and set_default_editor().

std::string VEXEC_PATH
static

Definition at line 87 of file defaults.cc.

Referenced by FEXEC_PATH(), and set_exec_path().

std::string Vfcn_file_dir
std::string Vimage_dir

Definition at line 83 of file defaults.cc.

Referenced by set_default_image_dir(), and set_image_path().

std::string VIMAGE_PATH
static

Definition at line 92 of file defaults.cc.

Referenced by set_image_path().

std::string Vinfo_dir

Definition at line 61 of file defaults.cc.

Referenced by set_default_info_dir().

std::string Vlibexec_dir

Definition at line 63 of file defaults.cc.

Referenced by set_default_libexec_dir().

std::string Vlocal_api_arch_lib_dir

Definition at line 66 of file defaults.cc.

Referenced by set_default_local_api_arch_lib_dir(), and set_exec_path().

std::string Vlocal_api_fcn_file_dir

Definition at line 74 of file defaults.cc.

Referenced by load_path::do_initialize(), and set_default_local_api_fcn_file_dir().

std::string Vlocal_api_oct_file_dir

Definition at line 70 of file defaults.cc.

Referenced by load_path::do_initialize(), and set_default_local_api_oct_file_dir().

std::string Vlocal_arch_lib_dir

Definition at line 65 of file defaults.cc.

Referenced by set_default_local_arch_lib_dir(), and set_exec_path().

std::string Vlocal_fcn_file_dir

Definition at line 75 of file defaults.cc.

Referenced by load_path::do_initialize(), and set_default_local_fcn_file_dir().

std::string Vlocal_oct_file_dir

Definition at line 71 of file defaults.cc.

Referenced by load_path::do_initialize(), and set_default_local_oct_file_dir().

std::string Vlocal_site_defaults_file

Definition at line 94 of file defaults.cc.

Referenced by execute_startup_files(), and set_local_site_defaults_file().

std::string Vlocal_ver_arch_lib_dir

Definition at line 67 of file defaults.cc.

Referenced by set_default_local_ver_arch_lib_dir(), and set_exec_path().

std::string Vlocal_ver_fcn_file_dir

Definition at line 73 of file defaults.cc.

Referenced by load_path::do_initialize(), and set_default_local_ver_fcn_file_dir().

std::string Vlocal_ver_oct_file_dir

Definition at line 69 of file defaults.cc.

Referenced by load_path::do_initialize(), and set_default_local_ver_oct_file_dir().

std::string Voct_etc_dir
std::string Voct_file_dir
std::string Voct_locale_dir
std::string Voctave_home

Definition at line 58 of file defaults.cc.

Referenced by FOCTAVE_HOME(), set_octave_home(), and subst_octave_home().

std::string Vsite_defaults_file

Definition at line 95 of file defaults.cc.

Referenced by execute_startup_files(), and set_site_defaults_file().