From f0d3f1c9797e79dd787e3be78ed088419cfe744e Mon Sep 17 00:00:00 2001 From: Tim Yardley Date: Tue, 31 Jul 2007 22:50:55 +0000 Subject: [PATCH] rrdtool: add python bindings SVN-Revision: 8292 --- utils/rrdtool/Makefile | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/utils/rrdtool/Makefile b/utils/rrdtool/Makefile index 2dd392d918..0601958808 100644 --- a/utils/rrdtool/Makefile +++ b/utils/rrdtool/Makefile @@ -55,6 +55,14 @@ define Package/rrdtool TITLE:=Round Robin Database (RRD) management tools (v1.2.x) endef +define Package/rrdpy + $(call Package/rrd) + DEPENDS:=librrd +python + SECTION:=utils + CATEGORY:=Utilities + TITLE:=Round Robin Database (RRD) python bindings (v1.2.x) +endef + define Build/Configure $(call Build/Configure/Default,--enable-shared=yes \ --enable-static=yes \ @@ -79,6 +87,13 @@ define Build/Compile $(MAKE) -C $(PKG_BUILD_DIR) \ DESTDIR="$(PKG_INSTALL_DIR)" \ all install + ifneq ($(CONFIG_PACKAGE_rrdpy),n) + $(MAKE) -C $(PKG_BUILD_DIR)/bindings/python \ + pythondir=$(shell $(STAGING_DIR)/usr/bin/hostpython $(SCRIPT_DIR)/pylibdir.py) \ + CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include/python2.5" \ + DESTDIR="$(PKG_INSTALL_DIR)" \ + all install + endif endef define Package/rrdtool/install @@ -87,6 +102,12 @@ define Package/rrdtool/install $(CP) $(PKG_INSTALL_DIR)/usr/bin/rrdupdate $(1)/usr/bin/ endef +define Package/rrdpy/install + $(INSTALL_DIR) $(1)/usr/lib/python2.5/site-packages + $(CP) $(PKG_INSTALL_DIR)/usr/lib/python2.5/site-packages/* \ + $(1)/usr/lib/python2.5/site-packages +endef + define Package/rrdcgi/install $(INSTALL_DIR) $(1)/usr/bin $(CP) $(PKG_INSTALL_DIR)/usr/bin/rrdcgi $(1)/usr/bin/ @@ -118,3 +139,4 @@ endef $(eval $(call BuildPackage,librrd)) $(eval $(call BuildPackage,rrdcgi)) $(eval $(call BuildPackage,rrdtool)) +$(eval $(call BuildPackage,rrdpy)) -- 2.30.2