HP-UX SNAplus2 MS Programmer's Guide
Writing MS Applications
Compiling and Linking the MS Application
Chapter 2 47
Compiling and Linking the MS Application
Applications are compiled with different options in order to select one of
the scheduling modes described in “Scheduling Asynchronous Events”.
NOTE Applications that use asynchronous API callbacks must eitherbe built as
multithreaded applications or include support for the application
scheduled mode. Motif applications must include the code fragment
described in “Motif Applications”.
Applications linked with previous versions of SNAplus2 that used
signal-based scheduling mode provided by the library, libmgr.sl, will
continue to work in the current version of SNAplus2. However, this
library is provided only for back-compatibility. New applications should
not use this library.
When compiling your MS application, specify the following option to
indicate to the compiler which directory contains the SNAplus2 header
files your application requires:
-I /usr
When linking your MS application, use the following options:
-L
Indicates the directory containing one or more libraries
to be used when linking the application.
-l
Indicates the name of a library to be used when linking
the application.
The command you use to link the application depends on which type of
application it is, as described below.
Back Level Applications
New applications will use dynamic libraries in /opt/sna/lib/hpux32 or
/opt/sna/lib/hpux64 as described above. SNAplus2 release 6.2 also
includes a set of dynamic libraries to support existing applications that