View | Details | Raw Unified | Return to bug 143830 | Differences between
and this patch

Collapse All | Expand All

(-)Makefile.inc1 (-1 / +1 lines)
Lines 1018-1024 Link Here
1018
_awk=		usr.bin/awk
1018
_awk=		usr.bin/awk
1019
.endif
1019
.endif
1020
1020
1021
.if ${BOOTSTRAPPING} < 700018
1021
.if ${MK_BSNMP} != "no"
1022
_gensnmptree=	usr.sbin/bsnmpd/gensnmptree
1022
_gensnmptree=	usr.sbin/bsnmpd/gensnmptree
1023
.endif
1023
.endif
1024
1024
(-)sbin/atm/atmconfig/main.c (-6 / +6 lines)
Lines 38-44 Link Here
38
#include <stdint.h>
38
#include <stdint.h>
39
#include <fnmatch.h>
39
#include <fnmatch.h>
40
#include <dirent.h>
40
#include <dirent.h>
41
#ifndef RESCUE
41
#if !defined(RESCUE) && defined(WITH_BSNMP)
42
#include <bsnmp/asn1.h>
42
#include <bsnmp/asn1.h>
43
#include <bsnmp/snmp.h>
43
#include <bsnmp/snmp.h>
44
#include <bsnmp/snmpclient.h>
44
#include <bsnmp/snmpclient.h>
Lines 444-450 Link Here
444
	exit(1);
444
	exit(1);
445
}
445
}
446
446
447
#ifndef RESCUE
447
#if !defined(RESCUE) && defined(WITH_BSNMP)
448
/*
448
/*
449
 * Parse a server specification
449
 * Parse a server specification
450
 *
450
 *
Lines 527-539 Link Here
527
	int opt, i;
527
	int opt, i;
528
	const struct cmdtab *match, *cc, *tab;
528
	const struct cmdtab *match, *cc, *tab;
529
529
530
#ifndef RESCUE
530
#if !defined(RESCUE) && defined(WITH_BSNMP)
531
	snmp_client_init(&snmp_client);
531
	snmp_client_init(&snmp_client);
532
	snmp_client.trans = SNMP_TRANS_LOC_STREAM;
532
	snmp_client.trans = SNMP_TRANS_LOC_STREAM;
533
	snmp_client_set_host(&snmp_client, PATH_ILMI_SOCK);
533
	snmp_client_set_host(&snmp_client, PATH_ILMI_SOCK);
534
#endif
534
#endif
535
535
536
#ifdef RESCUE
536
#if defined(RESCUE) || !defined(WITH_BSNMP)
537
#define OPTSTR	"htv"
537
#define OPTSTR	"htv"
538
#else
538
#else
539
#define	OPTSTR	"htvs:"
539
#define	OPTSTR	"htvs:"
Lines 545-551 Link Here
545
		  case 'h':
545
		  case 'h':
546
			help_func(0, argv);
546
			help_func(0, argv);
547
547
548
#ifndef RESCUE
548
#if !defined(RESCUE) && defined(WITH_BSNMP)
549
		  case 's':
549
		  case 's':
550
			parse_server(optarg);
550
			parse_server(optarg);
551
			break;
551
			break;
Lines 570-576 Link Here
570
		err(1, NULL);
570
		err(1, NULL);
571
	memcpy(main_tab, static_main_tab, sizeof(static_main_tab));
571
	memcpy(main_tab, static_main_tab, sizeof(static_main_tab));
572
572
573
#ifndef RESCUE
573
#if !defined(RESCUE) && defined(WITH_BSNMP)
574
	/* XXX while this is compiled in */
574
	/* XXX while this is compiled in */
575
	device_register();
575
	device_register();
576
#endif
576
#endif
(-)sbin/atm/atmconfig/Makefile (-9 / +11 lines)
Lines 5-16 Link Here
5
#
5
#
6
# $FreeBSD$
6
# $FreeBSD$
7
7
8
.include <bsd.own.mk>
9
8
PROG=	atmconfig
10
PROG=	atmconfig
9
.ifndef RESCUE
11
12
.if !defined(RESCUE) && ${MK_BSNMP} == "yes"
13
CFLAGS	+= -DWITH_BSNMP
10
SRCS=	${.OBJDIR}/oid.h
14
SRCS=	${.OBJDIR}/oid.h
11
.endif
15
.endif
12
SRCS+=	main.c diag.c natm.c
16
SRCS+=	main.c diag.c natm.c
13
.ifndef RESCUE
17
.if !defined(RESCUE) && ${MK_BSNMP} == "yes"
14
SRCS+=	atmconfig_device.c
18
SRCS+=	atmconfig_device.c
15
.endif
19
.endif
16
MAN=	atmconfig.8
20
MAN=	atmconfig.8
Lines 18-32 Link Here
18
22
19
CFLAGS+= -I${.OBJDIR}
23
CFLAGS+= -I${.OBJDIR}
20
24
21
.ifndef RESCUE
25
.if !defined(RESCUE) && ${MK_BSNMP} == "yes"
22
DPADD=	${LIBBSNMP}
26
DPADD=	${LIBBSNMP}
23
LDADD=	-lbsnmp
27
LDADD=	-lbsnmp
24
.endif
28
.endif
25
29
26
.ifndef RESCUE
27
CLEANFILES+= oid.h
28
.endif
29
30
# XXX - this is verboten
30
# XXX - this is verboten
31
.if ${MACHINE_CPUARCH} == "arm"
31
.if ${MACHINE_CPUARCH} == "arm"
32
WARNS?= 3
32
WARNS?= 3
Lines 38-45 Link Here
38
SNMP_ATM_DEF= ${.CURDIR}/../../../contrib/ngatm/snmp_atm/atm_tree.def	\
38
SNMP_ATM_DEF= ${.CURDIR}/../../../contrib/ngatm/snmp_atm/atm_tree.def	\
39
	${.CURDIR}/../../../usr.sbin/bsnmpd/modules/snmp_atm/atm_freebsd.def
39
	${.CURDIR}/../../../usr.sbin/bsnmpd/modules/snmp_atm/atm_freebsd.def
40
40
41
.if ${MK_BSNMP} != "no"
41
${.OBJDIR}/oid.h: atm_oid.list ${SNMP_ATM_DEF}
42
${.OBJDIR}/oid.h: atm_oid.list ${SNMP_ATM_DEF}
42
	cat ${SNMP_ATM_DEF} | gensnmptree -e `tail -n +2 ${.CURDIR}/atm_oid.list` \
43
	gensnmptree -e `tail -n +2 ${.CURDIR}/atm_oid.list` < ${SNMP_ATM_DEF} \
43
		> ${.OBJDIR}/oid.h
44
		> ${.TARGET}
45
.endif
44
46
45
.include <bsd.prog.mk>
47
.include <bsd.prog.mk>

Return to bug 143830