Subject: pkg/16238: some fixes for net/netsaint-plugins-1.2.9.4
To: None <gnats-bugs@gnats.netbsd.org>
From: Greg A. Woods <woods@weird.com>
List: netbsd-bugs
Date: 04/07/2002 17:52:26
>Number:         16238
>Category:       pkg
>Synopsis:       some fixes for net/netsaint-plugins-1.2.9.4
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Apr 07 14:53:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Greg A. Woods
>Release:        pkgsrc-2002/04//2
>Organization:
Planix, Inc.; Toronto, Ontario; Canada
>Environment:
System: NetBSD
>Description:

	there are some bugs remaining in the netsaint-plugins configure
	script and its invocation

	Note also that the check for /usr/bin/ssh is very naive if you
	consider the possibility of PREFIX=/usr.....

>How-To-Repeat:

	notice the wrong things were included as run-time dependencies

	examine the output from the configure step

>Fix:

	apply the following patch in pkgsrc/net/netsaint-plugins
	(take care with the line numbers -- some hand editing done to
	undo a patch regarding SSH)

Index: Makefile
===================================================================
RCS file: /cvs/master/m-NetBSD/main/pkgsrc/net/netsaint-plugins/Makefile,v
retrieving revision 1.8
diff -c -r1.8 Makefile
*** Makefile	26 Mar 2002 20:16:18 -0000	1.8
--- Makefile	7 Apr 2002 21:17:19 -0000
***************
*** 11,?? ****
  HOMEPAGE=		http://netsaintplug.sourceforge.net/
  COMMENT=		NetSaint plugins
  
! DEPENDS+=		autoconf>=2.13:../../devel/autoconf
! DEPENDS+=		automake>=1.4.5:../../devel/automake
  DEPENDS+=		netsaint-base-[0-9]*:../../net/netsaint-base
  .if !exists(/usr/bin/ssh)
  DEPENDS+=		{ssh{,6}-[0-9]*,openssh-[0-9]*}:../../security/ssh
--- 11,21 ----
  HOMEPAGE=		http://netsaintplug.sourceforge.net/
  COMMENT=		NetSaint plugins
  
! BUILD_DEPENDS+=		autoconf>=2.13:../../devel/autoconf
! BUILD_DEPENDS+=		automake>=1.4.5:../../devel/automake
! 
  DEPENDS+=		netsaint-base-[0-9]*:../../net/netsaint-base
  .if !exists(/usr/bin/ssh)
  DEPENDS+=		{ssh{,6}-[0-9]*,openssh-[0-9]*}:../../security/ssh
***************
*** 24,30 ****
  .include "../../mk/bsd.prefs.mk"
  
  .if ${OPSYS} == "NetBSD"
! CONFIGURE_ARGS+=      --with-df-command="/bin/df -Pkt nokernfs,procfs"
  .endif
  
  pre-configure:
--- 23,29 ----
  .include "../../mk/bsd.prefs.mk"
  
  .if ${OPSYS} == "NetBSD"
! CONFIGURE_ARGS+=      --with-df-command="/bin/df -Pklt nokernfs,procfs,fdesc"
  .endif
  
  pre-configure:
Index: patches/patch-aa
===================================================================
RCS file: /cvs/master/m-NetBSD/main/pkgsrc/net/netsaint-plugins/patches/patch-aa,v
retrieving revision 1.3
diff -c -r1.3 patch-aa
*** patches/patch-aa	26 Mar 2002 20:16:19 -0000	1.3
--- patches/patch-aa	7 Apr 2002 21:28:47 -0000
***************
*** 1,7 ****
  $NetBSD: patch-aa,v 1.3 2002/03/26 20:16:19 rh Exp $
  
  --- configure.in.orig	Fri Apr 27 00:00:26 2001
! +++ configure.in
  @@ -144,7 +144,7 @@
   dnl Check for LDAP libraries
   _SAVEDLIBS="$LIBS"
--- 1,7 ----
  $NetBSD: patch-aa,v 1.3 2002/03/26 20:16:19 rh Exp $
  
  --- configure.in.orig	Fri Apr 27 00:00:26 2001
! +++ configure.in	Sun Apr  7 17:27:29 2002
  @@ -144,7 +144,7 @@
   dnl Check for LDAP libraries
   _SAVEDLIBS="$LIBS"
***************
*** 11,16 ****
--- 11,36 ----
     LDAPLIBS="-lldap -llber"\
     LDAPINCLUDE="-I/usr/include/ldap"
     AC_SUBST(LDAPLIBS)
+ @@ -260,6 +260,9 @@
+  AC_TYPE_SIZE_T
+  AC_TYPE_SIGNAL
+  
+ +dnl Checks for library functions.
+ +AC_CHECK_FUNCS(select socket strdup strstr strtod strtol strtoul)
+ +
+  dnl EXTRA_LIBRARIES="libgetopt.a libsnprintf.a"
+  dnl noinst_LIBRARIES="libgetopt.a libsnprintf.a"
+  dnl libgetopt_a_SOURCES="getopt.c getopt1.c"
+ @@ -283,9 +286,6 @@
+  
+  AC_CHECK_FUNC(vsnprintf,,LIBS="$LIBS -lsnprintf" DEPLIBS="$DEPLIBS libsnprintf.a")
+  
+ -dnl Checks for library functions.
+ -AC_CHECK_FUNCS(select socket strdup strstr strtod strtol strtoul)
+ -
+  AC_MSG_CHECKING(for type of socket size)
+  AC_TRY_COMPILE([#include <stdlib.h>
+  #include <sys/types.h>
  @@ -395,7 +395,7 @@
   	AC_DEFINE_UNQUOTED(VSZ_FORMAT,"%d %s")
   	AC_DEFINE_UNQUOTED(RSS_COMMAND,"$PATH_TO_PS waxco 'rss command'")
***************
*** 20,25 ****
--- 40,54 ----
   dnl BSD-like mode in RH 6.1
   elif [ps waxno 'state comm vsz rss uid user ppid args' 2>/dev/null | egrep -i "^S +COMMAND +VSZ +RSS +UID +USER +PPID +[RGSCOMDNA]+" >/dev/null]
   then
+ @@ -596,7 +596,7 @@
+  if test -n "$ac_cv_path_PATH_TO_NSLOOKUP"
+  then
+  	AC_MSG_CHECKING("nslookup syntax")
+ -	if [nslookup -sil 127.0.0.1 2>&1 | grep "*** Invalid option: sil" >/dev/null]
+ +	if [nslookup -sil 127.0.0.1 2>&1 | fgrep "*** Invalid option: sil" >/dev/null]
+  	then
+  		AC_MSG_RESULT("$PATH_TO_NSLOOKUP")
+  		AC_DEFINE_UNQUOTED(NSLOOKUP_COMMAND,"$PATH_TO_NSLOOKUP")
  @@ -621,7 +621,7 @@
   fi
   
>Release-Note:
>Audit-Trail:
>Unformatted: