Re: collect2: ld returned 8 exit status
- From: "Christian Meier" <chris@xxxxxxxxxxx>
- Date: Fri, 18 Jan 2008 17:25:07 +0100
"Huub" <"v.niekerk at hccnet.nl"> schrieb im Newsbeitrag
news:47909572$0$26965$e4fe514c@xxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi,
Running AIX 5.3, I'm trying to compile a short piece of code in C++:
#include <iostream>
using namespace std;
int main()
{
cout << "Dit is AIX 5.3 - C++\n";
}
Compilation:
$ g++ test.cpp -o testcpp
ld: 0711-317 ERROR: Undefined symbol: .std::basic_ostream<char,
std::char_traits<char> >& std::operator<< <std::char_traits<char>
(std::basic_ostream<char, std::char_traits<char> >&, char const*)ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more
information.
collect2: ld returned 8 exit status
$
Hi
I had the same problem a few days ago. After some research I decided to
upgrade the gcc version.
IIRC there is a workarround for the problem. But it is has one or more
disadvantages. You can find the solution, if you google for it.
Trying with the suggested options:
$ g++ -bnoqiuet test.cpp -o testcpp
g++: couldn't run 'noqiuet-gcc-4.0.0': No such file or directory
$ g++ -bloadmap test.cpp -o testcpp
g++: couldn't run 'loadmap-gcc-4.0.0': No such file or directory
$ g++ test.cpp -bnoquiet -o testcpp
g++: '-b' must come at the start of the command line
Any clues on how to get on?
Thanks.
1. There is a typo.
2. -bnoquiet and -bloadmap are linker options. You have to use it like
"g++ -Wl,-bnoquiet test.cpp -o testcpp".
Regards, Chris
.
- Follow-Ups:
- Re: collect2: ld returned 8 exit status
- From: Huub
- Re: collect2: ld returned 8 exit status
- From: Huub
- Re: collect2: ld returned 8 exit status
- References:
- collect2: ld returned 8 exit status
- From: Huub
- collect2: ld returned 8 exit status
- Prev by Date: Re: ld: 0711-780 SEVERE ERROR
- Next by Date: Re: not possible to create mksysb dvd
- Previous by thread: collect2: ld returned 8 exit status
- Next by thread: Re: collect2: ld returned 8 exit status
- Index(es):
Relevant Pages
|
|