![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| High Level Programming Post questions about C, C++, Java, SQL, and other programming languages here. |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Not able to run gcc
Hi,
I am working with solaris 9(SunOS mgsun 5.9 Generic_112233-07 sun4u sparc SUNW,Sun-Blade-100).I install the gcc 3.4.6 from sunfreeware website and when I am trying to run it,I am getting the error-- # gcc ld.so.1: gcc: fatal: libiconv.so.2: open failed: No such file or directory Killed when I am trying to see that lib by # ldd /usr/local/bin/gcc libiconv.so.2 => (file not found) libc.so.1 => /usr/lib/libc.so.1 libdl.so.1 => /usr/lib/libdl.so.1 /usr/platform/SUNW,Sun-Blade-100/lib/libc_psr.so.1 so please let me know how can I solve this problem |
| Forum Sponsor | ||
|
|
|
#2
|
||||
|
||||
|
Set your LD_LIBRARY_PATH for /opt/csw/lib or something. Check the csw website for more instructions.
If it still doesn't work, you got to get the "Internationalization" libraries as well. These are used by a lot of GNU stuff, so there's probably a CSW package that you also have to install. (Could be they didn't check for the dependency). |
|
#3
|
|||
|
|||
|
You need to download and install the libiconv package. It is available on sunfreeware and elsewhere.
|
|
#4
|
|||
|
|||
|
fpmurphy's answer is correct. As stated in the sunfreeware listing for gcc 3.4.6, the libiconv package needs to be installed so that the libraries are in /usr/local/lib - which needs to be in your library path. The CSW packages have nothing to do with the sunfreeware ones and are not equivalent or used by any sunfreeware packages.
Feel free to email me directory with sunfreeware questions in the future. Steve Christensen Sunfreeware.com |
|
#5
|
||||
|
||||
|
Ooops. Indeed.
|
|
#6
|
|||
|
|||
|
I downloaded the libiconv and now I am able to compile the program..
Thanks a lot guys for helping me but now I am not able to run my program.I have a file test.cpp given below-- Code:
#include<iostream>
using namespace std;
int main()
{
cout<<"Welcome to the world of C++"<<endl;
return 0;
}
# gcc -c test.cpp -o test it is compiling the file and creating the binary file test.o but when I am running it,it is giving error-- # . ./test syntax error: `\3704' unexpected so please tell me why It's coming and how to resolve it Thanks in advance |
|
#7
|
|||
|
|||
|
Code:
#include<iostream>
using namespace std;
int main()
{
cout<<"Welcome to the world of C++"<<endl;
return 0;
}
You may want to space things out a little... Although I'm not 100% sure this is causing your problem. Code:
cout << "Welcome to the world of C++" << endl; |
|||
| Google The UNIX and Linux Forums |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|