Totalview® for HPC Reference Guide : PART III Platforms and Operating Systems : Chapter 9 Platforms and Compilers : Linking with the dbfork Library : SunOS 5 SPARC
Add one of the following command line arguments or options to the command that you use to link your programs:
-L/opt/totalview/sun5/lib -ldbfork
For example:
cc -o program program.c \
             -L/opt/totalview/sun5/lib -ldbfork
As an alternative, you can set the LD_LIBRARY_PATH environment variable and omit the -L option on the command line:
setenv LD_LIBRARY_PATH /opt/totalview/sun5/lib