44844aab2b11c964a27a8722ac7426189aa7756a
[feed/telephony.git] / net / sngrep / Makefile
1 #
2 # Copyright (C) 2016 Daniel Engberg <daniel.engberg.lists@pyret.net>
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=sngrep
11
12 PKG_VERSION:=1.4.8
13 PKG_RELEASE:=1
14
15 PKG_MAINTAINER:=Sebastian Kemper <sebastian_ml@gmx.net>
16 PKG_LICENSE:=GPL-3.0+
17 PKG_LICENSE_FILES:=COPYING
18
19 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
20 PKG_SOURCE_URL:=https://github.com/irontec/sngrep/releases/download/v$(PKG_VERSION)
21 PKG_HASH:=f39fded8dc9ef0b7a41319f223dd4afa348bb2418bea578ed281557726829728
22
23 PKG_RELEASE:=1
24
25 PKG_MIRROR_HASH:=94e150cabe3efc6f07d05e3ee348806a0a8fa9335d27dfddce477988b946ed8f
26
27 PKG_FIXUP:=autoreconf
28 PKG_BUILD_PARALLEL:=1
29 PKG_INSTALL:=1
30
31 PKG_CONFIG_DEPENDS:=CONFIG_IPV6 CONFIG_SNGREP_ENABLE_EEP CONFIG_SNGREP_WITH_PCRE
32
33 include $(INCLUDE_DIR)/package.mk
34
35 define Package/sngrep
36 SECTION:=utils
37 CATEGORY:=Utilities
38 SUBMENU:=Telephony
39 DEPENDS:=+libncursesw +libopenssl +libpcap +SNGREP_WITH_PCRE:libpcre
40 TITLE:=Ncurses SIP messages flow viewer
41 URL:=https://github.com/irontec/sngrep
42 endef
43
44 define Package/sngrep/description
45 sngrep is a tool for displaying SIP calls message flows from terminal.
46
47 It supports live capture to display realtime SIP packets and can also be
48 used as PCAP viewer.
49 endef
50
51 define Package/sngrep/conffiles
52 /etc/sngreprc
53 endef
54
55 define Package/sngrep/config
56 menu "sngrep configuration"
57 depends on PACKAGE_sngrep
58
59 config SNGREP_ENABLE_EEP
60 bool "EEP/HEP support"
61 default y
62 help
63 Enable EEP/HEP support
64
65 config SNGREP_WITH_PCRE
66 bool "PCRE support"
67 default y
68 help
69 Enable Perl compatible regular expressions
70 endmenu
71 endef
72
73 CONFIGURE_ARGS += \
74 --$(if $(CONFIG_SNGREP_ENABLE_EEP),en,dis)able-eep \
75 --$(if $(CONFIG_IPV6),en,dis)able-ipv6 \
76 --enable-unicode \
77 --with-openssl \
78 --with$(if $(CONFIG_SNGREP_WITH_PCRE),,out)-pcre
79
80 define Package/sngrep/install
81 $(INSTALL_DIR) $(1)/etc
82 $(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/sngreprc $(1)/etc
83 $(INSTALL_DIR) $(1)/usr/bin
84 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/sngrep $(1)/usr/bin
85 endef
86
87 $(eval $(call BuildPackage,sngrep))