Solaris Common Messages and Troubleshooting Guide

/usr/ucb/cc: language optional software package not installed

Cause

When compiling some code for BSD compatibility the error happened after invoking usr/ucb/cc. The unbundled compiler (SPARCworks Professional C product) was installed in /opt.

/usr/ucb/cc is a script which checks for the file /usr/ccs/bin/ucbcc and, if found, invokes it with appropriate library flags for BSD-compatibility compilation.

/usr/ucb/cc is part of the package SUNWscpu. /usr/ccs/bin/ucbcc is supposed to be a symbolic link to /opt/SUNWspro/bin/acc, which is created during installation of the unbundled C compiler, SPROcc.

Action

Verify that you have the essential OS-bundled Developer packages, SUNWscpu, SUNWbtool, and the unbundled C compiler:- SPROcc. However, /usr/ccs/bin/ucbcc was missing on customer's system. Evidently somewhere along the line this link was removed.

Solve the problem by creating a new symbolic link:


   # ln -s /opt/SUNWspro/bin/acc /usr/ccs/bin/ucbcc
Invoke usr/ucb/cc to verify this worked.

Commands used to identify which packages contain particular components involved:


craterlake% grep ucb/cc /var/sadm/install/contents
/usr/ucb/cc f none 0555 bin bin 3084 50323 814621113 *SUNWscpu
craterlake% ls -l /usr/ucb/cc
-r-xr-xr-x   1 bin      bin         3084 Oct 25  1995 /usr/ucb/cc
craterlake% file !$
file /usr/ucb/cc
/usr/ucb/cc:    executable /usr/bin/sh script
craterlake% grep ucbcc /var/sadm/install/contents
/usr/ccs/bin/ucbcc=/opt1/40/SUNWspro/SC4.0/bin/acc s none SPROcc SPROcc.2 SPROcc.5
craterlake% file /usr/ccs/bin/ucbcc
/usr/ccs/bin/ucbcc:     ELF 32-bit MSB executable SPARC Version 1, dynamically linked, stripped
craterlake% ls -l /usr/ccs/bin/ucbcc
lrwxrwxrwx   1 root     other         31 Aug 23  1996 /usr/ccs/bin/ucbcc -> /opt1/40/SUNWspro/SC4.0/bin/acc