From 697a83a4c1ff2af6f82fce21437990cbb89dc954 Mon Sep 17 00:00:00 2001 From: nico Date: Sat, 31 Jan 2009 16:25:41 +0000 Subject: [PATCH] [packages] add mini_snmpd, an SNMP server for embedded devices git-svn-id: svn://svn.openwrt.org/openwrt/packages@14314 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- net/mini_snmpd/Makefile | 42 ++++++++++++++++++++++ net/mini_snmpd/patches/101-opt_flags.patch | 13 +++++++ 2 files changed, 55 insertions(+) create mode 100644 net/mini_snmpd/Makefile create mode 100644 net/mini_snmpd/patches/101-opt_flags.patch diff --git a/net/mini_snmpd/Makefile b/net/mini_snmpd/Makefile new file mode 100644 index 000000000..a2679bd28 --- /dev/null +++ b/net/mini_snmpd/Makefile @@ -0,0 +1,42 @@ +# +# Copyright (C) 2009 OpenWrt.orgv +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# +# $Id$ + +include $(TOPDIR)/rules.mk + +PKG_NAME:=mini_snmpd +PKG_RELEASE:=1 + +PKG_SOURCE:=mini_snmpd.tar.gz +PKG_SOURCE_URL:=http://members.aon.at/linuxfreak/linux/ +PKG_MD5SUM:=13f2202ff01ff6b6463989f34f453063 + +include $(INCLUDE_DIR)/package.mk + +define Package/mini-snmpd + SECTION:=net + CATEGORY:=Network + TITLE:=SNMP server for embedded systems + URL:=http://members.aon.at/linuxfreak/linux/mini_snmpd.html +endef + + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) \ + CC="$(TARGET_CC)" \ + OFLAGS="$(TARGET_CFLAGS)" \ + STRIP="/bin/true" \ + INSTALL_ROOT="$(PKG_INSTALL_DIR)" \ + mini_snmpd install +endef + +define Package/mini-snmpd/install + $(INSTALL_DIR) $(1)/sbin + $(CP) $(PKG_INSTALL_DIR)/sbin/mini_snmpd $(1)/sbin/ +endef + +$(eval $(call BuildPackage,mini-snmpd)) diff --git a/net/mini_snmpd/patches/101-opt_flags.patch b/net/mini_snmpd/patches/101-opt_flags.patch new file mode 100644 index 000000000..b34852f16 --- /dev/null +++ b/net/mini_snmpd/patches/101-opt_flags.patch @@ -0,0 +1,13 @@ +--- a/Makefile ++++ b/Makefile +@@ -30,8 +30,9 @@ HEADERS = mini_snmpd.h + SOURCES = mini_snmpd.c protocol.c mib.c globals.c utils.c linux.c freebsd.c + VERSION = 1.0 + VENDOR = .1.3.6.1.4.1 ++OFLAGS = -O2 -DDEBUG + CFLAGS = -Wall -Werror -DVERSION="\"$(VERSION)\"" -DVENDOR="\"$(VENDOR)\"" \ +- -O2 -DDEBUG -D__LINUX__ -D__DEMO__ ++ $(OFLAGS) -D__LINUX__ -D__DEMO__ + TARGET = mini_snmpd + MAN = mini_snmpd.8 + DOC = CHANGELOG COPYING README TODO