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.
Database | Variable Name | Notes |
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. |
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:
SET SYBASE=c:\sybase
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.
The environment variables can be set in the Windows NT system registry, by using the following procedure:
Open the Control Panel window, and double click on the System icon.
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.
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.
After entering the environment variables, click on OK.
The variables that you set will not apply to any running programs, including SPM. Quit and restart SPM before compiling.
Variable | Value |
<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. |
1 | If 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.. |
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:
export INFORMIXDIR=/informix
If you are running in other than a Bourne or Korn shell, you may be able to use setenv, as in the following:
setenv INFORMIXDIR /informix
Before using SPM to build products on Linux, please check these two requirements:
The grep, sed, and dirname utilities must reside in /bin. If they don't, use whereis <file> to determine the location of any utility that is not in /bin, then run a symbolic link from <file> to /bin using:
ln -s <full path to file> /bin.
The ksh utility is required when using SPM to build Rogue Wave products. If your Linux installation does not include ksh, create a symbolic link from zsh-- a shell provided with most, if not all Linux distributions--to /bin/ksh, using:
ln -s /bin/zsh /bin/ksh
Be sure to check our knowledge base at support.roguewave.com for updated requirements and additional information about Rogue Wave products.
©Copyright 2000, Rogue Wave Software, Inc.
Contact Rogue Wave about documentation or support issues.