You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

122 lines
3.4 KiB

  1. #
  2. # Copyright (C) 2006-2015 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=aircrack-ng
  9. PKG_VERSION:=1.5.2
  10. PKG_RELEASE:=$(PKG_SOURCE_VERSION)
  11. PKG_LICENSE:=GPL-2.0
  12. PKG_LICENSE_FILES:=LICENSE
  13. PKG_CPE_ID:=cpe:/a:aircrack-ng:aircrack-ng
  14. PKG_SOURCE_PROTO:=git
  15. PKG_SOURCE_URL:=https://github.com/aircrack-ng/aircrack-ng.git
  16. PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
  17. PKG_SOURCE_VERSION:=42f2b48d7f46b39e0d5d2f2a64cbf63f87416a70
  18. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.xz
  19. PKG_MIRROR_HASH:=17893e05278635675a77a3cb0927202ec4df2fc9a742689a7a88e4a8f27a69b6
  20. PKG_BUILD_PARALLEL:=1
  21. PKG_INSTALL:=1
  22. PKG_MAINTAINER:=Rick Farina <zerochaos@gentoo.org>
  23. PKG_FIXUP:=autoreconf
  24. PKG_CONFIG_DEPENDS:= \
  25. CONFIG_AIRCRACK_NG_GCRYPT \
  26. CONFIG_AIRCRACK_NG_OPENSSL \
  27. \
  28. CONFIG_AIRCRACK_NG_OPTIMIZE_SPEED \
  29. \
  30. CONFIG_AIRCRACK_NG_HWLOC \
  31. CONFIG_AIRCRACK_NG_SQLITE3
  32. include $(INCLUDE_DIR)/uclibc++.mk
  33. include $(INCLUDE_DIR)/package.mk
  34. define Package/aircrack-ng
  35. SECTION:=net
  36. CATEGORY:=Network
  37. DEPENDS:=+AIRCRACK_NG_HWLOC:libhwloc +libpcap +libpcre +libpthread $(CXX_DEPENDS)
  38. DEPENDS += +AIRCRACK_NG_OPENSSL:libopenssl
  39. DEPENDS += +AIRCRACK_NG_GCRYPT:libgcrypt
  40. DEPENDS += +AIRCRACK_NG_SQLITE3:libsqlite3
  41. DEPENDS += +libnl-core +libnl-genl +zlib
  42. TITLE:=WLAN tools (without airmon-ng) for breaking 802.11 WEP/WPA keys
  43. URL:=https://www.aircrack-ng.org/
  44. SUBMENU:=Wireless
  45. endef
  46. define Package/aircrack-ng/description
  47. WLAN tools for breaking 802.11 WEP/WPA keys
  48. endef
  49. define Package/aircrack-ng/config
  50. source "$(SOURCE)/Config.in"
  51. endef
  52. define Package/airmon-ng
  53. SECTION:=net
  54. CATEGORY:=Network
  55. DEPENDS:=+wireless-tools +ethtool +procps-ng +CONFIG_PCI_SUPPORT:pciutils +CONFIG_USB_SUPPORT:usbutils
  56. TITLE:=Bash script designed to turn wireless cards into monitor mode.
  57. URL:=http://www.aircrack-ng.org/
  58. SUBMENU:=Wireless
  59. endef
  60. define Package/airmon-ng/description
  61. Bash script designed to turn wireless cards into monitor mode.
  62. endef
  63. define Build/Prepare
  64. $(call Build/Prepare/Default)
  65. echo "$(PKG_VERSION)_rev$(PKG_SOURCE_VERSION)" > $(PKG_BUILD_DIR)/VERSION
  66. endef
  67. CONFIGURE_ARGS += \
  68. --disable-silent-rules \
  69. --enable-shared \
  70. --with-experimental \
  71. --with-libpcap-include=$(STAGING_DIR)/usr/include \
  72. --with-libpcap-lib=$(STAGING_DIR)/usr/lib \
  73. --without-opt \
  74. \
  75. PYTHON=$(PYTHON) \
  76. \
  77. $(if $(CONFIG_AIRCRACK_NG_OPENSSL),,--without-openssl) \
  78. $(if $(CONFIG_AIRCRACK_NG_GCRYPT),--with-gcrypt,--without-gcrypt) \
  79. $(if $(CONFIG_AIRCRACK_NG_HWLOC),--enable-hwloc,--disable-hwloc) \
  80. $(if $(CONFIG_AIRCRACK_NG_SQLITE3),--with-sqlite3=$(STAGING_DIR)/usr,--without-sqlite3)
  81. TARGET_CFLAGS += -Wall -Wextra -ffunction-sections -fdata-sections
  82. ifeq ($(CONFIG_AIRCRACK_NG_OPTIMIZE_SPEED),y)
  83. TARGET_CFLAGS := $(filter-out -O%,$(TARGET_CFLAGS)) -O3
  84. endif
  85. TARGET_LDFLAGS+= \
  86. -Wl,--gc-sections
  87. define Package/aircrack-ng/install
  88. $(INSTALL_DIR) $(1)/usr/bin
  89. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
  90. $(INSTALL_DIR) $(1)/usr/sbin
  91. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/* $(1)/usr/sbin/
  92. $(INSTALL_DIR) $(1)/usr/lib
  93. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/* $(1)/usr/lib/
  94. rm -f $(1)/usr/sbin/airmon-ng
  95. endef
  96. define Package/airmon-ng/install
  97. $(INSTALL_DIR) $(1)/usr/sbin
  98. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/airmon-ng $(1)/usr/sbin/
  99. endef
  100. $(eval $(call BuildPackage,aircrack-ng))
  101. $(eval $(call BuildPackage,airmon-ng))