Changeset 20956


Ignore:
Timestamp:
2010-04-17T18:49:59+02:00 (7 years ago)
Author:
nico
Message:

[packages] mini_snmpd: build 2 variants, one for IPv4 and one for IPv6

File:
1 edited

Legend:

Unmodified
Added
Removed
  • packages/net/mini_snmpd/Makefile

    r20955 r20956  
    11# 
    2 # Copyright (C) 2010 OpenWrt.org 
     2# Copyright (C) 2009-2010 OpenWrt.org 
    33# 
    44# This is free software, licensed under the GNU General Public License v2. 
     
    1010PKG_NAME:=mini_snmpd 
    1111PKG_VERSION:=1.0 
    12 PKG_RELEASE:=6 
     12PKG_RELEASE:=7 
    1313 
    1414PKG_SOURCE:=mini_snmpd.tar.gz 
     
    1616PKG_MD5SUM:=13f2202ff01ff6b6463989f34f453063 
    1717 
    18 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) 
     18PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME) 
    1919 
    2020include $(INCLUDE_DIR)/package.mk 
    2121 
     22define Package/mini-snmpd/Default 
     23  TITLE:=SNMP server for embedded systems 
     24  URL:=http://members.aon.at/linuxfreak/linux/mini_snmpd.html 
     25endef 
     26 
    2227define Package/mini-snmpd 
     28$(call Package/mini-snmpd/Default) 
    2329  SECTION:=net 
    2430  CATEGORY:=Network 
    25   TITLE:=SNMP server for embedded systems 
    26   URL:=http://members.aon.at/linuxfreak/linux/mini_snmpd.html 
    27   DEPENDS:=+IPV6:kmod-ipv6 
     31  TITLE+= (IPv4 only) 
     32  VARIANT:=ipv4 
     33endef 
     34 
     35define Package/mini-snmpd6 
     36$(call Package/mini-snmpd/Default) 
     37  SECTION:=ipv6 
     38  CATEGORY:=IPv6 
     39  TITLE+= (IPv6 only) 
     40  VARIANT:=ipv6 
     41  DEPENDS:=+kmod-ipv6 
    2842endef 
    2943 
    3044 
     45PKG_OFLAGS:=$(TARGET_CFLAGS) -DSYSLOG 
     46ifeq ($(BUILD_VARIANT),ipv6) 
     47  PKG_OFLAGS+= -DIPV6 
     48endif 
     49 
    3150MAKE_FLAGS+= \ 
     51        OFLAGS="$(PKG_OFLAGS)" \ 
    3252        STRIP="/bin/true" \ 
    3353        INSTALL_ROOT="$(PKG_INSTALL_DIR)" \ 
    3454        mini_snmpd install 
    35  
    36 ifeq ($(CONFIG_IPV6),y) 
    37 MAKE_FLAGS+= OFLAGS="$(TARGET_CFLAGS) -DSYSLOG -DIPV6" 
    38 else 
    39 MAKE_FLAGS+= OFLAGS="$(TARGET_CFLAGS) -DSYSLOG" 
    40 endif 
    4155 
    4256define Package/mini-snmpd/install 
     
    4963endef 
    5064 
     65Package/mini-snmpd6/install=$(Package/mini-snmpd/install) 
     66 
    5167$(eval $(call BuildPackage,mini-snmpd)) 
     68$(eval $(call BuildPackage,mini-snmpd6)) 
Note: See TracChangeset for help on using the changeset viewer.