0970444903c1b68264ff79c9c05a6dd3a49caa89
[packages.git] / net / nagios-plugins / 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 # $Id: $
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=nagios-plugins
12 PKG_VERSION:=1.4.6
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=@SF/nagiosplug
17 PKG_MD5SUM:=ea79fa91092d709aa6b2e732b1d55541
18 PKG_CAT:=zcat
19
20 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
21
22 include $(INCLUDE_DIR)/package.mk
23
24 define Package/nagios-plugins
25   SECTION:=net
26   CATEGORY:=Network
27   DEPENDS:=uclibcxx
28   TITLE:=plugins for Nagios checks
29   URL:=http://nagiosplug.sourceforge.net/
30 endef
31
32 define Build/Configure
33         $(call Build/Configure/Default, \
34                 --without-mysql \
35                 --with-openssl="$(STAGING_DIR)/usr" \
36                 --with-ping-command="/bin/ping -c %d %s" \
37                 --with-ps-command="/bin/ps -Aopid" \
38                 --with-ps-cols="5" \
39                 --with-ps-format="%d %s %d %s %n" \
40                 --with-uptime-command="/usr/bin/uptime" \
41                 --with-ssh-command="/usr/bin/ssh" \
42                 --with-nslookup-command="/usr/bin/nslookup" \
43                 , \
44         )
45 endef
46
47 define Build/Compile
48         $(call Build/Compile/Default,\
49                 DESTDIR="$(PKG_INSTALL_DIR)" \
50                 all install \
51         )
52 endef
53
54 define Package/nagios-plugins/install
55         $(INSTALL_DIR) $(1)/usr/libexec/nagios
56         $(CP) $(PKG_INSTALL_DIR)/usr/lib/* $(1)/usr/libexec/nagios/
57 endef
58
59 $(eval $(call BuildPackage,nagios-plugins))