Subject: pkg/18715: fix to make devel/gdb build and install cleanly as non-root
To: None <gnats-bugs@gnats.netbsd.org>
From: Greg A. Woods <woods@weird.com>
List: netbsd-bugs
Date: 10/19/2002 15:26:11
>Number:         18715
>Category:       pkg
>Synopsis:       fix to make devel/gdb build and install cleanly as non-root
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Oct 19 12:27:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Greg A. Woods
>Release:        pkgsrc-current 2002/10/18
>Organization:
Planix, Inc.; Toronto, Ontario; Canada
>Environment:
	
System: NetBSD proven 1.5W NetBSD 1.5W (PROVEN) #1: Sat Aug 25 21:25:26 EDT 2001 woods@proven:/work/woods/NetBSD-src/sys/arch/i386/compile/PROVEN i386
Architecture: i386
Machine: i386
>Description:

	the default "build" of gdb doesn't update the bfd.info files and
	so they get created as root during "make install"

	adding a post-build target to build them during "make build" is
	the best fix

	also note that this package installs a file that more properly
	comes from devel/autoconf (no fix provided to avoid this yet)

>How-To-Repeat:

	run "make install && make clean" as a non-root user

>Fix:

Index: devel/gdb/Makefile
===================================================================
RCS file: /cvs/master/m-NetBSD/main/pkgsrc/devel/gdb/Makefile,v
retrieving revision 1.5
diff -c -r1.5 Makefile
*** devel/gdb/Makefile	7 Aug 2002 14:18:26 -0000	1.5
--- devel/gdb/Makefile	13 Sep 2002 20:36:48 -0000
***************
*** 11,21 ****
--- 11,26 ----
  
  MAKE_ENV+=	CPPFLAGS=
  INFO_FILES=	gdb.info gdbint.info stabs.info bfd.info
+ # WARNING: standards.info conflicts with the more authoritative one in
+ # autoconf-2.53
  INFO_FILES+=	mmalloc.info standards.info
  INSTALL_TARGET=	install install-info
  
  do-configure:
  	cd ${WRKSRC}; ./configure --prefix=${PREFIX}
+ 
+ post-build:
+ 	cd ${WRKSRC}/bfd/doc; ${MAKE} bfd.info
  
  .include "../../mk/texinfo.mk"
  .include "../../mk/bsd.pkg.mk"
>Release-Note:
>Audit-Trail:
>Unformatted: