README for the HP Neoview UNIX Drivers (R2.3)
2. Compile the sample program.
Note: All drivers, other than the 64-bit driver for HP-UX(IA-64) and
the x86_64 Linux driver, are 32-bit drivers; therefore, applications
need to be compiled accordingly.
o On Linux:
gcc connect_test.cpp -L/usr/lib -I/usr/include/hpodbc -lhpodbc \
-o connect_test
Note: The Linux driver is a 32-bit driver. If you are using an
x86-64 machine, you need to explicitly compile your appplication
as a 32-bit application. For example:
gcc connect_test.cpp -m32 -L/usr/lib \
-I/usr/include/hpodbc -lhpodbc -o connect_test
o On x86_64 Linux:
gcc connect_test.cpp -L/usr/lib -I/usr/include/hpodbc \
-lhpodbc64 -o connect_test
o On HP-UX (IA-64):
aCC -AA connect_test.cpp -L/usr/lib -I/usr/include/hpodbc \
-lhpodbc64 -o connect_test -lm
To use cc for compiling and linking:
o Rename connect_test.cpp to connect_test.c.
o Run this command:
cc connect_test.c -I/usr/include/hpodbc -L/usr/lib \
-lhpodbc lstd_v2 -lCsup -lunwind -lm -lhpodbc -o
connect_test
Note: When linking in the pthread library, it should be linked in
ahead of -lhpodbc.
o On HP-UX (IA-64) 64 bit:
aCC +DD64 -AA connect_test.cpp -L/usr/lib/hpux64
-I/usr/include/hpodbc \
-lhpodbc64 -o connect_test -lm
To use cc for compiling and linking:
o Rename connect_test.cpp to connect_test.c