next up previous contents index
Next: The System and its Up: System Description Previous: System Description   Contents   Index

Entering and Exiting XSB

After the system has been installed, the emulator's executable code appears in the file:


                     $XSB_DIR/bin/xsb
or, if, after being built, XSB is later installed at a central location, $SHARED_XSB.

                     $SHARED_XSB/bin/xsb
and indeed, using this command, invokes XSB's top level interpreter which is the usual way of using XSB

Version 2.2 of XSB can also directly execute object code files from the command line interface. Suppose you have a top-level routine go in a file foo.P that you would like to run from the UNIX or Windows command line. As long as foo.P contains a directive :- go., and foo has been compiled to an object file ( foo.O), then


                       $XSB_DIR/bin/xsb -B foo.O
will execute go, loading the appropriate files as needed. In fact the command $XSB_DIR/bin/xsb is equivalent to the command:

             $XSB_DIR/bin/xsb -B $XSB_DIR/syslib/loader.O

There are several ways to exit XSB. A user may issue the command halt. or end_of_file, or simply type CTRL-d at the XSB prompt. To interrupt XSB while it is executing a query, strike CTRL-c.


next up previous contents index
Next: The System and its Up: System Description Previous: System Description   Contents   Index
Baoqiu Cui
2000-04-23