STREAMS/UX for the HP 9000 Reference Manual
105
How to Compile and Link STREAMS/UX Drivers, Modules, and Applications
Compiling STREAMS/UX Drivers and Modules
Compiling STREAMS/UX Drivers and Modules
The steps for compiling STREAMS/UX drivers and modules follow.
1 Include the appropriate STREAMS/UX include files in the driver and module
sources. Table 2 describes the files. Drivers and modules are compiled in the
/usr/conf directory. They contain include statements with relative path names.
The table shows the path names.
2 If you are only adding modules, you will need to archive those modules into a
library.
3 Compile the sources in /usr/conf with the appropriate options. Create a directory
under /etc/conf and place your source files in this directory. Use the following
command line with appropriate substitutions to compile your source code.
@${CC} -I. -c ${CFLAGS} ${NOGLOOPTS} $(your_file).c
Table 2 STREAMS/UX and TPI Include Files
Include File Use
“../h/stream.h” Needed by all drivers and modules.
“../h/stropts.h” Needed by all drivers and modules.
“../h/strlog.h”
Needed by drivers and modules that call strlog. Note that
log.h and syslog.h are not needed. STREAMS/UX does not
support priority and facility codes.
“../h/strstat.h”
Needed by drivers and modules that use the qi_mstat field of
the qinit structure to maintain statistics.
“../h/strenv.h” Needed by drivers and modules that use DKI functions.
“../h/cmn_err.h” Needed by drivers and modules that use cmn_err().
“../h/tihdr.h” Needed by drivers and modules that use TPI.