diff options
author | tv <tv> | 1999-05-04 03:51:57 +0000 |
---|---|---|
committer | tv <tv> | 1999-05-04 03:51:57 +0000 |
commit | b56119aa3b2af34da3a417641526cb881a90da3d (patch) | |
tree | a9351fad1396a8c31c6a0a354ab3065be8a0e63b /net | |
parent | 6dc86031fc14d1faf66085d2e3b8d6bafbc86415 (diff) | |
download | pkgsrc-b56119aa3b2af34da3a417641526cb881a90da3d.tar.gz |
Build libsnmp as a shared object with libtool. Bump version to "...p1".
Diffstat (limited to 'net')
-rw-r--r-- | net/ucd-snmp/Makefile | 35 | ||||
-rw-r--r-- | net/ucd-snmp/patches/patch-aa | 82 | ||||
-rw-r--r-- | net/ucd-snmp/patches/patch-ab | 35 | ||||
-rw-r--r-- | net/ucd-snmp/pkg/PLIST | 6 |
4 files changed, 66 insertions, 92 deletions
diff --git a/net/ucd-snmp/Makefile b/net/ucd-snmp/Makefile index 0ffd2e91f98..5954236f809 100644 --- a/net/ucd-snmp/Makefile +++ b/net/ucd-snmp/Makefile @@ -1,8 +1,9 @@ -# $NetBSD: Makefile,v 1.11 1999/04/21 20:47:22 abs Exp $ +# $NetBSD: Makefile,v 1.12 1999/05/04 03:51:57 tv Exp $ # FreeBSD Id: Makefile,v 1.18 1998/04/06 20:50:31 andreas Exp # DISTNAME= ucd-snmp-3.6.1 +PKGNAME= ucd-snmp-3.6.1p1 CATEGORIES= net MASTER_SITES= ftp://ucd-snmp.ucdavis.edu/ \ ftp://sunsite.cnlab-switch.ch/mirror/ucd-snmp/ @@ -10,35 +11,25 @@ MASTER_SITES= ftp://ucd-snmp.ucdavis.edu/ \ MAINTAINER= packages@netbsd.org HOMEPAGE= http://www.ece.ucdavis.edu/ucd-snmp/ -BUILD_DEPENDS+= autoconf:../../devel/autoconf +USE_LIBTOOL= yes GNU_CONFIGURE= yes -CONFIGURE_ARGS+= --with-defaults -CONFIGURE_ARGS+= --with-libwrap -# note the default appends a redundant and silly ".log" -CONFIGURE_ARGS+= --with-logfile="/var/log/snmpd" -# this might make it easier to use scotty's mibs, and local ones too -CONFIGURE_ARGS+= --with-mibdirs="${PREFIX}/share/snmp/mibs:${PREFIX}/lib/tnm2.1.8/mibs:/usr/local/share/snmp/mibs" +CONFIGURE_ARGS+=--with-defaults --with-libwrap --with-logfile="/var/log/snmpd" -# pass down PKG_PREFIX to simulate pkg_add's environment -MAKE_ENV+= PKG_PREFIX="${PREFIX}" +# this might make it easier to use scotty's mibs, and local ones too +CONFIGURE_ARGS+=--with-mibdirs="${PREFIX}/share/snmp/mibs:${PREFIX}/lib/tnm2.1.8/mibs:/usr/local/share/snmp/mibs" -.include "../../mk/bsd.prefs.mk" +# provide path to libtool's lib directory: +MAKE_ENV= CC_RUNTIME_ARG="-L../snmplib/.libs -L../../snmplib/.libs" -pre-configure: - (cd ${WRKSRC}; autoreconf --force) +# deal with libwrap bogosity by providing these variables to programs which +# do not supply them: +post-extract: + @${ECHO} 'int allow_severity, deny_severity;' >${WRKSRC}/snmplib/libwrap.c -# Need to run INSTALL script as this doesn't happen automagically from pkgsrc. post-install: @${MKDIR} ${PREFIX}/share/examples/ucd-snmp - @for F in ${WRKSRC}/etc/* ; do \ - ${INSTALL_DATA} $$F ${PREFIX}/share/examples/ucd-snmp ; \ - done - ${ECHO} "Creating ${PREFIX}/etc/rc.d/snmpd.sh startup file."; \ - ${ECHO} "#!/bin/sh" > ${PREFIX}/etc/rc.d/snmpd.sh; \ - ${ECHO} "[ -x ${PREFIX}/sbin/snmpd ] && ${PREFIX}/sbin/snmpd && ${ECHO} -n ' snmpd'" >> ${PREFIX}/etc/rc.d/snmpd.sh - ${CHMOD} 755 ${PREFIX}/etc/rc.d/snmpd.sh + ${INSTALL_DATA} ${WRKSRC}/etc/* ${PREFIX}/share/examples/ucd-snmp ${INSTALL_DATA_DIR} ${PREFIX}/lib/snmp/dlmod - ${TOUCH} ${PREFIX}/lib/snmp/dlmod/.keepme .include "../../mk/bsd.pkg.mk" diff --git a/net/ucd-snmp/patches/patch-aa b/net/ucd-snmp/patches/patch-aa index 57964846559..7dd6ab82368 100644 --- a/net/ucd-snmp/patches/patch-aa +++ b/net/ucd-snmp/patches/patch-aa @@ -1,67 +1,33 @@ -# XXX The LIBWRAP horrible hack is necessary because of the stupid linker's -# insistence on requiring that all externals referenced from a shared library -# be defined, even if nothing elese from the library is ever used. In this -# case the libwrap.so library is at fault as it references 'deny_severity' and -# 'allow_severity', but none of the configure tests will include this, nor -# indeed will any product binary except for snmpd (which is the only one that -# actualy uses tcp_wrappers). -# -# /usr/libexec/ld.so: Undefined symbol "_deny_severity" in conftest:/usr/lib/libwrap.so.0.0 -# ---- configure.in.orig Mon Mar 15 15:31:43 1999 -+++ configure.in Tue Apr 20 18:35:51 1999 -@@ -97,14 +97,15 @@ - AC_ARG_WITH(libwrap, - [ --with-libwrap[=LIBPATH] Compile in libwrap (tcp_wrappers) support.], - if test "x$withval" != "x" -a -d "$withval"; then -- LIBS="-L$withval -lwrap $LIBS" -+ LIBWRAP="-L$withval -lwrap" +$NetBSD: patch-aa,v 1.7 1999/05/04 03:51:57 tv Exp $ + +--- configure.orig Mon Mar 15 19:27:31 1999 ++++ configure Mon May 3 23:39:50 1999 +@@ -744,7 +744,7 @@ + if test "x$withval" != "x" -a -d "$withval"; then + LIBS="-L$withval -lwrap $LIBS" elif test "x$withval" = "xyes"; then - LIBS="-lwrap $LIBS" + LIBWRAP="-lwrap" else -- LIBS="$withval $LIBS" -+ LIBWRAP="$withval" + LIBS="$withval $LIBS" fi - AC_DEFINE(USE_LIBWRAP) - ) -+AC_SUBST(LIBWRAP) +@@ -1821,9 +1821,10 @@ - AC_ARG_WITH(mib_modules, - [ --with-mib-modules=\"item1 ...\" Compile with additional mib modules -@@ -821,11 +822,7 @@ + esac + else +- SHLIB_EXTENSION="a" ++ SHLIB_EXTENSION="la" + SHLIB_LD_CMD="ar cr" + SHLIB_LDCONFIG_CMD=":" ++ RANLIB=":" + fi - AC_CHECK_STRUCT_FOR([ - #include <sys/types.h> --#define KERNEL --#define _KERNEL - #include <sys/socket.h> --#undef KERNEL --#undef _KERNEL - #include <net/route.h> - ], rtentry, rt_dst, no) -@@ -836,11 +833,7 @@ - dnl 4.4 compat - AC_TRY_COMPILE([ - #include <sys/types.h> --#define KERNEL --#define _KERNEL - #include <sys/socket.h> --#undef KERNEL --#undef _KERNEL - #include <net/route.h> - ],[ +@@ -7699,6 +7700,7 @@ + fi + fi -@@ -857,11 +850,7 @@ - if test "x$ac_cv_RTENTRY_TYPE" = "x"; then - AC_TRY_COMPILE([ - #include <sys/types.h> --#define KERNEL --#define _KERNEL - #include <sys/socket.h> --#undef KERNEL --#undef _KERNEL - #include <net/route.h> - ],[ - struct rtentry rt; ++LIBS="$LIBS $LIBWRAP" + + trap '' 1 2 15 + cat > confcache <<\EOF diff --git a/net/ucd-snmp/patches/patch-ab b/net/ucd-snmp/patches/patch-ab index 6b7f22c165a..89fc3e9c050 100644 --- a/net/ucd-snmp/patches/patch-ab +++ b/net/ucd-snmp/patches/patch-ab @@ -1,11 +1,28 @@ ---- agent/Makefile.in.orig Tue Apr 20 18:13:58 1999 -+++ agent/Makefile.in Tue Apr 20 18:14:11 1999 -@@ -4,7 +4,7 @@ +$NetBSD: patch-ab,v 1.2 1999/05/04 03:51:57 tv Exp $ + +--- snmplib/Makefile.in.orig Mon Mar 15 11:49:10 1999 ++++ snmplib/Makefile.in Mon May 3 23:26:56 1999 +@@ -35,19 +35,18 @@ - TARG= snmpd - USELIBS= ../snmplib/libsnmp.$(SHLIB_EXTENSION)$(SHLIB_VERSION) --LIBS= -L../snmplib $(CC_RUNTIME_ARG) -lsnmp @LIBS@ -+LIBS= -L../snmplib $(CC_RUNTIME_ARG) -lsnmp @LIBS@ @LIBWRAP@ + CFLAGS=@CFLAGS@ @SHLIB_CFLAGS@ + CPPFLAGS=@CPPFLAGS@ -I. -I.. -I$(srcdir) -I$(srcdir)/.. +-CC = @CC@ $(CPPFLAGS) ++CC = $(LIBTOOL) @CC@ $(CPPFLAGS) + + all: $(TARG) + +-libsnmp.$(SHLIB_EXTENSION)$(SHLIB_VERSION): ${OBJS} +- $(SHLIB_LD_CMD) libsnmp.$(SHLIB_EXTENSION)$(SHLIB_VERSION) ${OBJS} +- $(RANLIB) libsnmp.$(SHLIB_EXTENSION)$(SHLIB_VERSION) ++$(TARG): $(OBJS) ++ $(CC) -o $@ $(OBJS:.o=.lo) -version-info 0:0 -rpath $(PREFIX)/lib + + installdirs: + @$(SHELL) $(srcdir)/../mkinstalldirs $(libdir) $(includedir) + + install: $(TARG) installdirs +- @for i in $(TARG) ; do $(INSTALL) $$i $(libdir) ; $(RANLIB) $(libdir)/$$i ; echo "install: installed $$i in $(libdir)" ; done ++ @for i in $(TARG) ; do $(LIBTOOL) $(INSTALL) $$i $(libdir) ; $(RANLIB) $(libdir)/$$i ; echo "install: installed $$i in $(libdir)" ; done + @for i in $(INSTALLHEADERS) ; do $(INSTALL) $(srcdir)/$$i $(includedir) ; echo "install: installed $$i in $(includedir)" ; done + $(SHLIB_LDCONFIG_CMD) - CPPFLAGS=@CPPFLAGS@ -I.. -I$(srcdir)/.. -I$(srcdir)/../snmplib \ - -I$(srcdir) -I. -I$(srcdir)/mibgroup -Imibgroup diff --git a/net/ucd-snmp/pkg/PLIST b/net/ucd-snmp/pkg/PLIST index a569b014cbd..ce0f7ed279a 100644 --- a/net/ucd-snmp/pkg/PLIST +++ b/net/ucd-snmp/pkg/PLIST @@ -1,4 +1,4 @@ -@comment $NetBSD: PLIST,v 1.4 1999/04/05 00:59:08 hubertf Exp $ +@comment $NetBSD: PLIST,v 1.5 1999/05/04 03:51:57 tv Exp $ bin/snmpnetstat bin/snmpwalk bin/snmpbulkwalk @@ -13,7 +13,6 @@ bin/snmpdelta bin/snmptable bin/snmpcheck bin/tkmib -etc/rc.d/snmpd.sh include/ucd-snmp/acl.h include/ucd-snmp/asn1.h include/ucd-snmp/context.h @@ -32,6 +31,7 @@ include/ucd-snmp/ucd-snmp-includes.h include/ucd-snmp/version.h include/ucd-snmp/view.h lib/libsnmp.a +lib/libsnmp.so.0.0 man/man1/snmpcmd.1 man/man1/snmpget.1 man/man1/snmpset.1 @@ -91,7 +91,7 @@ share/snmp/mibs/TCP-MIB.txt share/snmp/mibs/UCD-SNMP-MIB.txt share/snmp/mibs/UDP-MIB.txt @unexec /bin/rm -f %D/share/snmp/mibs/.index -lib/snmp/dlmod/.keepme +@exec mkdir -p %D/lib/snmp/dlmod @dirrm lib/snmp/dlmod @dirrm share/snmp/mibs @dirrm share/snmp |