Customizing library paths and path aliases
Author(s): Daniel Cabeza.
This library provides means for customizing, from environment variables, the libraries and path aliases known by an executable. Many applications of Ciao, including ciaoc, ciaosh, and ciao-shell make use of this library. Note that if an executable is created dynamic, it will try to load its components at startup, before the procedures of this module can be invoked, so in this case all the components should be in standard locations.
Usage and interface
- Library usage:
:- use_module(library(libpaths)). - Exports:
- Predicates:
get_alias_path/0. - Multifiles:
file_search_path/2, library_directory/1.
- Predicates:
- Imports:
- System library modules:
system, lists. - Packages:
prelude, nonpure, assertions.
- System library modules:
Documentation on exports
Consult the environment variable 'CIAOALIASPATH' and add facts to predicates library_directory/1 and file_search_path/2 to define new library paths and path aliases. The format of 'CIAOALIASPATH' is a sequence of paths or alias assignments separated by colons, an alias assignment is the name of the alias, an '=' and the path represented by that alias (no blanks allowed). For example, given
CIAOALIASPATH=/home/bardo/ciao:contrib=/usr/local/lib/ciaothe predicate will define /home/bardo/ciao as a library path and /usr/local/lib/ciao as the path represented by 'contrib'.
Documentation on multifiles
The predicate is of type dynamic.
Trust:file_search_path(X,Y)
- The following properties hold upon exit:
(basic_props:gnd/1)X is ground.
(basic_props:gnd/1)Y is ground.
The predicate is of type dynamic.
Trust:library_directory(X)
- The following properties hold upon exit:
(basic_props:gnd/1)X is ground.