LDB Installation

The system has been tested on Solaris 2.6 and 2.7, and on Red Hat Linux 6.2, 7.1, 7.2, 7.3, 8.0, and 9.0. LDB is built on top of SHORE 3.0, which supports the solaris/sparc, solaris/intel, windowsNT/intel, linux/intel, and NetBSD/intel platforms. It also uses the gc garbage collector, which supports most platforms. You will also need: gcc, g++, make, flex, bison, ar, awk (for rpcgen), wish (for VOODOO), and javac (for the Java binding).

Installing the SHORE 3.0 Interim Snapshot Release

You can download SHORE 3.0 Interim Release from ftp://ftp.cs.wisc.edu/shore/interim/. Please read README.BUILD for more information. After you successfully compile SHORE, use make install to install the files in the shore-interim-3/installed directory.

For example, for Red Hat Linux 8.0 or 9.0, you add the lines:

#define GCC_VER_3_WARNINGS
#define	FC_USE_FORM
#define OPTIMIZE ON
to the file conf/linux_generic.def and you do:
make DIR_SCHEME_FILE=linux_generic.def build_shore_only
make install
For example, for Solaris 2.7 with gcc 2.95.* you add the line:
PERL_DIR = /usr/local
to the file conf/solaris_generic.def and you do:
make DIR_SCHEME_FILE=solaris_generic.def build_shore_only
make install

Installing the GC Garbage Collector

Download the GC garbage collector and use:

tar xfz gc.tar.gz
to extract the files. Then go to the installed directory (gc*) and change the top lines of the Makefile to CC=gcc, CXX=g++, and
CFLAGS= -O -I$(srcdir)/include -DNO_SIGNALS -DALL_INTERIOR_POINTERS -DSILENT -DATOMIC_UNCOLLECTABLE -DREDIRECT_MALLOC=GC_malloc_uncollectable
and execute make and make c++ to install the C and C++ garbage collectors.

Installing LDB

Installation step:

  1. Download the latest LDB source distribution in your home directory and extract the files using:
    tar xfz ldb.tar.gz
    
    This will create a directory ldb and will extract the files inside.

  2. Go to the ldb directory and change the file ldb.include to point to your local directories.

  3. Execute make to build the LDB executables.
After installing and testing the executables, you may use make clean to remove all intermediate build files, keeping only the executables and libraries. The command make distclean will also remove all executables and libraries.

Testing the Installation

Let $(LDB) be the ldb directory. First, create the database store in some directory using:

mkdir ldbstore
mkdir ldbstore/log
and change the file $(LDB)/ldbconfig accordingly. Go to the $(LDB)/examples/school directory and do the following:
make build            # initialize the user database and catalogs (answer 'y' to the question)
make                  # compile school.odl to build the school schema and populate the database
make query            # compile query.oql which contains one statically- and one dynamically-compiled OQL query
./query               # execute the query against the School database
Optional step: extensive test of the system by compiling and executing over 40 static and 40 dynamic OQL queries:
make test             # compile test.oql which contains over 80 OQL queries
./test                # execute the queries against the School database

To test the C++/Java bindings through RPCs (Remote Procedure Calls), you must start the server in a separate window:

$(LDB)/bin/server
Then, you can do the following at the $(LDB)/examples/school directory:
make C++_client       # compile and run a test file that uses the C++ binding
make Java_client      # compile and run a test file that uses the Java binding
With the server runing, you can use the tcl script
$(LDB)/bin/oql.tcl School
to evaluate ad-hoc OQL queries against the School database. To test the VOODOO interface, run
$(LDB)/bin/voodoo.tcl School
The directory $(LDB)/examples/java is completely done in Java. To compile it, use make build to clear the database, start the server in a separate window, and use make to compile the schema, populate the database, and run some simple queries and updates.


Last modified: 01/12/04 by Leonidas Fegaras