Mail Archives: djgpp/2006/05/23/14:46:31
Dr. Xiangdong Wang <xiangdong DOT wang AT charismathics DOT com> wrote:
> I can compile and link it with gxx
> gxx main.cpp
> but if I link it with ld,
> ld -lc -lstdcx -lsupcxx -lgcc main.o -o main.bin
But why would you want to do that?
Or, if you really have to, why don't you ask the one tool in your
hands that obviously already knows how to do it, to help you out?
That tool is GCC itself.
gxx -v main.cpp
should be enlightening.
Lesson learned: if you don't know exactly how ld has to be run to a
link a program for a given platform, don't even try. Let GCC handle
it.
--
Hans-Bernhard Broeker (broeker AT physik DOT rwth-aachen DOT de)
Even if all the snow were burnt, ashes would remain.
- Raw text -