Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Jun 1997 21:59:17 -0400 (EDT)
From:      James FitzGibbon <james@nexis.net>
To:        FreeBSD-gnats-submit@FreeBSD.ORG
Subject:   ports/3880: diff to ucd-snmp port to install libraries and headers
Message-ID:  <199706160159.VAA10286@nexis.net>
Resent-Message-ID: <199706160210.TAA09635@hub.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         3880
>Category:       ports
>Synopsis:       ucd-snmp port does not install library or headers
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports
>State:          open
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sun Jun 15 19:10:01 PDT 1997
>Last-Modified:
>Originator:     James FitzGibbon
>Organization:
ACC TelEnterprises
>Release:        FreeBSD 2.2-STABLE i386
>Environment:

>Description:

The current port of UCD SNMP (net/ucd-snmp) doesn't install libsnmp.a or any
of the header files that come with the distribution.  This makes it
impossible for other ports that require these files to use ucd-snmp in the
*_DEPENDS lines of their Makefiles.

Note: I have mailed the maintainer, Gary Palmer, twice with this patch, but
received no response.  I'm not sure if his gpalmer@freebsd.org address is
being read, but I thought it best to do this through GNATS to avoid the type
of situation we had with hylafax last month.  If he's busy, I can commit the
diff myself.

>How-To-Repeat:

Build net/ucd-snmp.  The headers and library are in the distribution, but
not installed.

>Fix:
	
The following patch:
 - installs the library and headers
 - adds these files to pkg/PLIST
 - adds -DPIC -fpic to CFLAGS so that when other programs link to the newly
   installed library, they don't get "RRS Text Relocation" errors for each
   function therein.

diff -ruN ucd-snmp.orig/patches/patch-ab ucd-snmp/patches/patch-ab
--- ucd-snmp.orig/patches/patch-ab	Thu May 29 11:26:55 1997
+++ ucd-snmp/patches/patch-ab	Thu May 29 14:51:17 1997
@@ -1,8 +1,18 @@
---- Makefile.in.orig	Wed Jun 26 17:01:04 1996
-+++ Makefile.in	Wed Jun 26 17:01:21 1996
-@@ -62,16 +62,16 @@
+--- Makefile.in.orig	Wed Feb  5 11:29:38 1997
++++ Makefile.in	Thu May 29 13:58:34 1997
+@@ -40,6 +40,9 @@
+ 	done
+ 	@$(INSTALL) mib.txt $(snmplibdir) ; echo "install:  installed mib.txt in $(snmplibdir)"
+ 	@$(INSTALL) ucd-snmp.txt $(mibdir) ; echo "install:  installed ucd-snmp.txt in $(mibdir)"
++	@$(INSTALL) snmplib/*.h $(snmplibdir) ; echo "install:  installed snmp header files in $(snmplibdir)"
++	@$(INSTALL) snmplib/libsnmp.a $(libdir) ; echo "install:  installed libsnmp.a in $(libdir)"
++	
+ 
+ installdirs:
+ 	@$(SHELL) $(srcdir)/mkinstalldirs $(snmplibdir) $(mibdir)
+@@ -64,16 +67,16 @@
  	rm -f config.cache config.status config.log
- 	rm -f snmplib/Makefile Makefile snmptcl/Makefile agent/Makefile apps/Makefile apps/snmpnetstat/Makefile agent/extensible/Makefile local/Makefile
+ 	rm -f snmplib/Makefile Makefile agent/Makefile apps/Makefile apps/snmpnetstat/Makefile agent/extensible/Makefile local/Makefile
  
 -configure: configure.in aclocal.m4
 -	cd ${srcdir} && autoconf
diff -ruN ucd-snmp.orig/patches/patch-ah ucd-snmp/patches/patch-ah
--- ucd-snmp.orig/patches/patch-ah	Wed Dec 31 19:00:00 1969
+++ ucd-snmp/patches/patch-ah	Thu May 29 11:44:55 1997
@@ -0,0 +1,11 @@
+--- snmplib/Makefile.in.orig	Thu May 29 11:43:35 1997
++++ snmplib/Makefile.in	Thu May 29 11:43:45 1997
+@@ -5,7 +5,7 @@
+ CSRCS=	snmp_client.c mib.c parse.c snmp_api.c snmp.c snmp_auth.c asn1.c md5.c party.c context.c acl.c view.c party_parse.c context_parse.c acl_parse.c system.c
+ OBJS=	snmp_client.o mib.o parse.o snmp_api.o snmp.o snmp_auth.o asn1.o md5.o party.o context.o acl.o view.o party_parse.o context_parse.o acl_parse.o system.o
+ 
+-CFLAGS=@CFLAGS@
++CFLAGS=@CFLAGS@ -fpic -DPIC
+ CPPFLAGS=@CPPFLAGS@ -I..
+ LDFLAGS=@LDFLAGS@
+ 
diff -ruN ucd-snmp.orig/pkg/PLIST ucd-snmp/pkg/PLIST
--- ucd-snmp.orig/pkg/PLIST	Thu May 29 11:26:56 1997
+++ ucd-snmp/pkg/PLIST	Thu May 29 15:12:12 1997
@@ -24,10 +24,27 @@
 man/man5/snmpd.conf.5.gz
 man/man8/snmptrapd.8.gz
 man/man8/snmpd.8.gz
+lib/libsnmp.a
 lib/snmp/mib.txt
+lib/snmp/acl.h
+lib/snmp/asn1.h
+lib/snmp/context.h
+lib/snmp/md5.h
+lib/snmp/mib.h
+lib/snmp/parse.h
+lib/snmp/party.h
+lib/snmp/snmp.h
+lib/snmp/snmp_api.h
+lib/snmp/snmp_client.h
+lib/snmp/snmp_impl.h
+lib/snmp/system.h
+lib/snmp/view.h
+lib/snmp/mibs/ucd-snmp.txt
 sbin/snmpd
 share/examples/ucd-snmp/README
 share/examples/ucd-snmp/acl.conf
 share/examples/ucd-snmp/context.conf
 share/examples/ucd-snmp/party.conf
 share/examples/ucd-snmp/view.conf
+@dirrm lib/snmp/mibs
+@dirrm lib/snmp
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199706160159.VAA10286>