1937fd3baa9a3e3bce6e7a91fb9ae419abe1bc1a
[packages.git] / net / l7-protocols / Makefile
1 include $(TOPDIR)/rules.mk
2
3 PKG_NAME:=l7-protocols
4 PKG_VERSION:=2007-11-22
5 PKG_RELEASE:=1
6
7 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
8 PKG_SOURCE_URL:=@SF/l7-filter
9 PKG_MD5SUM:=162c988422fec85e1f1c24417a2c600c
10
11 include $(INCLUDE_DIR)/package.mk
12
13 define Package/l7-protocols
14   SECTION:=net
15   CATEGORY:=Network
16   TITLE:=Protocols for layer7 filtering
17   URL:=http://l7-filter.sourceforge.net/
18   SUBMENU:=layer7
19   DEPENDS:=iptables-mod-filter
20 endef
21
22 define Package/l7-protocols/description
23        l7-filter classifies packets based on patterns in application
24        layer data. This allows correct classification of P2P traffic that
25        uses unpredictable ports as well as standard protocols running on
26        non-standard ports.
27 endef
28
29 define Package/l7-protocols-testing
30         $(call Package/l7-protocols)
31     TITLE:=testing utilities for layer7
32         DEPENDS+=l7-protocols +uclibcxx
33 endef
34
35 define Package/l7-protocols-testing/description
36         testing utilities for layer 7 patterns
37 endef
38
39 define Build/Configure
40 endef
41
42 ifneq ($(SDK)$(CONFIG_PACKAGE_l7-protocols-testing),)
43   define Build/Compile
44         cd $(PKG_BUILD_DIR)/testing && $(MAKE) $(TARGET_CONFIGURE_OPTS) CXX="$(STAGING_DIR)/usr/bin/g++-uc"
45   endef
46 else
47   define Build/Compile
48   endef
49 endif
50
51 define Package/l7-protocols/install
52         $(INSTALL_DIR) $(1)/etc/l7-protocols
53         $(CP) $(PKG_BUILD_DIR)/example_traffic \
54                 $(PKG_BUILD_DIR)/extra \
55                 $(PKG_BUILD_DIR)/file_types \
56                 $(PKG_BUILD_DIR)/groups.sh \
57                 $(PKG_BUILD_DIR)/malware \
58                 $(PKG_BUILD_DIR)/protocols \
59                 $(1)/etc/l7-protocols
60 endef
61
62 define Package/l7-protocols-testing/install
63         $(INSTALL_DIR) $(1)/etc/l7-protocols/testing
64         $(CP) $(PKG_BUILD_DIR)/testing/data \
65                 $(1)/etc/l7-protocols/testing
66         $(INSTALL_BIN) \
67                 $(PKG_BUILD_DIR)/testing/rand{chars,printable} \
68                 $(PKG_BUILD_DIR)/testing/test_speed-{kernel,userspace} \
69                 $(PKG_BUILD_DIR)/testing/match_kernel \
70                 $(PKG_BUILD_DIR)/testing/doallspeeds.sh \
71                 $(PKG_BUILD_DIR)/testing/test_match.sh \
72                 $(PKG_BUILD_DIR)/testing/timeit.sh \
73                 $(1)/etc/l7-protocols/testing
74 endef
75
76 $(eval $(call BuildPackage,l7-protocols))
77 $(eval $(call BuildPackage,l7-protocols-testing))