Subject: kern/13615: NetBSD current requires a .note.netbsd.ident section
To: None <gnats-bugs@gnats.netbsd.org>
From: None <cagney@mac.com>
List: netbsd-bugs
Date: 08/01/2001 13:58:56
>Number:         13615
>Category:       kern
>Synopsis:       NetBSD current requires a .note.netbsd.ident section
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Aug 01 13:56:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Andrew cagney
>Release:        NetBSD 1.5.1 userland + NetBSD 2001-08-01(ish) kernel
>Organization:
>Environment:
NetBSD localhost 1.5X NetBSD 1.5X (NETLUX) #0: Wed Aug  1 15:41:44 EDT 2001     boor@localhost:/usr/trunk/sys/arch/macppc/compile/NETLUX macppc

>Description:
/usr/lib/crtstart.o contains a .note.netbsd.ident section.
NetBSD's bundled compiler links crtstart, crtend, crt0, ... into an executable.
The kernel (current) refuses to run NetBSD executables unless: they contain the above .note section or the kernel is configured with ``options EXEC_ELF_CATCHALL''.

Unfortunatly, unbundled complers (eg GCC>3.0) typically don't use system supplied files such as crtbegin.o - instead they supply their own.  Consequently, an unbundled compiler won't include the crtbegin.o .note section and, in turn, won't be able to generate binaries that can be run on NetBSD-current.

Further, the error message printed when you run such a binary is totally unhelpful.


>How-To-Repeat:
Build an executable that does not contain a .note section.
>Fix:
Revert rev 1.57 of kern/exec_conf.c.


>Release-Note:
>Audit-Trail:
>Unformatted: