Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Compiling / Linking error in Solaris Studio 12.3 C++ Compiler

977823Dec 4 2012 — edited Jan 9 2013
Hi,

I downloaded Solaris Studio 12.3 (SolarisStudio12.3-solaris-x86-pkg.tar.bz2) & unpacked and installed on the default directory (in non-interactive mode) of local machine running Solaris 10 10/09 s10x_u8wos_08a X86. Also applied all the required patches by running the "install_patches.sh" after running "solarisstudio.sh".

My application has make files to take care of the building the whole application. I made necessary changes to the make files to pick up the latest Solaris 12.3 C++ compiler. I could see that it has picked up for compiling.

While building the whole project, the source files are compiled to object files successfully but when it is creating shared object (.so) files it stops at the below error:

/opt/solarisstudio12.3/prod/bin/CC -mt -i -library=stlport4 -zdefs -ztext -G -h xmem.so -Lpic/lib/debug/sol32 -L/MyHome/open_source/abc/lib/sol32 -L/MyHome/open_source/mno/lib/sol32 -L/MyHome/open_source/pqr/lib/sol32 -L/MyHome/open_source/xyz/lib/sol32 -g -lc -lCrun -lumem -m32 -o debug/xmem.so

*usage: CC [ options ] files. Use 'CC -flags' for details*

Note:
Some third party open source libraries are being used in the project. Those libraries are not built using Solaris Studio 12.3 compilers.

Tried changing lot of options and re-ordering the switches/options but no luck. But on changing as mentioned below the shared library DID build successfully
- Added space after '-L' option, added '*' at the end of path like "-L/MyHome/open_source/pqr/lib/sol32/*".

Note:*_
+1) I tried compiling a separate small program into object files using Solaris 12.3 C++ compiler but got the above error/problem when linking the experimental libraries (shared object) with most of the options used in the above command.+

+2) The same project gets built successfully in Solaris Studio 12.1 (studio12.1-091123) and Solaris Studio 12 (studio12-070724) but the same is failing in Solaris Studio 12.3.+

Can someone please help me to understand the issue and resolve it? Let me know if any more information is needed.

Thanks in advance.

-Vijay

Edited by: 974820 on Dec 4, 2012 7:05 PM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 6 2013
Added on Dec 4 2012
10 comments
2,485 views