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.

142 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:=1
  11. PKG_LICENSE:=LGPLv2.1
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  13. PKG_SOURCE_URL:=http://www.kismetwireless.net/code
  14. PKG_HASH:=bdb21f153311f1ff3b16621bf0d6740f66369bf0982b0a289c9a12af8847e237
  15. PKG_BUILD_DEPENDS:=libpcap libncurses libpcre
  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/kismet/kismet_drone.conf
  36. endef
  37. define Package/kismet-server/conffiles
  38. /etc/kismet/kismet.conf
  39. endef
  40. define Package/kismet-client
  41. $(call Package/kismet/Default)
  42. TITLE+= client
  43. DEPENDS+= +libncurses
  44. endef
  45. define Package/kismet-client/description
  46. $(call Package/kismet/Default/description)
  47. This package contains the kismet text interface client.
  48. endef
  49. define Package/kismet-drone
  50. $(call Package/kismet/Default)
  51. DEPENDS+= +libpcap +libpcre +libcap +wireless-tools
  52. TITLE+= drone
  53. endef
  54. define Package/kismet-drone/description
  55. $(call Package/kismet/Default/description)
  56. This package contains the kismet remote sniffing.and monitoring drone.
  57. endef
  58. define Package/kismet-server
  59. $(call Package/kismet/Default)
  60. DEPENDS+= +libpcap +libpcre +libcap +wireless-tools
  61. TITLE+= server
  62. endef
  63. define Package/kismet-server/description
  64. $(call Package/kismet/Default/description)
  65. This package contains the kismet server.
  66. endef
  67. CONFIGURE_ARGS += \
  68. --sysconfdir=/etc/kismet \
  69. CONFIGURE_VARS += \
  70. CXXFLAGS="$$$$CXXFLAGS -fno-rtti" \
  71. LIBS="-lm" \
  72. CLIENTCLIBS="-lm"
  73. define Build/Compile
  74. $(MAKE) -C $(PKG_BUILD_DIR) \
  75. LD="$(TARGET_CXX)" \
  76. all
  77. endef
  78. define Package/kismet/install
  79. $(INSTALL_DIR) $(1)/usr/bin/
  80. $(INSTALL_BIN) $(PKG_BUILD_DIR)/scripts/kismet $(1)/usr/bin/kismet
  81. endef
  82. define Package/kismet-client/install
  83. $(INSTALL_DIR) $(1)/usr/bin
  84. $(INSTALL_BIN) $(PKG_BUILD_DIR)/kismet_client $(1)/usr/bin/
  85. $(INSTALL_DIR) $(1)/etc/kismet/
  86. $(INSTALL_CONF) ./files/kismet.conf $(1)/etc/kismet/
  87. endef
  88. define Package/kismet-drone/install
  89. $(INSTALL_DIR) $(1)/usr/bin
  90. $(INSTALL_BIN) $(PKG_BUILD_DIR)/kismet_drone $(1)/usr/bin/
  91. $(INSTALL_DIR) $(1)/etc/kismet/
  92. $(INSTALL_CONF) ./files/kismet_drone.conf $(1)/etc/kismet/
  93. $(INSTALL_DIR) $(1)/etc/config
  94. $(INSTALL_CONF) ./files/kismet_drone.config $(1)/etc/config/kismet_drone
  95. $(INSTALL_DIR) $(1)/etc/init.d
  96. $(INSTALL_BIN) ./files/kismet_drone.init $(1)/etc/init.d/kismet_drone
  97. endef
  98. define Package/kismet-server/install
  99. $(INSTALL_DIR) $(1)/usr/bin
  100. $(INSTALL_BIN) $(PKG_BUILD_DIR)/kismet_server $(1)/usr/bin/
  101. $(INSTALL_DIR) $(1)/etc/kismet/
  102. $(INSTALL_CONF) ./files/kismet.conf $(1)/etc/kismet/
  103. $(INSTALL_DIR) $(1)/etc/config
  104. $(INSTALL_CONF) ./files/kismet_server.config $(1)/etc/config/kismet_server
  105. $(INSTALL_DIR) $(1)/etc/init.d
  106. $(INSTALL_BIN) ./files/kismet_server.init $(1)/etc/init.d/kismet_server
  107. endef
  108. $(eval $(call BuildPackage,kismet-client))
  109. $(eval $(call BuildPackage,kismet-drone))
  110. $(eval $(call BuildPackage,kismet-server))