problem compiling c++ programs with g++-4.0

Post here about scripting and programming for HaloPC (audio, network, ai, etc.)
Post Reply
User avatar
[cc]z@nd!




Literarian 500

Posts: 2297
Joined: Tue May 04, 2004 1:52 pm
Location: michigan

problem compiling c++ programs with g++-4.0

Post by [cc]z@nd! »

i'm not sure if you guys could help me here, but nowhere else has been able to. anyways, so i'd like to program some on this ubuntu pc i have. it's an old distro (breezy badger) so i personally think that's where my problem might be, but i don't see a reason why this isn't working...

anyways, here it is:

Code: Select all

zandi@pavilion:~$ cat test.cpp
//g++ test
//because i couldn't compile source code i wrote with dev-cpp using g++-4.0

int main()
{
    return(0);
}
zandi@pavilion:~$ g++-4.0 test.cpp
/usr/bin/ld: crt1.o: No such file: No such file or directory
collect2: ld returned 1 exit status
zandi@pavilion:~$ argh......
there you see my simple program, no includes or anything. and the file it says doesn't exist has a 1 in it, not an L. i used synaptic to get g++-4.0, so i guess i'll try installing g++ and using it instead and see if that works... also, i have all the libraries i need, the only one synaptic shows that i don't have is some snmp one. anyways, i'll investigate it a bit on my own, but tell me if you guys have any solutions.

btw, should this be in tech questions, or here in programming?
ASPARTAME: in your diet soda and artificial sweeteners. also, it's obviously completely safe. it's not like it will cause tumors or anything. >.>
always remember: guilty until proven innocent
Post Reply