[openbeos] Re: Assembler and BeOS (tool chain question)

  • From: "Axel Dörfler" <axeld@xxxxxxxxxxxxxxxx>
  • To: openbeos@xxxxxxxxxxxxx
  • Date: Sun, 21 Jan 2007 13:07:53 +0100 (MET)

"Zenja Solaja" <solaja@xxxxxxxxx> wrote:
> However, if I manually assemble and link the program, the executable 
> doesn't
> work.
> (~/develop/example)> as -o example.o example.s
> (~/develop/example)> ld -o example example.o -e main -lroot
> (the -e main argument instructs linker to search for main instead of 
> _start)
> When executed, I get a segment violation error under Zeta 1.2.

Which will circumvent the usual startup procedure from that crti/n/
begin/end.o stuff.
If you want to use public library functions, you must link against 
those, just like GCC does for you automatically.


Other related posts: