191a2f929SHartmut Brandt# $FreeBSD$ 291a2f929SHartmut Brandt# 391a2f929SHartmut Brandt# Author: Harti Brandt <harti@freebsd.org> 491a2f929SHartmut Brandt 5c6063d0dSWarner Losh.include <src.opts.mk> 6135f7de5SShteryana Shopova 764a0982bSEnji CooperCONTRIB=${SRCTOP}/contrib/bsnmp 8723d6e64SHartmut Brandt.PATH: ${CONTRIB}/snmpd 991a2f929SHartmut Brandt 1091a2f929SHartmut BrandtPROG= bsnmpd 11b6a6dd18SHartmut BrandtSRCS= main.c action.c config.c export.c trap.c trans_udp.c trans_lsock.c 12b6a6dd18SHartmut BrandtSRCS+= oid.h tree.c tree.h 13b6a6dd18SHartmut BrandtXSYM= snmpMIB begemotSnmpdModuleTable begemotSnmpd begemotTrapSinkTable \ 14b6a6dd18SHartmut Brandt sysUpTime snmpTrapOID coldStart authenticationFailure \ 1599eebd2aSGleb Smirnoff begemotSnmpdTransUdp begemotSnmpdTransLsock begemotSnmpdLocalPortTable \ 16135f7de5SShteryana Shopova freeBSD freeBSDVersion 17b6a6dd18SHartmut BrandtCLEANFILES= oid.h tree.c tree.h 18f66b889dSEnji Cooper 1991a2f929SHartmut BrandtMAN= bsnmpd.1 snmpmod.3 2091a2f929SHartmut Brandt 21f66b889dSEnji CooperMLINKS+= snmpmod.3 FIND_OBJECT_INT.3 22f66b889dSEnji CooperMLINKS+= snmpmod.3 FIND_OBJECT_INT_LINK.3 23f66b889dSEnji CooperMLINKS+= snmpmod.3 FIND_OBJECT_INT_LINK_INDEX.3 24f66b889dSEnji CooperMLINKS+= snmpmod.3 FIND_OBJECT_OID.3 25f66b889dSEnji CooperMLINKS+= snmpmod.3 FIND_OBJECT_OID_LINK.3 26f66b889dSEnji CooperMLINKS+= snmpmod.3 FIND_OBJECT_OID_LINK_INDEX.3 27f66b889dSEnji CooperMLINKS+= snmpmod.3 INSERT_OBJECT_INT.3 28f66b889dSEnji CooperMLINKS+= snmpmod.3 INSERT_OBJECT_INT_LINK.3 29f66b889dSEnji CooperMLINKS+= snmpmod.3 INSERT_OBJECT_INT_LINK_INDEX.3 30f66b889dSEnji CooperMLINKS+= snmpmod.3 INSERT_OBJECT_OID.3 31f66b889dSEnji CooperMLINKS+= snmpmod.3 INSERT_OBJECT_OID_LINK.3 32f66b889dSEnji CooperMLINKS+= snmpmod.3 INSERT_OBJECT_OID_LINK_INDEX.3 33f66b889dSEnji CooperMLINKS+= snmpmod.3 NEXT_OBJECT_INT.3 34f66b889dSEnji CooperMLINKS+= snmpmod.3 NEXT_OBJECT_INT_LINK.3 35f66b889dSEnji CooperMLINKS+= snmpmod.3 NEXT_OBJECT_INT_LINK_INDEX.3 36f66b889dSEnji CooperMLINKS+= snmpmod.3 NEXT_OBJECT_OID.3 37f66b889dSEnji CooperMLINKS+= snmpmod.3 NEXT_OBJECT_OID_LINK.3 38f66b889dSEnji CooperMLINKS+= snmpmod.3 NEXT_OBJECT_OID_LINK_INDEX.3 39f66b889dSEnji CooperMLINKS+= snmpmod.3 bsnmpd_get_target_stats.3 40f66b889dSEnji CooperMLINKS+= snmpmod.3 bsnmpd_get_usm_stats.3 41f66b889dSEnji CooperMLINKS+= snmpmod.3 bsnmpd_reset_usm_stats.3 42f66b889dSEnji CooperMLINKS+= snmpmod.3 buf_alloc.3 43f66b889dSEnji CooperMLINKS+= snmpmod.3 buf_size.3 44f66b889dSEnji CooperMLINKS+= snmpmod.3 comm_define.3 45f66b889dSEnji CooperMLINKS+= snmpmod.3 community.3 46f66b889dSEnji CooperMLINKS+= snmpmod.3 fd_deselect.3 47f66b889dSEnji CooperMLINKS+= snmpmod.3 fd_resume.3 48f66b889dSEnji CooperMLINKS+= snmpmod.3 fd_select.3 49f66b889dSEnji CooperMLINKS+= snmpmod.3 fd_suspend.3 50f66b889dSEnji CooperMLINKS+= snmpmod.3 get_ticks.3 51f66b889dSEnji CooperMLINKS+= snmpmod.3 index_append.3 52f66b889dSEnji CooperMLINKS+= snmpmod.3 index_append_off.3 53f66b889dSEnji CooperMLINKS+= snmpmod.3 index_compare.3 54f66b889dSEnji CooperMLINKS+= snmpmod.3 index_compare_off.3 55f66b889dSEnji CooperMLINKS+= snmpmod.3 index_decode.3 56f66b889dSEnji CooperMLINKS+= snmpmod.3 ip_commit.3 57f66b889dSEnji CooperMLINKS+= snmpmod.3 ip_get.3 58f66b889dSEnji CooperMLINKS+= snmpmod.3 ip_rollback.3 59f66b889dSEnji CooperMLINKS+= snmpmod.3 ip_save.3 60f66b889dSEnji CooperMLINKS+= snmpmod.3 or_register.3 61f66b889dSEnji CooperMLINKS+= snmpmod.3 or_unregister.3 62f66b889dSEnji CooperMLINKS+= snmpmod.3 oid_commit.3 63f66b889dSEnji CooperMLINKS+= snmpmod.3 oid_get.3 64f66b889dSEnji CooperMLINKS+= snmpmod.3 oid_rollback.3 65f66b889dSEnji CooperMLINKS+= snmpmod.3 oid_save.3 66f66b889dSEnji CooperMLINKS+= snmpmod.3 oid_usmNotInTimeWindows.3 67f66b889dSEnji CooperMLINKS+= snmpmod.3 oid_usmUnknownEngineIDs.3 68f66b889dSEnji CooperMLINKS+= snmpmod.3 oid_zeroDotZero.3 69f66b889dSEnji CooperMLINKS+= snmpmod.3 reqid_allocate.3 70f66b889dSEnji CooperMLINKS+= snmpmod.3 reqid_base.3 71f66b889dSEnji CooperMLINKS+= snmpmod.3 reqid_istype.3 72f66b889dSEnji CooperMLINKS+= snmpmod.3 reqid_next.3 73f66b889dSEnji CooperMLINKS+= snmpmod.3 reqid_type.3 74f66b889dSEnji CooperMLINKS+= snmpmod.3 snmp_input_finish.3 75f66b889dSEnji CooperMLINKS+= snmpmod.3 snmp_input_start.3 76f66b889dSEnji CooperMLINKS+= snmpmod.3 snmp_output.3 77f66b889dSEnji CooperMLINKS+= snmpmod.3 snmp_pdu_auth_access.3 78f66b889dSEnji CooperMLINKS+= snmpmod.3 snmp_send_port.3 79f66b889dSEnji CooperMLINKS+= snmpmod.3 snmp_send_trap.3 80f66b889dSEnji CooperMLINKS+= snmpmod.3 snmpd_target_stat.3 81f66b889dSEnji CooperMLINKS+= snmpmod.3 snmpd_usmstats.3 82f66b889dSEnji CooperMLINKS+= snmpmod.3 start_tick.3 83f66b889dSEnji CooperMLINKS+= snmpmod.3 string_commit.3 84f66b889dSEnji CooperMLINKS+= snmpmod.3 string_free.3 85f66b889dSEnji CooperMLINKS+= snmpmod.3 string_get.3 86f66b889dSEnji CooperMLINKS+= snmpmod.3 string_get_max.3 87f66b889dSEnji CooperMLINKS+= snmpmod.3 string_rollback.3 88f66b889dSEnji CooperMLINKS+= snmpmod.3 string_save.3 89f66b889dSEnji CooperMLINKS+= snmpmod.3 systemg.3 90f66b889dSEnji CooperMLINKS+= snmpmod.3 this_tick.3 91f66b889dSEnji CooperMLINKS+= snmpmod.3 timer_start.3 92f66b889dSEnji CooperMLINKS+= snmpmod.3 timer_start_repeat.3 93f66b889dSEnji CooperMLINKS+= snmpmod.3 timer_stop.3 94f66b889dSEnji CooperMLINKS+= snmpmod.3 target_activate_address.3 95f66b889dSEnji CooperMLINKS+= snmpmod.3 target_address.3 96f66b889dSEnji CooperMLINKS+= snmpmod.3 target_delete_address.3 97f66b889dSEnji CooperMLINKS+= snmpmod.3 target_delete_notify.3 98f66b889dSEnji CooperMLINKS+= snmpmod.3 target_delete_param.3 99f66b889dSEnji CooperMLINKS+= snmpmod.3 target_first_address.3 100f66b889dSEnji CooperMLINKS+= snmpmod.3 target_first_notify.3 101f66b889dSEnji CooperMLINKS+= snmpmod.3 target_first_param.3 102f66b889dSEnji CooperMLINKS+= snmpmod.3 target_flush_all.3 103f66b889dSEnji CooperMLINKS+= snmpmod.3 target_next_address.3 104f66b889dSEnji CooperMLINKS+= snmpmod.3 target_next_notify.3 105f66b889dSEnji CooperMLINKS+= snmpmod.3 target_next_param.3 106f66b889dSEnji CooperMLINKS+= snmpmod.3 target_new_address.3 107f66b889dSEnji CooperMLINKS+= snmpmod.3 target_new_notify.3 108f66b889dSEnji CooperMLINKS+= snmpmod.3 target_new_param.3 109f66b889dSEnji CooperMLINKS+= snmpmod.3 target_notify.3 110f66b889dSEnji CooperMLINKS+= snmpmod.3 target_param.3 111f66b889dSEnji CooperMLINKS+= snmpmod.3 usm_delete_user.3 112f66b889dSEnji CooperMLINKS+= snmpmod.3 usm_find_user.3 113f66b889dSEnji CooperMLINKS+= snmpmod.3 usm_first_user.3 114f66b889dSEnji CooperMLINKS+= snmpmod.3 usm_flush_users.3 115f66b889dSEnji CooperMLINKS+= snmpmod.3 usm_next_user.3 116f66b889dSEnji CooperMLINKS+= snmpmod.3 usm_new_user.3 117f66b889dSEnji CooperMLINKS+= snmpmod.3 usm_user.3 118f66b889dSEnji Cooper 11992ba581cSHartmut BrandtFILESGROUPS= BMIBS DEFS 12091a2f929SHartmut Brandt 12192ba581cSHartmut BrandtBMIBS= FOKUS-MIB.txt BEGEMOT-MIB.txt BEGEMOT-SNMPD.txt 122a0f13910SHartmut BrandtBMIBSDIR= ${SHAREDIR}/snmp/mibs 12391a2f929SHartmut BrandtDEFS= tree.def 124a0f13910SHartmut BrandtDEFSDIR= ${SHAREDIR}/snmp/defs 12591a2f929SHartmut Brandt 1265f892a7fSTom RhodesCFLAGS+= -I${CONTRIB}/lib -I${CONTRIB}/snmpd -I. -DUSE_LIBBEGEMOT 1277a775b30SHartmut BrandtCFLAGS+= -DHAVE_STDINT_H -DHAVE_INTTYPES_H -DHAVE_ERR_H -DHAVE_STRLCPY 12853c167f9SEnji CooperLIBADD= begemot bsnmp 12991a2f929SHartmut Brandt 1301c706be0SShteryana ShopovaLDFLAGS= -Wl,-export-dynamic 131b6a6dd18SHartmut Brandt 132135f7de5SShteryana Shopova.if ${MK_OPENSSL} != "no" 133135f7de5SShteryana ShopovaCFLAGS+= -DHAVE_LIBCRYPTO 134135f7de5SShteryana Shopova.endif 135135f7de5SShteryana Shopova 13653c167f9SEnji Cooper.if ${MK_TCP_WRAPPERS} != "no" 13753c167f9SEnji CooperCFLAGS+= -DUSE_TCPWRAPPERS 13853c167f9SEnji CooperLIBADD+= wrap 13953c167f9SEnji Cooper.endif 14053c167f9SEnji Cooper 1411e1c4c13SHartmut Brandtoid.h: tree.def Makefile 142*8e9b3e70SHartmut Brandt gensnmptree -I${CONTRIB}/lib -e ${XSYM} < ${.ALLSRC:M*.def} > ${.TARGET} 143b6a6dd18SHartmut Brandt 144b6a6dd18SHartmut Brandt.ORDER: tree.c tree.h 14592edc966SBryan Drewerytree.h: .NOMETA 146b6a6dd18SHartmut Brandttree.c tree.h: tree.def 147*8e9b3e70SHartmut Brandt gensnmptree -I${CONTRIB}/lib -l -f < ${.ALLSRC} 14891a2f929SHartmut Brandt 14916b2454cSHartmut BrandtMANFILTER= sed -e 's%@MODPATH@%${LIBDIR}/%g' \ 15016b2454cSHartmut Brandt -e 's%@DEFPATH@%${DEFSDIR}/%g' \ 15116b2454cSHartmut Brandt -e 's%@MIBSPATH@%${BMIBSDIR}/%g' 15216b2454cSHartmut Brandt 15391a2f929SHartmut Brandt.include <bsd.prog.mk> 154