Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 517238 - dev-ruby/rrdtool-bindings - add USE=graph
Summary: dev-ruby/rrdtool-bindings - add USE=graph
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Netmon project
URL:
Whiteboard:
Keywords: PATCH
Depends on: 509682
Blocks:
  Show dependency tree
 
Reported: 2014-07-16 12:35 UTC by Jeroen Roovers (RETIRED)
Modified: 2014-10-04 09:36 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
rrdtool-bindings-1.4.8-graph.patch (rrdtool-bindings-1.4.8-graph.patch,1.81 KB, patch)
2014-07-16 12:35 UTC, Jeroen Roovers (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jeroen Roovers (RETIRED) gentoo-dev 2014-07-16 12:35:13 UTC
Created attachment 380814 [details, diff]
rrdtool-bindings-1.4.8-graph.patch

It should be nice to get the Ruby bindings built without rrd_graph/rrd_xport.

The only problem is that the ebuild (probably the eclasses involved) completely ignore appending _DHAVE_RRD_GRAPH to CFLAGS/CPPFLAGS.

How do I teach the ebuild to use that. Running the proper autotools-based configure script would surely help, I guess, because that would set up HAVE_CONFIG_H (and so on).
Comment 1 Hans de Graaff gentoo-dev Security 2014-07-20 08:09:02 UTC
It looks like this will work best (with suitable stuff to enable/disable the flag):

each_ruby_configure() {
	${RUBY} extconf.rb --with-cflags="${CFLAGS} -DHAVE_RDD_GRAPH" || die
}

Does that help?

Looking at the ruby bindings code I don't see how it would pick up the results from the autotools configure from a quick look at the source code or the generated Makefile. Also, it would need to be run for each ruby implementation in each_ruby_configure(), but then all dependencies are automagic and porting all USE flags from net-analyzer/rrdtool doesn't sound like fun.
Comment 2 Jeroen Roovers (RETIRED) gentoo-dev 2014-07-20 11:53:40 UTC
(In reply to Hans de Graaff from comment #1)
> It looks like this will work best (with suitable stuff to enable/disable the
> flag):
> 
> each_ruby_configure() {
> 	${RUBY} extconf.rb --with-cflags="${CFLAGS} -DHAVE_RDD_GRAPH" || die
> }
> 
> Does that help?

I guess.
Comment 3 Jeroen Roovers (RETIRED) gentoo-dev 2014-07-20 12:07:11 UTC
(In reply to Hans de Graaff from comment #1)
> each_ruby_configure() {
> 	${RUBY} extconf.rb --with-cflags="${CFLAGS} -DHAVE_RDD_GRAPH" || die

You'd want IUSE=graph and then $(usex -DHAVE_RDD_GRAPH '').
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2014-10-04 09:36:01 UTC
Fixed in -r2 and in 1.4.9.