Linux Instructions for building Firebird from CVS

1. Introduction

This is the updated "howto" build the database from the firebird CVS tree.
Any mistakes, andthere are still likely to be a few are all mine...

Regards

Mark
 

2. What you need

    InterBaseSS_LI-V6.0.tar       - you need one running to build a new one.
    Interbase source                      - downloadable from firebird CVS tree (see later for details)
 

3.  Installing superserver interbase

    Before you can build interbase you need an existing running interbase.  This explains how to install the curent version.

Create an install directory and put download in it
    $mkdir /tmp/install
    $cp InterBaseSS_LI-V6.0.tar /tmp/install
    $cd /tmp/install
    $tar -xvf InterBaseSS_LI-V6.0.tar
This results in two files (InterBaseSS_LI-V6.0.tgz, install) in the current directory.  To do the install to /opt/interbase do the following.  I did this as root user
    $./install -s /tmp/install/InterBaseSS_LI-V6.0.tgz
The other options to install is -c which installs a classic interbase.  You need the full path to the .tgz file.  Also in the beta6.0 documentation it explains how to set it up as user 'interbase'.

I also tried to install it to /usr/local/interbase but that didn't work for two reasons 1. the error message db was stll expected from /opt/interbase/messages.gdb and 2. in was at nfs drive and when i ran the server it keep trying to connect to a server running on the machine that had the nfs drive.  Soo stay with /opt and make sure its a local drive.

Now to start the server

    $cd /opt/interbase/bin
    $./ibmgr -start -user SYSDBA -password masterkey
You should get some pleasant messages.  Then try it against one of the  test database.
    $/opt/interbase/bin
    $./isql  -user SYSDBA -password masterkey
    SQL>connect /opt/interbase/examples/employee.gdb;
    SQL>show tables;
    SQL>
 

3.  Extracting the source from CVS

        Create a work directory and move into it.
    $mkdir /tmp/build
     $cd /tmp/build
     Then check out the sources from the firebird CVS tree.  This is either:
        $export CVS_RSH=ssh
        $cvs -z3  -ddevelopername@cvs.firebird.sourceforge.net:/cvsroot/firebird co interbase

             If you are a developer, or

       $cvs -d:pserver:anonymous@cvs.firebird.sourceforge.net:/cvsroot/firebird login
       $cvs -z3  -d:pserver:anonymous@cvs.firebird.sourceforge.net:/cvsroot/firebird co interbase

    If you are not intenting to commit changes.
This creates a subdirectory InterBase with most of the source code.
 
4.  Install Reference databases
Build the reference databases used for compiling interbase.
      $cd /tmp/build/InterBase
      $sh builds/original/buildRefDatabases
It is important that this happens in the /tmp/build/Interbase directory.  It will build a directory /tmp/build/refDatabases which will contain all the required databases..
        Expect the error:
Use CONNECT or CREATE DATABASE to specify a database
Statement failed, SQLCODE = -902
I/O error for file "/tmp/build/InterBase/metadata.gdb"
-Error while trying to open file
-No such file or directory
Is OK, it's just trying to delete the database before creating a new one.
 
5.  Setting up the directories.
Interbase needs a number of symbolic links to databases/source,  and directories.
    $cd /tmp/build/InterBase
    $sh setup_dirs LINUX DEV /tmp/build/refDatabases
LINUX specifies the system, DEV could also be PROD if yoyu feel lucky, and the last parameter is where we have our reference databases.


6.  Building.

We are now ready to start building the database engine.  Change to the root directory and start the build.
    $cd /tmp/build/InterBase

    $build_kits builds SUPER
 

7.  Testing the build

You should now (some 4-10 minutes later) have a directory "/tmp/build/InterBase/interbase/" that contains the interbase binary distribution.

Testing the build basically means shutting down the current database, and starting up the one in the directory:


    /tmp/build/InterBase/interbase/bin
 

8.  Finding out more about the build

If you want to know more about the build have a look through the file "InterBase/builds/original/000_readme"
Some of this document will be a straight copy from there, also have a look at:
http://www.interbase2000.org/highlevelsource.htm
for an overview of the source directories.
 

Good Luck....

Mark