Subject: bin/678: linker problems?
To: None <gnats-admin@NetBSD.ORG>
From: None <yoav@MIT.EDU>
List: netbsd-bugs
Date: 01/02/1995 11:05:09
>Number:         678
>Category:       bin
>Synopsis:       Linker only checks dependencies one level deep.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    bin-bug-people (Utility Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jan  2 11:05:05 1995
>Originator:     Yoav Yerushalmi
>Organization:
"SIPB (MIT)"
>Release:        1.0
>Environment:
	
System: NetBSD lola-granola 1.0 NetBSD 1.0 (LOLA-DDB) #56: Sat Dec 17 13:51:12 EST 1994 fsf@lola-granola:/u1/usr/src/sys/arch/i386/compile/LOLA-DDB i386


>Description:
The linker only checks symbol dependencies one level deep, so when you
link a program against, say motif, and forget Xt, it does not notice
in the compilation stage, only when running does the dynamic linker
notice the problem (ld.so: foobar not defined). This has probably been
noticed lots of times already, but I didn't see it on the bug list, so
am reporting it.  
>How-To-Repeat:
	Build any program which relies on a library which relies on
another one. For example, building a program which uses Xaw (which
relies on Xmu) and not linking with Xmu results in a binary, but when
this binary is executed, the following appears:
	ld.so: Undefined symbol "_XmuCvtStringToOrientation" in kerberometer:/usr/X11R6/lib/libXaw.so.6.0

>Fix:
	Well, it could be possible to make the linker warn (but
successfully link), when a symbol might be undefined?
>Audit-Trail:
>Unformatted:


	It seems a compilation succeeded, when in fact, several
symbols are still undefined.