The run–time library locator is the default; it can be selected
explicitly with the command line option --library-locator
run-time or by setting the parameter current-library-locator to
run-time-library-locator; it is meant to be used by an
installation of Vicare to run applications. The reference
scenario for the run–time library locator is this:
(library-binary-search-path) ⇒ (... "/usr/local/lib/vicare-scheme" ...)
(current-library-binary-search-path-scanner default-library-binary-search-path-scanner)
which will scan the search path returned by
(library-binary-search-path).
(import (vicare) (prefix (vicare posix) px.) (vicare something))
and we execute it selecting the run–time library locator:
$ vicare --library-locator run-time --r6rs-script demo.sps
the command line option --library-locator will put
run-time-library-locator in the parameter
current-library-locator.
the result is that Vicare will search the binary libraries search path for library files.
The following bindings are exported by the library (vicare
libraries).
Possible value for the parameter current-library-locator; this
function is meant to be used to search for libraries when running an
application.
Given a R6RS library reference: return a thunk to be used to start the search for a matching library. The returned thunk scans the search path for compiled libraries in search of a matching binary file; if a matching compiled library is not found: it scans the search path for source libraries in search of a matching source file.
When successful the returned thunk returns 2 values:
When no matching library is found: the returned thunk returns #f
and #f.