Rogue Wave banner
Previous fileTop of DocumentContentsNext file

3.2 Setting Environment Variables

You must properly define all compiler-specific and database-specific environment variables and system settings before building the DBTools.h++ libraries.

Table 10 lists an environment variable for each of the DBTools.h++ access libraries and describes the typical settings required. The rest of this section provides operating system-specific instructions for setting the variables.

Table 10 -- Environment variables 

 
DatabaseVariable NameNotes
Informix
INFORMIXDIR
Set the variable to the path in which Informix is installed.
MS SQL Server
SQLSERVER
(Windows only) Set the variable to the path in which MS SQL is installed.
DB2 CLI
DB2DIR
Set the variable to the path in which DB2 CLI is installed.
ODBC
ODBC
Set the variable to the path in which the ODBC library and header files are installed.
MSVC users: Simply set this variable to the VC98 directory.
Oracle
ORACLE on Windows,
ORACLE_HOME on UNIX
Set the variable to the path in which Oracle is installed.
Oracle8
ORACLE on Windows,
ORACLE_HOME on UNIX
Set the variable to the path in which Oracle is installed.
Sybase CT Library
SYBASE
Set the variable to the path in which CT Library is installed.

3.2.1 Setting Environment Variables in Windows 95

The environment variables can be set in your autoexec.bat file, by using the SET directive followed by the variable name for your database (from Table 10), an equal sign, ("="), and the name of the drive and directory that contains the header files and libraries. For example, to point to the Sybase Client-Library directory, include the following in your autoexec.bat file:

Including environment variables in your autoexec.bat file allows you to indicate the location of more than one database. You will need to reboot for the changes to autoexec.bat to take effect.

3.2.2 Setting Environment Variables in Windows NT

The environment variables can be set in the Windows NT system registry, by using the following procedure:

  1. Open the Control Panel window, and double click on the System icon.

  2. Move the cursor to the box labeled User Environment Variables. Click on one of the existing variables. The variable name and its value will appear in separate fields near the bottom of the screen.

  3. Enter or append the variables and values listed in Table 11, clicking on the Set button after entering each value.

    Be sure to append information to the include and lib values that are already set in the system registry.

  4. After entering the environment variables, click on OK.

  5. The variables that you set will not apply to any running programs, including SPM. Quit and restart SPM before compiling.

    Table 11 -- Windows NT environment variables1 

     
    VariableValue
    <environment_variable_name>
    <drive>:\<directory path>
    Table 10 lists possible <environment_variable_name> values.
    include
    Append the name of the drive and directory that contains the header files for your database to the existing include path. Do not replace the value that appears in the registry.
    MSVC users: The include path for ODBC is already entered if you are using MSVC.
    lib
    Append the name of the drive and directory that contains the libraries for your database to the existing lib path. Do not replace the value that appears in the registry.
    MSVC users: The lib path for ODBC is already in place if you are using MSVC.
    1If your environment variables are already set for some other version of the same product, you may need to delete those references, or prepend the new data..

3.2.3 Setting Environment Variables in UNIX

If you are working in a Korn or a Bourne shell, use export to set the environment variable. Refer to Table 10 for the variable you must set for your database. For example, to set the variable for the Informix database, you might use something like the following:

If you are running in other than a Bourne or Korn shell, you may be able to use setenv, as in the following:

3.2.4 Notes to Linux Users

Before using SPM to build products on Linux, please check these two requirements:

Be sure to check our knowledge base at support.roguewave.com for updated requirements and additional information about Rogue Wave products.


Previous fileTop of DocumentContentsNext file

©Copyright 2000, Rogue Wave Software, Inc.
Contact Rogue Wave about documentation or support issues.