Port scdp to -ng
[openwrt/svn-archive/archive.git] / net / scdp / Makefile
1 #
2 # Copyright (C) 2006 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=scdp
12 PKG_VERSION:=1.0b
13 PKG_RELEASE:=1
14 PKG_MD5SUM:=7eafaf5a422e37d04715613993ed5d95
15
16 PKG_SOURCE_URL:=@SF/scdp
17 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
18 PKG_CAT:=zcat
19
20 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
21 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/scdp
26 SECTION:=net
27 CATEGORY:=Network
28 DEPENDS:=+libnet
29 TITLE:=An utility to send CDP (Cisco Discovery Protocol) packets
30 DESCRIPTION:=This program sends CDP (Cisco Discovery Protocol) packets out on\\\
31 selected interfaces and tells the connected switch (cisco only)\\\
32 where the host is connected.\\\
33 URL:=http://sourceforge.net/projects/scdp
34 endef
35
36 define Build/Configure
37 $(call Build/Configure/Default,--enable-shared)
38 endef
39
40 define Build/Compile
41 rm -rf $(PKG_INSTALL_DIR)/
42 mkdir -p $(PKG_INSTALL_DIR)/
43 $(MAKE) -C $(PKG_BUILD_DIR) \
44 DESTDIR=$(PKG_INSTALL_DIR) \
45 all install
46 endef
47
48 define Package/scdp/install
49 install -d -m0755 $(1)/usr/bin
50 $(CP) $(PKG_INSTALL_DIR)/usr/bin/scdp $(1)/usr/bin/
51 endef
52
53 $(eval $(call BuildPackage,scdp))