DataBlade client applications
You can compile and link a DataBlade client application with the HCL Informix® GLS libraries.
For information about how to write and compile DataBlade client applications, see the IBM® Informix DataBlade API Programmer's Guide.
You must specify the location of the Informix GLS header file, ifxgls.h. This header file is located in %INFORMIXDIR%\incl\public for Windows and in $INFORMIXDIR/incl/public for UNIX.
This directory also contains many of the other files that a DataBlade client application uses. Therefore, it is an important directory to include when you compile the application.
cl -MD -Id:\msdev\include -Id:\informix\incl\public -Id:\informix\incl\esql \
-Id:\informix\incl -c sample.c
At link time (in lib subdirectory of INFORMIXDIR) | At run time (in bin subdirectory of INFORMIXDIR) | Purpose |
---|---|---|
libthdmi.lib | idmit09a.dll | DataBlade API functions |
isqlt09a.lib | isqlt09a.dll | ESQL/C functions |
cc -I$INFORMIXDIR/incl/public -I$INFORMIXDIR/esql -I$INFORMIXDIR/incl -c sample.c
The preceding command checks to see whether the API client libraries have been installed in the directory that the INFORMIXDIR environment variable indicates.
- For the library location, use the following -L compiler option: -L$INFORMIXDIR/lib/esql
- For the library name, include the -lifgls command-line option.
cc -o sample sample.o \
-L$INFORMIXDIR/lib/esql -L$INFORMIXDIR/lib/dmi -L$INFORMIXDIR/lib \
-lifdmi -lifsql -lifasf -lifcss -lifos -lifgen -lifgls -lifglx \
-lnsl -lsocket -laio -lm -ldl -lelf -lw \
$INFORMIXDIR/lib/esql/checkapi.o
esql -o sample sample.o -L$INFORMIXDIR/lib/dmi -ldmi