Sun WorkShop Compiler C 5.0 User's Guide

-B[static|dynamic]

Specifies whether bindings of libraries for linking are static or dynamic, indicating whether libraries are non-shared or shared, respectively.

-Bdynamic causes the link editor to look for files named libx.so and then for files named libx.a when given the -lx option.

-Bstatic causes the link editor to look only for files named libx.a. This option may be specified multiple times on the command line as a toggle. This option and its argument are passed to ld.


Note -

Many system libraries, such as libc, are only available as dynamic libraries in the Solaris 7 64-bit compilation environment. Therefore, do not use -Bstatic as the last toggle on the command line.