Date: Wed, 09 Sep 1998 22:29:45 -0700 From: John Polstra <jdp@polstra.com> To: sprice@hiwaay.net Cc: current@FreeBSD.ORG Subject: Re: XFree86 and ELF (beating a dead horse) Message-ID: <199809100529.WAA27838@austin.polstra.com> In-Reply-To: <Pine.OSF.4.02.9809092011260.12979-100000@fly.HiWAAY.net> References: <Pine.OSF.4.02.9809092011260.12979-100000@fly.HiWAAY.net>
next in thread | previous in thread | raw e-mail | index | archive | help
In article <Pine.OSF.4.02.9809092011260.12979-100000@fly.HiWAAY.net>, Steve Price <sprice@hiwaay.net> wrote: > > Just to followup on my own mail, all of the > "undefined reference" errors that I am seeing > seem to all be from .s files. It seems it is > looking for 'symbol' and as(1) is outputting > '_symbol'. That's because with a.out, a C variable "foo" is called "_foo" in assembler. But with ELF, it is called just plain "foo". So when you reference a C symbol from assembly language, it has to be handled differently depending on the object file format. This needs to be solved using either the CNAME/HIDENAME macros from <machine/asmacros.h>, or using #defines as in <machine/asnames.h>. John -- John Polstra jdp@polstra.com John D. Polstra & Co., Inc. Seattle, Washington USA "Self-knowledge is always bad news." -- John Barth To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199809100529.WAA27838>