public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Russell King <rmk+lkml@arm.linux.org.uk>
To: Andrew Morton <akpm@osdl.org>
Cc: azarah@nosferatu.za.org, trini@kernel.crashing.org,
	linux-kernel@vger.kernel.org, torvalds@osdl.org
Subject: Re: binutils woes
Date: Thu, 1 Jul 2004 23:22:07 +0100	[thread overview]
Message-ID: <20040701232207.H8389@flint.arm.linux.org.uk> (raw)
In-Reply-To: <20040701152134.7fd0fd1b.akpm@osdl.org>; from akpm@osdl.org on Thu, Jul 01, 2004 at 03:21:34PM -0700

On Thu, Jul 01, 2004 at 03:21:34PM -0700, Andrew Morton wrote:
> Russell King <rmk+lkml@arm.linux.org.uk> wrote:
> >
> > Essentially, we run 'nm' against the object, and look for any line
> > which matches the pattern '^ *U '.  With this, a failing output looks
> > like:
> > 
> >   LD      init/built-in.o
> >   LD      .tmp_vmlinux1
> > ldchk: .tmp_vmlinux1: final image has undefined symbols:
> >   SIZEOF_MACHINE_DESC
> 
> What is the user supposed to do when this happens?

Report it as an error to the most appropriate forum.  Then it becomes
a hunt for why the symbol is undefined.

Sorry, afaics it's not possible to do this any better.

To illustrate the severity of the problem better, the following
program:

        .globl  _start
_start:
        add     r0, r0, #UNDEFINED_SYMBOL
        mov     pc, lr

will successfully assemble and link on ARM, and is in fact runnable
despite having a symbol table of the following:

$ arm-linux-nm t
00008074 t $a
0001007c A __bss_end__
0001007c A _bss_end__
0001007c A __bss_start
0001007c A __bss_start__
0001007c D __data_start
0001007c A _edata
0001007c A _end
0001007c A __end__
00008074 T _start
         U UNDEFINED_SYMBOL


-- 
Russell King
 Linux kernel    2.6 ARM Linux   - http://www.arm.linux.org.uk/
 maintainer of:  2.6 PCMCIA      - http://pcmcia.arm.linux.org.uk/
                 2.6 Serial core

  reply	other threads:[~2004-07-01 22:22 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-01 16:52 binutils woes Russell King
2004-07-01 17:47 ` Tom Rini
2004-07-01 18:07   ` Russell King
2004-07-01 19:44     ` Martin Schlemmer
2004-07-01 19:52       ` Russell King
2004-07-01 22:12         ` Russell King
2004-07-01 22:21           ` Andrew Morton
2004-07-01 22:22             ` Russell King [this message]
2004-07-02 10:56 ` Michael Buesch
2004-07-11 11:32 ` Russell King
2004-07-11 13:56 ` Russell King

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040701232207.H8389@flint.arm.linux.org.uk \
    --to=rmk+lkml@arm.linux.org.uk \
    --cc=akpm@osdl.org \
    --cc=azarah@nosferatu.za.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.org \
    --cc=trini@kernel.crashing.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox