ODBC Server Reference Manual
HP NonStop ODBC Server Reference Manual—429151-002
9-1
9 UNIX Notes
This section contains the environment-specific information on using DB-LIBRARY in 
the UNIX environment.
The Microsoft SQL Server Programmer’s Reference describes DB-LIBRARY and lists 
DB-LIBRARY commands and routines for DOS-based and OS/2-based SQL Server. 
This section contains more information for UNIX users. It covers the following topics:
•
Building an executable
•
DB-LIBRARY functions and macros 
Building an Executable
The syntax of the command to compile and link a DB-LIBRARY application is: 
The preceding command assumes that the DB-LIBRARY include files and the Sybase 
library libsybdb.a reside in the directories in which they were initially installed. If 
these files have been moved to standard UNIX library and include directories, the 
command is simpler: 
Note that DB-LIBRARY applications must link with the math library, libm.a, which is 
invoked with the -lm flag.
DB-LIBRARY Functions and Macros
The Microsoft SQL Server Programmer’s Reference lists DB-LIBRARY functions and 
macros for DOS-based and OS/2-based SQL Server. UNIX users can use the 
additional functions and macros described in Table 9-1.
Note. If you are using SQL Server documentation from Sybase, you can use the Sybase 
manuals—you do not need the Microsoft manuals or the information in this section.
cc program.c -I$SYBASE/include $SYBASE/lib/libsybdb.a -lm -o 
program
cc program.c -lsybdb -lm -o program










