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.

143 lines
3.5 KiB

  1. #
  2. # Copyright (C) 2006-2016 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:=kismet
  9. PKG_VERSION:=2016-07-R1
  10. PKG_RELEASE:=5
  11. PKG_LICENSE:=LGPLv2.1
  12. PKG_CPE_ID:=cpe:/a:kismet:kismet
  13. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  14. PKG_SOURCE_URL:=http://www.kismetwireless.net/code
  15. PKG_HASH:=bdb21f153311f1ff3b16621bf0d6740f66369bf0982b0a289c9a12af8847e237
  16. include $(INCLUDE_DIR)/uclibc++.mk
  17. include $(INCLUDE_DIR)/package.mk
  18. define Package/kismet/Default
  19. SECTION:=net
  20. CATEGORY:=Network
  21. TITLE:=Kismet
  22. MAINTAINER:=Jean-Michel lacroix <lacroix@lepine-lacroix.info>
  23. DEPENDS:= $(CXX_DEPENDS) +libnl
  24. URL:=http://www.kismetwireless.net/
  25. SUBMENU:=Wireless
  26. endef
  27. define Package/kismet/Default/description
  28. An 802.11 layer2 wireless network detector, sniffer, and intrusion
  29. detection system.
  30. endef
  31. define Package/kismet-client/conffiles
  32. /etc/kismet/kismet.conf
  33. endef
  34. define Package/kismet-drone/conffiles
  35. /etc/config/kismet_drone
  36. /etc/kismet/kismet_drone.conf
  37. endef
  38. define Package/kismet-server/conffiles
  39. /etc/config/kismet_server
  40. /etc/kismet/kismet.conf
  41. endef
  42. define Package/kismet-client
  43. $(call Package/kismet/Default)
  44. TITLE+= client
  45. DEPENDS+= +libncurses
  46. endef
  47. define Package/kismet-client/description
  48. $(call Package/kismet/Default/description)
  49. This package contains the kismet text interface client.
  50. endef
  51. define Package/kismet-drone
  52. $(call Package/kismet/Default)
  53. DEPENDS+= +libpcap +libpcre +libcap +wireless-tools
  54. TITLE+= drone
  55. endef
  56. define Package/kismet-drone/description
  57. $(call Package/kismet/Default/description)
  58. This package contains the kismet remote sniffing.and monitoring drone.
  59. endef
  60. define Package/kismet-server
  61. $(call Package/kismet/Default)
  62. DEPENDS+= +libpcap +libpcre +libcap +wireless-tools
  63. TITLE+= server
  64. endef
  65. define Package/kismet-server/description
  66. $(call Package/kismet/Default/description)
  67. This package contains the kismet server.
  68. endef
  69. CONFIGURE_ARGS += \
  70. --sysconfdir=/etc/kismet \
  71. CONFIGURE_VARS += \
  72. CXXFLAGS="$$$$CXXFLAGS -fno-rtti" \
  73. LIBS="-lm" \
  74. CLIENTCLIBS="-lm"
  75. define Build/Compile
  76. $(MAKE) -C $(PKG_BUILD_DIR) \
  77. LD="$(TARGET_CXX)" \
  78. all
  79. endef
  80. define Package/kismet/install
  81. $(INSTALL_DIR) $(1)/usr/bin/
  82. $(INSTALL_BIN) $(PKG_BUILD_DIR)/scripts/kismet $(1)/usr/bin/kismet
  83. endef
  84. define Package/kismet-client/install
  85. $(INSTALL_DIR) $(1)/usr/bin
  86. $(INSTALL_BIN) $(PKG_BUILD_DIR)/kismet_client $(1)/usr/bin/
  87. $(INSTALL_DIR) $(1)/etc/kismet/
  88. $(INSTALL_CONF) ./files/kismet.conf $(1)/etc/kismet/
  89. endef
  90. define Package/kismet-drone/install
  91. $(INSTALL_DIR) $(1)/usr/bin
  92. $(INSTALL_BIN) $(PKG_BUILD_DIR)/kismet_drone $(1)/usr/bin/
  93. $(INSTALL_DIR) $(1)/etc/kismet/
  94. $(INSTALL_CONF) ./files/kismet_drone.conf $(1)/etc/kismet/
  95. $(INSTALL_DIR) $(1)/etc/config
  96. $(INSTALL_CONF) ./files/kismet_drone.config $(1)/etc/config/kismet_drone
  97. $(INSTALL_DIR) $(1)/etc/init.d
  98. $(INSTALL_BIN) ./files/kismet_drone.init $(1)/etc/init.d/kismet_drone
  99. endef
  100. define Package/kismet-server/install
  101. $(INSTALL_DIR) $(1)/usr/bin
  102. $(INSTALL_BIN) $(PKG_BUILD_DIR)/kismet_server $(1)/usr/bin/
  103. $(INSTALL_DIR) $(1)/etc/kismet/
  104. $(INSTALL_CONF) ./files/kismet.conf $(1)/etc/kismet/
  105. $(INSTALL_DIR) $(1)/etc/config
  106. $(INSTALL_CONF) ./files/kismet_server.config $(1)/etc/config/kismet_server
  107. $(INSTALL_DIR) $(1)/etc/init.d
  108. $(INSTALL_BIN) ./files/kismet_server.init $(1)/etc/init.d/kismet_server
  109. endef
  110. $(eval $(call BuildPackage,kismet-client))
  111. $(eval $(call BuildPackage,kismet-drone))
  112. $(eval $(call BuildPackage,kismet-server))