wshaper: add init scripwshaper: add init scriptt
[openwrt/svn-archive/archive.git] / utils / rrdcollect / Makefile
index ca581ea95b6ae7a4fc8da645a5930cb6203fcfca..bf01704f442568a98c5c6479f78b9a9e2995edcf 100644 (file)
@@ -10,46 +10,53 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=rrdcollect
 PKG_VERSION:=0.2.3
-PKG_RELEASE:=1
+PKG_RELEASE:=3
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=@SF/rrdcollect
 PKG_MD5SUM:=5e4305c612bc3cccbaf802c275c81a11
-PKG_CAT:=zcat
 
 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
 
 include $(INCLUDE_DIR)/package.mk
 
-define Package/rrdcollect
+define Package/rrdcollect/Default
   SECTION:=utils
   CATEGORY:=Utilities
-  DESCRIPTION:=\
-       RRDcollect is a daemon which polls ceratin files in /proc/ \\\
-       directory, gathering data and storing it inside RRDtool's \\\
-       database files.  Being written in C should be both fast \\\
-       and resources-friendly.  Supports both scanf(3)-style \\\
-       pattern matches and perl compatible regular expressions.
   URL:=http://rrdcollect.sourceforge.net/
 endef
 
 define Package/rrdcollect
   $(call Package/rrdcollect/Default)
-  DEPENDS:=+librrd1
+  DEPENDS:=+librrd
   TITLE:=Round-Robin Database (RRD) collecting daemon
-  DESCRIPTION+=\\\
-       \\\
-       This package contains the RRD collecting daemon.
   MENU:=1
 endef
 
+define Package/rrdcollect/description
+=
+       RRDcollect is a daemon which polls ceratin files in /proc/ 
+       directory, gathering data and storing it inside RRDtool's 
+       database files. Being written in C should be both fast 
+       and resources-friendly. Supports both scanf(3)-style 
+       pattern matches and perl compatible regular expressions.        
+       This package contains the RRD collecting daemon.
+endef
+
 define Package/rrdcollect-example
   $(call Package/rrdcollect/Default)
   DEPENDS:=rrdcollect
   TITLE:=Example setup for RRD collecting daemon above
-  DESCRIPTION+=\\\
-       \\\
+endef
+
+define Package/rrdcollect-example/description
+=
+       RRDcollect is a daemon which polls ceratin files in /proc/ 
+       directory, gathering data and storing it inside RRDtool's 
+       database files. Being written in C should be both fast 
+       and resources-friendly. Supports both scanf(3)-style 
+       pattern matches and perl compatible regular expressions.        
        This package contains examples for the RRD collecting daemon.
 endef
 
@@ -63,7 +70,6 @@ define Build/Configure
                --enable-shared \
                --disable-static \
                --disable-rpath \
-               --with-gnu-ld \
                --enable-exec \
                --without-rrdtool \
                --with-librrd \
@@ -71,7 +77,7 @@ define Build/Configure
                --without-libpcap \
                , \
                CFLAGS="$(TARGET_CFLAGS) -DSOCKET_COMM" \
-               LIBS="-lz" \
+               LIBS="-lz -lfreetype -lpng -lart_lgpl_2" \
        )
 endef
 
@@ -82,19 +88,19 @@ define Build/Compile
 endef
 
 define Package/rrdcollect/install      
-       install -d -m0755 $(1)/usr/sbin
-       $(CP) $(PKG_INSTALL_DIR)/usr/sbin/rrdcollect $(1)/usr/sbin/
+       $(INSTALL_DIR) $(1)/usr/sbin
+       $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/rrdcollect $(1)/usr/sbin/
 endef
 
 define Package/rrdcollect-example/install      
-       install -d -m0755 $(1)/etc
-       install -m0644 ./files/rrd.conf $(1)/etc/
-       install -m0644 ./files/rrdcollect.conf $(1)/etc/
-       install -d -m0755 $(1)/etc/init.d
-       install -m0755 ./files/rrdcollect.init $(1)/etc/init.d/rrdcollect
-       install -d -m0755 $(1)/usr/bin
-       install -m0755 ./files/rrd.sh $(1)/usr/bin/
-       install -d -m0755 $(1)/www/cgi-bin
+       $(INSTALL_DIR) $(1)/etc
+       $(INSTALL_DATA) ./files/rrd.conf $(1)/etc/
+       $(INSTALL_DATA) ./files/rrdcollect.conf $(1)/etc/
+       $(INSTALL_DIR) $(1)/etc/init.d
+       $(INSTALL_BIN) ./files/rrdcollect.init $(1)/etc/init.d/rrdcollect
+       $(INSTALL_DIR) $(1)/usr/bin
+       $(INSTALL_BIN) ./files/rrd.sh $(1)/usr/bin/
+       $(INSTALL_DIR) $(1)/www/cgi-bin
        ln -sf /var/lib/rrdcollect/rrd.cgi $(1)/www/cgi-bin/rrd.cgi
        ln -sf /var/lib/rrdcollect/img $(1)/www/img
 endef