]> git.pld-linux.org Git - packages/rrdtool.git/blobdiff - rrdtool.spec
- ruby and tcl bconds
[packages/rrdtool.git] / rrdtool.spec
index b9839efa18d929d503c7bb08f105c26ba39fb87b..6f11fea43b954b027caf6eba2f98a9e67648c07e 100644 (file)
@@ -1,6 +1,8 @@
 #
 # Conditional build:
 %bcond_without python  # Python binding
+%bcond_without tcl     # Tcl binding
+%bcond_without ruby    # Ruby binding
 #
 %include       /usr/lib/rpm/macros.perl
 %define        pdir    RRDp
@@ -10,12 +12,12 @@ Summary(pt_BR.UTF-8):       Round Robin Database, uma ferramenta para construção de
 Summary(ru.UTF-8):     RRDtool - база данных с "циклическим обновлением"
 Summary(uk.UTF-8):     RRDtool - це система зберігання та показу серійних даних
 Name:          rrdtool
-Version:       1.4.4
-Release:       2
+Version:       1.4.5
+Release:       1
 License:       GPL v2+ + FLOSS exception
 Group:         Applications/Databases
 Source0:       http://oss.oetiker.ch/rrdtool/pub/%{name}-%{version}.tar.gz
-# Source0-md5: 93ad2fc2e9ddcd7d99c611fe30284a54
+# Source0-md5: 4d116dba9a0888d8aaac179e35d3980a
 Patch0:                %{name}-tcl-path.patch
 URL:           http://oss.oetiker.ch/rrdtool/
 BuildRequires: autoconf >= 2.60
@@ -38,8 +40,8 @@ BuildRequires:        python-devel >= 2.3
 BuildRequires: rpm-perlprov
 BuildRequires: rpm-pythonprov
 BuildRequires: rpmbuild(macros) >= 1.272
-BuildRequires: ruby-devel
-BuildRequires: tcl-devel
+%{?with_ruby:BuildRequires:    ruby-devel}
+%{?with_tcl:BuildRequires:     tcl-devel}
 Requires:      cairo >= 1.4.6
 Requires:      glib2 >= 1:2.12.12
 Requires:      libxml2 >= 2.6.31
@@ -240,6 +242,7 @@ Rozszerzenie Tcl-a pozwalające na dostęp do biblioteki Tcl.
 %patch0 -p1
 
 sed -i -e 's#\$TCL_PACKAGE_PATH#%{_prefix}/lib#g' configure.ac
+sed -i -e 's#/lib/lua/#/%{_lib}/lua/#g' configure.ac
 
 %build
 %{__libtoolize}
@@ -250,6 +253,8 @@ sed -i -e 's#\$TCL_PACKAGE_PATH#%{_prefix}/lib#g' configure.ac
 %configure \
        LUA=/usr/bin/lua51 \
        --disable-silent-rules \
+       %{!?with_tcl:--disable-tcl} \
+       %{!?with_ruby:--disable-ruby} \
        --with-perl-options="INSTALLDIRS=vendor"
 
 # empty RUBY_MAKE_OPTIONS as workaround for some make weirdness
@@ -262,7 +267,7 @@ sed -i -e 's#\$TCL_PACKAGE_PATH#%{_prefix}/lib#g' configure.ac
 rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
 
-%{__make} -j1 install \
+%{__make} install \
        DESTDIR=$RPM_BUILD_ROOT \
        perl_sitearch=%{perl_vendorarch} \
        pythondir=%{py_sitedir} \
@@ -330,11 +335,15 @@ rm -rf $RPM_BUILD_ROOT
 %endif
 %endif
 
+%if %{with ruby}
 %files -n ruby-rrdtool
 %defattr(644,root,root,755)
 %attr(755,root,root) %{ruby_archdir}/RRD.so
+%endif
 
+%if %{with tcl}
 %files -n tcl-rrdtool
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/tclrrd%{version}.so
 %{_prefix}/lib/tclrrd%{version}
+%endif
This page took 0.025955 seconds and 4 git commands to generate.