2 # Copyright (C) 2008 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
15 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
16 PKG_SOURCE_URL
:=@SF
/nagios
17 PKG_MD5SUM
:=8c3a29e138f2ff8c8abbd3dd8a40c4b6
19 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
21 include $(INCLUDE_DIR
)/package.mk
23 PKG_BUILD_DEPENDS
:=libnotimpl
29 DEPENDS
:=+libpthread
+microperl
+libltdl
30 TITLE
:=service and network monitoring program
31 URL
:=http
://www.nagios.org
/
34 define Package
/nagios
/description
35 service and network monitoring program
38 EXTRA_CFLAGS
+= -I
$(STAGING_DIR
)/usr
/include -I
$(STAGING_DIR
)/include
41 --with-nagios-user
="root" \
42 --with-nagios-group
="root" \
43 --sysconfdir
="/etc/nagios" \
46 CFLAGS
="$(TARGET_CFLAGS) $(EXTRA_CFLAGS)"
52 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
53 DESTDIR
="$(PKG_INSTALL_DIR)" \
56 all install install-config
59 define Package
/nagios
/install
60 $(INSTALL_DIR
) $(1)/etc
/nagios
61 $(INSTALL_DATA
) $(PKG_INSTALL_DIR
)/etc
/nagios
/* $(1)/etc
/nagios
/
62 $(INSTALL_DIR
) $(1)/usr
/bin
63 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/bin
/{nagios
,nagiostats
} $(1)/usr
/bin
/
64 $(INSTALL_DIR
) $(1)/usr
/sbin
65 $(INSTALL_BIN
) $(PKG_INSTALL_DIR
)/usr
/sbin
/* $(1)/usr
/sbin
/
66 $(INSTALL_DIR
) $(1)/usr
/share
67 $(CP
) $(PKG_INSTALL_DIR
)/usr
/share
/* $(1)/usr
/share
/
70 $(eval
$(call BuildPackage
,nagios
))