Subject: pkg/30007: tcl-scotty's configure mishandles TCL_LD_SEARCH_FLAGS
To: None <,,>
From: None <>
List: pkgsrc-bugs
Date: 04/19/2005 09:01:00
>Number:         30007
>Category:       pkg
>Synopsis:       tcl-scotty's configure mishandles TCL_LD_SEARCH_FLAGS
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Apr 19 09:01:00 +0000 2005
>Originator:     Havard Eidnes
>Release:        NetBSD 2.0
System: NetBSD 2.0 NetBSD 2.0 (GENERIC) #12: Thu Dec 2 12:00:22 CET 2004 i386
Architecture: i386
Machine: i386
	The tcl-scotty package presently fails to install with

libtool  --mode=link cc -L/usr/lib -Wl,-R/usr/lib -Wl,-R/usr/pkg/lib -Wl,-R -o scotty scotty.o -Wl,-R/usr/pkg/lib -L/usr/pkg/lib -ltcl84 -lrpcsvc   -lpthread -lm  -lm
libtool: link: you must specify an output file
Try `libtool --help --mode=link' for more information.
*** Error code 1

	Note the "empty" "-Wl,-R" specification which most probably
	ends up "eating" the output file specification.

	The reason is that the tcl-scotty configure script misuses the
	TCL_LD_SEARCH_FLAGS setting in, like this:

. $tnm_cv_path_tcl_config/

	My says quite clearly:

# Flags to pass to ld, such as "-R /usr/local/tcl/lib", that tell the
# run-time dynamic linker where to look for shared libraries such as
#  Used when linking applications.  Only works if there
# is a variable "LIB_RUNTIME_DIR" defined in the Makefile.

	and LIB_RUNTIME_DIR is not defined at that point, so Makefile
	ends up with just "-Wl,-R" as LD_SEARCH_FLAGS, which gets
	passed to the link line, and results in the error above.

	Inspect as above.

	Ensure LIB_RUNTIME_DIR is set to something sensible (what?)
	before sourcing