summaryrefslogtreecommitdiff
path: root/dev-ruby/rrdtool-bindings
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-ruby/rrdtool-bindings
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-ruby/rrdtool-bindings')
-rw-r--r--dev-ruby/rrdtool-bindings/Manifest6
-rw-r--r--dev-ruby/rrdtool-bindings/files/rrdtool-bindings-1.4.8-graph-ruby.patch70
-rw-r--r--dev-ruby/rrdtool-bindings/metadata.xml15
-rw-r--r--dev-ruby/rrdtool-bindings/rrdtool-bindings-1.6.0.ebuild63
-rw-r--r--dev-ruby/rrdtool-bindings/rrdtool-bindings-1.7.0.ebuild60
5 files changed, 214 insertions, 0 deletions
diff --git a/dev-ruby/rrdtool-bindings/Manifest b/dev-ruby/rrdtool-bindings/Manifest
new file mode 100644
index 000000000000..29e250ea5ce9
--- /dev/null
+++ b/dev-ruby/rrdtool-bindings/Manifest
@@ -0,0 +1,6 @@
+AUX rrdtool-bindings-1.4.8-graph-ruby.patch 1857 BLAKE2B 4a36c4dee4e755bd39851c5c333fddacdddb53324017290f15345687b577caf9efb41d97ce55cc0bcd57554746e1a90d9a2d9fd92c0acd48b405eb02957e491c SHA512 1803247c9949a6d28d7027242604b5d61bc9da38ff22ff9d6302ca69743e49328372b4e51554c868b19a459c4341fa6d1291d09d62ea6a414a81d4558a7ef66d
+DIST rrdtool-1.6.0.tar.gz 2186538 BLAKE2B b56ef79b9d45a65cacd7c1d8da2158dcaaff3ebc2ffc0640081cdc2fa3ac643be1ce48a2cac60427a836dc3e457ddb042c95533d0ffbcdefa2978f5659150391 SHA512 45a8f16a2bda9d497c5f39de80236adb7a5bd054a14755c4d130f21cd6430bd0a76caef9632994be56fd1ea2364eb218687ea8ebf945a71ca411221c248f3ebd
+DIST rrdtool-1.7.0.tar.gz 2849994 BLAKE2B f7a91fa661728850af55356a69b61ea1d4343c79579823e025e0a0757d1dab0d2cda6387197ece20e07f33a657743350cadfaf6504500f13be472d18e8826a3f SHA512 36d979561601135d74622eaf183701de15cba5e25118f7a308926a695ba84ecb33c3d16511bf4bc80cff055853e2eb85065bc4ed8aef19fc0277c6430ecd319f
+EBUILD rrdtool-bindings-1.6.0.ebuild 1324 BLAKE2B 3ef5cc35a9b495db4ffb33fd5e4b91c3fc1b6b515eaf92993c5674d281ca58b74afdb9e4ded0d3483396c10ad9761dc39ff6bcc0353ffc6d23e658a0dbbf76c8 SHA512 39ba745ed55bfa103497d66c09d7582d4e33a20ba49e1c8e1ee2bd20895e8ac5722703efd3bf94c54aaa0534cefbd61f322ea01ad39c1704c32592eb917bb80b
+EBUILD rrdtool-bindings-1.7.0.ebuild 1321 BLAKE2B 3d4aa42330134b37f1adbe038c16a1cb0e8274754b15e2ca071acab3ce0f08f573eeb80f57520395acf6f4b7aea93c3d1bbfea6076f7a1099678eaf2159c47c6 SHA512 78d9b941966aab0f4d4d965090e30c4f737c07e3492d60307742e779f43626190111a2df2f2733d1dc351e706d13415eb9170f275b274b55ba5deeeb7e3bad66
+MISC metadata.xml 463 BLAKE2B edb3b1f3703163a7f6c28ea7d16a79158d108721a2a775e30967885fb6b7b31d6074585951cc5b1c7b640c88b0694b95f0aaf62b71df43a8d6d6a0d6f78e07c9 SHA512 60732861cde4604b50875b6bbba205f232a52c4d91e6e21bce49a46bcef824bc542140e73b07ce4c18518a366ff8c9bd34569895741b0ac292124f43b0f02aa1
diff --git a/dev-ruby/rrdtool-bindings/files/rrdtool-bindings-1.4.8-graph-ruby.patch b/dev-ruby/rrdtool-bindings/files/rrdtool-bindings-1.4.8-graph-ruby.patch
new file mode 100644
index 000000000000..8c26ce48cfb3
--- /dev/null
+++ b/dev-ruby/rrdtool-bindings/files/rrdtool-bindings-1.4.8-graph-ruby.patch
@@ -0,0 +1,70 @@
+--- a/bindings/ruby/main.c
++++ b/bindings/ruby/main.c
+@@ -216,13 +216,14 @@
+ return rb_rrd_infocall(rrd_update_v, args);
+ }
+
++#ifdef HAVE_RRD_GRAPH
+ VALUE rb_rrd_graphv(
+ VALUE self,
+ VALUE args)
+ {
+ return rb_rrd_infocall(rrd_graph_v, args);
+ }
+-
++#endif /* HAVE_RRD_GRAPH */
+
+ /* Other Calls */
+
+@@ -273,6 +274,7 @@
+ return result;
+ }
+
++#ifdef HAVE_RRD_GRAPH
+ VALUE rb_rrd_graph(
+ VALUE self,
+ VALUE args)
+@@ -302,7 +304,7 @@
+ rb_ary_store(result, 2, INT2FIX(ysize));
+ return result;
+ }
+-
++#endif /* HAVE_RRD_GRAPH */
+
+ VALUE rb_rrd_last(
+ VALUE self,
+@@ -320,6 +322,7 @@
+ return rb_funcall(rb_cTime, rb_intern("at"), 1, UINT2NUM(last));
+ }
+
++#ifdef HAVE_RRD_GRAPH
+ VALUE rb_rrd_xport(
+ VALUE self,
+ VALUE args)
+@@ -367,6 +370,7 @@
+ rb_ary_store(result, 5, rdata);
+ return result;
+ }
++#endif /* HAVE_RRD_GRAPH */
+
+ void Init_RRD(
+ )
+@@ -377,7 +381,9 @@
+ rb_define_module_function(mRRD, "create", rb_rrd_create, -2);
+ rb_define_module_function(mRRD, "dump", rb_rrd_dump, -2);
+ rb_define_module_function(mRRD, "fetch", rb_rrd_fetch, -2);
++#ifdef HAVE_RRD_GRAPH
+ rb_define_module_function(mRRD, "graph", rb_rrd_graph, -2);
++#endif /* HAVE_RRD_GRAPH */
+ rb_define_module_function(mRRD, "last", rb_rrd_last, -2);
+ rb_define_module_function(mRRD, "resize", rb_rrd_resize, -2);
+ rb_define_module_function(mRRD, "restore", rb_rrd_restore, -2);
+@@ -386,6 +392,8 @@
+ rb_define_module_function(mRRD, "flushcached", rb_rrd_flushcached, -2);
+ rb_define_module_function(mRRD, "info", rb_rrd_info, -2);
+ rb_define_module_function(mRRD, "updatev", rb_rrd_updatev, -2);
++#ifdef HAVE_RRD_GRAPH
+ rb_define_module_function(mRRD, "graphv", rb_rrd_graphv, -2);
+ rb_define_module_function(mRRD, "xport", rb_rrd_xport, -2);
++#endif /* HAVE_RRD_GRAPH */
+ }
diff --git a/dev-ruby/rrdtool-bindings/metadata.xml b/dev-ruby/rrdtool-bindings/metadata.xml
new file mode 100644
index 000000000000..8a2c1bd406e6
--- /dev/null
+++ b/dev-ruby/rrdtool-bindings/metadata.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+<email>ruby@gentoo.org</email>
+<name>Gentoo Ruby Project</name>
+ </maintainer>
+<maintainer type="project">
+<email>netmon@gentoo.org</email>
+<name>Gentoo network monitoring and analysis project</name>
+ </maintainer>
+<use>
+<flag name="graph">Enable support for graphing functions</flag>
+</use>
+</pkgmetadata>
diff --git a/dev-ruby/rrdtool-bindings/rrdtool-bindings-1.6.0.ebuild b/dev-ruby/rrdtool-bindings/rrdtool-bindings-1.6.0.ebuild
new file mode 100644
index 000000000000..8d8c2aa3a3c0
--- /dev/null
+++ b/dev-ruby/rrdtool-bindings/rrdtool-bindings-1.6.0.ebuild
@@ -0,0 +1,63 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+
+USE_RUBY="ruby23 ruby24 ruby25"
+
+RUBY_FAKEGEM_TASK_DOC=""
+
+inherit ruby-ng
+
+MY_P=${P/-bindings}
+MY_P=${MY_P/_/-}
+
+DESCRIPTION="Ruby bindings for rrdtool"
+HOMEPAGE="https://oss.oetiker.ch/rrdtool/"
+SRC_URI="${HOMEPAGE}pub/${MY_P}.tar.gz"
+RUBY_S="$MY_P"/bindings/ruby
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x86-macos ~x86-solaris"
+IUSE="graph test"
+REQUIRED_USE="test? ( graph )"
+
+# Block on older versions of rrdtool that install the bindings themselves.
+# requires rrd_xport which requires rrd_graph
+RDEPEND="
+ ~net-analyzer/rrdtool-${PV}[graph=]
+"
+DEPEND="
+ test? ( ~net-analyzer/rrdtool-${PV}[graph] )
+"
+
+RUBY_PATCHES=(
+ "${FILESDIR}"/${PN}-1.4.8-graph-ruby.patch
+)
+
+each_ruby_configure() {
+ rm ../../src/rrd_config.h || die
+ touch ../../src/rrd_config.h || die
+
+ ${RUBY} extconf.rb \
+ --with-cflags="${CFLAGS} $(usex graph -DHAVE_RRD_GRAPH -UHAVE_RRD_GRAPH)" || die
+}
+
+each_ruby_compile() {
+ emake V=1 ABS_TOP_SRCDIR="${PWD}/../.."
+}
+
+each_ruby_test() {
+ if use graph; then
+ ${RUBY} -I. test.rb || die
+ fi
+}
+
+all_ruby_install() {
+ dodoc CHANGES README
+}
+
+each_ruby_install() {
+ DESTDIR=${D} emake install
+}
diff --git a/dev-ruby/rrdtool-bindings/rrdtool-bindings-1.7.0.ebuild b/dev-ruby/rrdtool-bindings/rrdtool-bindings-1.7.0.ebuild
new file mode 100644
index 000000000000..6644d0fc0228
--- /dev/null
+++ b/dev-ruby/rrdtool-bindings/rrdtool-bindings-1.7.0.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+USE_RUBY="ruby23 ruby24 ruby25"
+RUBY_FAKEGEM_TASK_DOC=""
+inherit ruby-ng
+
+MY_P=${P/-bindings}
+MY_P=${MY_P/_/-}
+
+DESCRIPTION="Ruby bindings for rrdtool"
+HOMEPAGE="https://oss.oetiker.ch/rrdtool/"
+SRC_URI="${HOMEPAGE}pub/${MY_P}.tar.gz"
+RUBY_S="$MY_P"/bindings/ruby
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x86-macos ~x86-solaris"
+IUSE="graph test"
+REQUIRED_USE="test? ( graph )"
+
+# Block on older versions of rrdtool that install the bindings themselves.
+# requires rrd_xport which requires rrd_graph
+RDEPEND="
+ ~net-analyzer/rrdtool-${PV}[graph=]
+"
+DEPEND="
+ test? ( ~net-analyzer/rrdtool-${PV}[graph] )
+"
+
+RUBY_PATCHES=(
+ "${FILESDIR}"/${PN}-1.4.8-graph-ruby.patch
+)
+
+each_ruby_configure() {
+ rm ../../src/rrd_config.h || die
+ touch ../../src/rrd_config.h || die
+
+ ${RUBY} extconf.rb \
+ --with-cflags="${CFLAGS} $(usex graph -DHAVE_RRD_GRAPH -UHAVE_RRD_GRAPH)" || die
+}
+
+each_ruby_compile() {
+ emake V=1 ABS_TOP_SRCDIR="${PWD}/../.."
+}
+
+each_ruby_test() {
+ if use graph; then
+ ${RUBY} -I. test.rb || die
+ fi
+}
+
+all_ruby_install() {
+ dodoc CHANGES README
+}
+
+each_ruby_install() {
+ DESTDIR=${D} emake install
+}