LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Password
Solaris / OpenSolaris This forum is for the discussion of Solaris, OpenSolaris, OpenIndiana, and illumos.
General Sun, SunOS and Sparc related questions also go here. Any Solaris fork or distribution is welcome.

Notices


Reply
  Search this Thread
Old 06-02-2005, 05:58 AM   #1
murugesan
Member
 
Registered: May 2003
Location: Bangalore ,Karnataka, India, Asia, Earth, Solar system, milky way galaxy, black hole
Distribution: murugesan openssl
Posts: 181

Rep: Reputation: 29
"Multiple declaration for mbstate_t"


hi all,

I compiled a simple Cpp program on solaris. It was giving this error
Code:
"/usr/include/iso/wchar_iso.h", line 100: Error: Multiple declaration for mbstate_t.
"/opt/SUNWspro/SC5.0/include/CC/./iosfwd", line 51: Error: The name mbstate_t is ambiguous, std::mbstate_t and std::mbstate_t.
"/opt/SUNWspro/SC5.0/include/CC/./iosfwd", line 78: Error: The name mbstate_t is ambiguous, std::mbstate_t and std::mbstate_t.
"/opt/SUNWspro/SC5.0/include/CC/rw/iotraits", line 56: Error: The name mbstate_t is ambiguous, std::mbstate_t and std::mbstate_t.
By default it is taking the /usr/include/iso/wchar_iso.h for compiling. How can i override/remove default include path for compiling a program with CC.

Regards,
Murugesan
 
Old 06-02-2005, 01:01 PM   #2
technopark02
Member
 
Registered: Feb 2005
Distribution: Solaris 8 - 11, JDS Linux 3.0
Posts: 99

Rep: Reputation: 15
From the error message(s), I'm assuming that Workshop C++ compiler 5.0 is being used to compile the C++ program.

On Solaris 8 and prior versions, the patch 107311-10 or later must be installed, to compile the test case successfully.

Do the following:

1) Check for the patch:
showrev -p | grep 107311

2) Download and install, latest version of 107311 from sunsolve.sun.com.
(Direct URL: http://sunsolve.sun.com/pub-cgi/pdow...11-19&method=h)
 
Old 06-03-2005, 05:38 AM   #3
murugesan
Member
 
Registered: May 2003
Location: Bangalore ,Karnataka, India, Asia, Earth, Solar system, milky way galaxy, black hole
Distribution: murugesan openssl
Posts: 181

Original Poster
Rep: Reputation: 29
hi technopark02,

I found the work around.
CC -library=iostream a.C
gave me the solution


man CC
iostream
Use libiostream, the classic
iostreams library. (If using this value,
do not use Cstd)

anyhow thanks for the other soln.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
bash script: using "select" to show multi-word options? (like "option 1"/"o zidane_tribal Programming 7 12-19-2015 01:03 AM
what is "sticky bit mode" , "SUID" , "SGID" augustus123 Linux - General 10 08-03-2012 04:40 AM
Telling people to use "Google," to "RTFM," or "Use the search feature" Ausar General 77 03-21-2010 11:26 AM
"Xlib: extension "XFree86-DRI" missing on display ":0.0"." zaps Linux - Games 9 05-14-2007 03:07 PM
Can't install "glibmm" library. "configure" script can't find "sigc++-2.0&q kornerr Linux - General 4 05-10-2005 02:32 PM

LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris

All times are GMT -5. The time now is 07:18 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration