Subject: pkg/14240: [rkb] pkgsrc/graphics/gle doesn't build due to bad link line
To: None <gnats-bugs@gnats.netbsd.org>
From: None <rafal@netbsd.org>
List: netbsd-bugs
Date: 10/13/2001 13:07:37
>Number:         14240
>Category:       pkg
>Synopsis:       pkgsrc/graphics/gle doesn't build due to bad link line
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Oct 13 11:01:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Rafal
>Release:        pkgsrc updated 10/11, userland&kernel from 10/9 (NEW_TOOLCHAIN)
>Organization:
Highly unlikely
>Environment:
System: NetBSD groo-the-wanderer 1.5Y NetBSD 1.5Y (STINKPAD) #7: Tue Oct 9 07:02:20 EDT 2001 root@stinkpad:/usr/rafal/netbsd-src/sys/arch/i386/compile/STINKPAD i386
Architecture: i386
Machine: i386

	Using NEW_TOOLCHAIN, in case that's relevant (though I don't think so).
>Description:
	The link line for the GLE example programs (which aren't installed,
	so one possible fix is to not build them at all) has the newly biult
	gle library *after* the GL, GLUT, etc. libs.

	This causes the linker to complain that it cannot resolve symbols in
	the gle library that are part of GLU/GLUT/GL libs.
>How-To-Repeat:
	Build the package, notice that linking examples fails.
>Fix:

	The package seems to abuse X_LIBS contrary to the purpose stated in
	the comments, which these patches perpetuate, but at least everything
	works now.  Included also is a patch to configure.in (which I don't
	think we use, but it's here just in case).

--- configure.orig	Fri Oct 12 18:23:13 2001
+++ configure	Fri Oct 12 18:24:13 2001
@@ -3202,7 +3202,7 @@
 #       cc @X_LIBS@ (-lfoo...) @X_PRE_LIBS@ -lX11 @X_EXTRA_LIBS@
 # (Perhaps X_LIBS should have been called X_LDFLAGS.)
 
-X_LIBS="$X_LIBS -lgle -lXi -lXext -lXmu -lXt -lX11"
+X_LIBS="-lgle $X_LIBS -lXi -lXext -lXmu -lXt -lX11"
 
 trap '' 1 2 15
 cat > confcache <<\EOF

--- configure.in.orig	Fri Oct 12 18:23:25 2001
+++ configure.in	Fri Oct 12 18:24:32 2001
@@ -129,7 +129,7 @@
 #       cc @X_LIBS@ (-lfoo...) @X_PRE_LIBS@ -lX11 @X_EXTRA_LIBS@
 # (Perhaps X_LIBS should have been called X_LDFLAGS.)
 
-X_LIBS="$X_LIBS -lgle -lXi -lXext -lXmu -lXt -lX11"
+X_LIBS="-lgle $X_LIBS -lXi -lXext -lXmu -lXt -lX11"
 
 AC_OUTPUT(
           Makefile
>Release-Note:
>Audit-Trail:
>Unformatted: