nuke $Id$ in /packages as well
[openwrt/svn-archive/archive.git] / net / nprobe / Makefile
1 #
2 # Copyright (C) 2006 OpenWrt.org
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:=nprobe
11 PKG_VERSION:=4.1
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=nProbe-$(PKG_VERSION).tgz
15 PKG_SOURCE_URL:=http://downloads.openwrt.org/sources
16 PKG_MD5SUM:=32ed12f60eab771a79bd5f90622fa2a3
17
18 BUILD_DEPENDS:=libwrap
19
20 PKG_BUILD_DIR:=$(BUILD_DIR)/nProbe
21
22 include $(INCLUDE_DIR)/package.mk
23
24 define Package/nprobe
25 SECTION:=utils
26 CATEGORY:=Utilities
27 DEPENDS:=+libpcap +libpcre +libpthread +NPROBE_MYSQL_SUPPORT:libmysqlclient
28 TITLE:=nProbe
29 URL:=http://invisible-island.net/dialog/
30 endef
31
32 define Package/nprobe/config
33 config NPROBE_MYSQL_SUPPORT
34 depends on PACKAGE_nprobe
35 bool "MySQL support"
36
37 endef
38
39 define Package/nprobe/description
40 nprobe
41 endef
42
43 ifndef CONFIG_NPROBE_MYSQL_SUPPORT
44 CONFIGURE_VARS += ac_cv_prog_MYSQL=no
45 endif
46
47 define Build/Configure
48 # patch creates these, so we make them executable
49 chmod +x $(PKG_BUILD_DIR)/configure
50 chmod +x $(PKG_BUILD_DIR)/config.guess
51 $(call Build/Configure/Default, \
52 --with-only-ipv4 \
53 PCAP_ROOT="$(STAGING_DIR)/usr" \
54 )
55 endef
56
57 define Build/Compile
58 DESTDIR=$(PKG_INSTALL_DIR) \
59 LDFLAGS="$(TARGET_LDFLAGS) -ldl" \
60 $(MAKE) -C $(PKG_BUILD_DIR) \
61 all install
62 endef
63
64 define Package/nprobe/install
65 $(INSTALL_DIR) $(1)/usr/bin
66 $(INSTALL_DIR) $(1)/usr/lib
67 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/nprobe \
68 $(1)/usr/bin/
69 $(CP) -a $(PKG_INSTALL_DIR)/usr/lib/*.so* \
70 $(1)/usr/lib
71 endef
72
73 $(eval $(call BuildPackage,nprobe))
74