Port aircrack-ng to -ng, also update to latest version : 0.6
[packages.git] / net / aircrack-ng / Makefile
1 # Copyright (C) 2006 OpenWrt.org
2 #
3 # This is free software, licensed under the GNU General Public License v2.
4 # See /LICENSE for more information.
5 #
6 # $Id$
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=aircrack-ng
11 PKG_VERSION:=0.6
12 PKG_RELEASE:=1
13 PKG_MD5SUM:=6b85fe925c93c972f3d9f8170dce46c6
14
15 PKG_SOURCE_URL:=http://download.aircrack-ng.org
16 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
17 PKG_CAT:=zcat
18
19 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
20 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
21
22 include $(INCLUDE_DIR)/package.mk
23
24 define Package/aircrack-ng
25   SECTION:=net
26   CATEGORY:=Network
27   TITLE:=Aircrack-ng the next generation of aircrack with new features
28   DESCRIPTION:=Aircrack-ng the next generation of aircrack with new features
29   URL:=http://www.aircrack-ng.org
30 endef
31
32 define Build/Configure
33 endef
34
35 define Build/Compile
36         rm -rf $(PKG_INSTALL_DIR)
37         mkdir -p $(PKG_INSTALL_DIR)
38         $(MAKE) -C $(PKG_BUILD_DIR) \
39                 CC="$(TARGET_CC)" \
40                 CFLAGS="$(TARGET_CFLAGS) -Wall" \
41                 prefix="/usr" \
42                 destdir="$(PKG_INSTALL_DIR)" \
43         all install
44 endef
45
46 define Package/aircrack-ng/install
47         install -d -m0755 $(1)/usr/bin
48         $(CP) $(PKG_INSTALL_DIR)/usr/bin/aircrack-ng $(1)/usr/bin/
49         $(CP) $(PKG_INSTALL_DIR)/usr/bin/airdecap-ng $(1)/usr/bin/
50         $(CP) $(PKG_INSTALL_DIR)/usr/bin/arpforge-ng $(1)/usr/bin/
51         $(CP) $(PKG_INSTALL_DIR)/usr/bin/ivstools $(1)/usr/bin/
52         $(CP) $(PKG_INSTALL_DIR)/usr/bin/kstats $(1)/usr/bin/
53         install -d -m0755 $(1)/usr/sbin
54         $(CP) $(PKG_INSTALL_DIR)/usr/sbin/aireplay-ng $(1)/usr/sbin/
55         $(CP) $(PKG_INSTALL_DIR)/usr/sbin/airodump-ng $(1)/usr/sbin/
56         $(CP) $(PKG_INSTALL_DIR)/usr/sbin/airmon-ng $(1)/usr/sbin/
57 endef
58
59 $(eval $(call BuildPackage,aircrack-ng))