Web Oriented Object Framework

User Guide (Version 0.5b4)

User Guide (Version 0.5b4)

Loading packages

Because it runs in safe mode, the Woof! application interpreter is restricted in terms of the areas of the file system it can read from. By default, the interpreter can only read from the app and public subdirectories in the Woof! tree. In addition, the lib directory can be read during start-up but not subsequently once Woof! itself is loaded.

Consequently, any package require or source commands in your application code will fail.

To get your packages to load, you need to configure Woof! to allow files to be read from the directories where your libraries are stored. This is done by setting the variable lib_dirs in the configuration file to a list of directories that should be accessible. Note that the entire subdirectory tree below these directories will also be accessible. Note that the directories app lib do not need to be listed as they are included by default.

For example,

set lib_dirs [list /usr/lib/tcl /usr/local/lib/tcl]

will allow any packages under those directories to be read. Generally, it would be wise to list only the directories containing the specific packages you want to load, or to place all required packages under a specific directory and include that in the list.