libsunmath is a library that is included with the Sun compilers in both static and dynamic formats.
I've been told that with C99 and the new libm functions, there are very few reasons to be using libsunmath anymore. I'd love to have feedback from libsunmath users on whether this might be true or not. In the compiler team we're discussing the current behavior of the C compiler when using -lsunmath. The C compiler differs from the C++ and Fortran compilers in that it doesn't automatically add -R/opt/.../lib all the time. Because of that it has special behavior so that libsunmath is linked statically, even when no -Bstatic was supplied. Things we could do (not mutually exclusive): 1. Add -library=sunmath (which lets us turn on RPATH) 2. Work towards EOL of libsunmath 3. remove special behavior of C compiler, this requires libsunmath users to use -Bstatic with -lsunmath. This would be an incompatible change. However, if the change happens, the new options would work with the old compiler (this has been an issue in the past). Note: By the way, we're looking for the background on the thou-must-not-add-RPATH-all-the-time edict. Any pointers would be appreciated. I didn't get very far by scanning the ARC cases. (If anyone inside Sun knows of a full-text index of ARC cases, please let me know. Note: libsunperf has a similar problem, and we're planning to add -library=sunperf. But we don't currently document -lsunperf as a supported way of using sunperf, only -library=sunperf (currently for Fortran and C++). So we don't have compatibility concerns for -lsunperf.
