diff --git a/rrdtool.spec b/rrdtool.spec index a8273b0..304eb77 100644 --- a/rrdtool.spec +++ b/rrdtool.spec @@ -1,13 +1,14 @@ %define with_python %{?_without_python: 0} %{?!_without_python: 1} %define with_php %{?_without_php: 0} %{?!_without_php: 1} %define with_tcl %{?_without_tcl: 0} %{?!_without_tcl: 1} +%define with_ruby %{?_without_ruby: 0} %{?!_without_ruby: 1} %define php_rrd_svn 839 %define php_extdir %(php-config --extension-dir 2>/dev/null || echo %{_libdir}/php4) Summary: Round Robin Database Tool to store and display time-series data Name: rrdtool Version: 1.2.23 -Release: 3%{?dist} +Release: 4%{?dist} License: GPL Group: Applications/Databases URL: http://people.ee.ethz.ch/~oetiker/webtools/%{name}/ @@ -112,6 +113,20 @@ Provides: tcl-%{name} = %{version}-%{release} The %{name}-tcl package includes RRDtool bindings for Tcl. %endif +%if %{with_ruby} +%{!?ruby_sitearch: %define ruby_sitearch %(ruby -rrbconfig -e 'puts Config::CONFIG["sitearchdir"]')} + +%package ruby +Summary: Ruby RRDtool bindings +Group: Development/Languages +BuildRequires: ruby-devel +Requires: ruby(abi) = 1.8 +Requires: %{name} = %{version}-%{release} + +%description ruby +The %{name}-ruby package includes RRDtool bindings for Ruby. +%endif + %prep %setup -q %setup -q -T -D -a 1 @@ -143,6 +158,9 @@ The %{name}-tcl package includes RRDtool bindings for Tcl. --enable-python \ %else --disable-python \ +%endif +%if %{with_ruby} + --enable-ruby \ %endif --disable-static \ --with-pic @@ -277,7 +295,17 @@ find examples/ -type f -exec chmod 0644 {} \; %{_libdir}/rrdtool/*.tcl %endif +%if %{with_ruby} +%files ruby +%defattr(-,root,root,-) +%doc bindings/ruby/README +%{ruby_sitearch}/RRD.so +%endif + %changelog +* Mon May 21 2007 Jarod Wilson 1.2.23-4 +- Build ruby bindings + * Thu May 03 2007 Jarod Wilson 1.2.23-3 - Disable php bits on ppc64 for now, they fail to build