]> git.pld-linux.org Git - packages/rrdtool.git/blobdiff - rrdtool.spec
- up to 1.4.8
[packages/rrdtool.git] / rrdtool.spec
index 8ae0f0798fd059ea5e557f9ba10b7d8e6d56ff56..dc89c49c9c6943c3e128766ab6cc1664032dd131 100644 (file)
@@ -1,3 +1,12 @@
+#
+## TODO:
+# - separate package with rrdcached (init script, systemd file, etc)
+#
+# 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
 Summary:       RRDtool - round robin database
@@ -6,30 +15,44 @@ 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.2.26
+Version:       1.4.8
 Release:       1
-License:       GPL
+License:       GPL v2+ + FLOSS exception
 Group:         Applications/Databases
 Source0:       http://oss.oetiker.ch/rrdtool/pub/%{name}-%{version}.tar.gz
-# Source0-md5: b2c179e2d2ec2a92969648c4ebd382dc
+# Source0-md5: dbe59386db97fd2f2216729facd74ca8
 Patch0:                %{name}-tcl-path.patch
-URL:           http://oss.oetiker.ch/rrdtool/  
-BuildRequires: autoconf
+URL:           http://oss.oetiker.ch/rrdtool/
+BuildRequires: autoconf >= 2.60
 BuildRequires: automake
-BuildRequires: freetype-devel >= 2.1.7
-BuildRequires: libart_lgpl-devel >= 2.3.17
-BuildRequires: libpng-devel >= 2:1.2.8
+BuildRequires: cairo-devel >= 1.10.2
+BuildRequires: gettext-devel >= 0.18
+BuildRequires: glib2-devel >= 1:2.28.7
+BuildRequires: groff
+BuildRequires: intltool
+BuildRequires: libdbi-devel
+BuildRequires: libtool
+BuildRequires: libwrap-devel
+BuildRequires: libxml2-devel >= 1:2.7.8
+BuildRequires: lua51 >= 5.1
+BuildRequires: lua51-devel >= 5.1
+BuildRequires: pango-devel >= 1:1.28.4
 BuildRequires: perl-devel >= 1:5.8.0
 BuildRequires: pkgconfig
-BuildRequires: python >= 1:2.5
-BuildRequires: python-devel >= 1:2.5
+%if %{with python}
+BuildRequires: python >= 2.3
+BuildRequires: python-devel >= 2.3
+%endif
 BuildRequires: rpm-perlprov
 BuildRequires: rpm-pythonprov
-BuildRequires: tcl-devel
-BuildRequires: zlib-devel >= 1.2.1
-Requires:      libart_lgpl >= 2.3.17
-Requires:      libpng >= 1.2.8
-Requires:      zlib >= 1.2.1
+BuildRequires: rpmbuild(macros) >= 1.272
+%{?with_ruby:BuildRequires:    ruby-devel}
+%{?with_tcl:BuildRequires:     tcl-devel}
+Requires:      cairo >= 1.10.2
+Requires:      glib2 >= 1:2.28.7
+Requires:      libxml2 >= 1:2.7.8
+Requires:      pango >= 1:1.28.4
+Suggests:      fonts-TTF-DejaVu
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -89,11 +112,12 @@ Summary(ru.UTF-8): RRDtool - Заголовки, необходимые для 
 Summary(uk.UTF-8):     RRDtool - бібліотечні лінки та файли хедерів
 Group:         Development/Libraries
 Requires:      %{name} = %{version}-%{release}
-Requires:      cgilibc-devel >= 0.5
-Requires:      freetype-devel >= 2.1.7
-Requires:      libart_lgpl-devel >= 2.3.17
-Requires:      libpng-devel >= 2:1.2.8
-Requires:      zlib-devel >= 1.2.1
+Requires:      cairo-devel >= 1.10.2
+Requires:      glib2-devel >= 1:2.28.7
+Requires:      libdbi-devel
+Requires:      libwrap-devel
+Requires:      libxml2-devel >= 1:2.7.8
+Requires:      pango-devel >= 1:1.28.4
 
 %description devel
 RRDtool development files.
@@ -151,6 +175,19 @@ RRD - соращение для "Round Robin Database" (база данных с
 %description static -l uk.UTF-8
 Статичні бібліотеки для розробки програм, що використовують RRDtool.
 
+%package -n lua-rrdtool
+Summary:       RRD module for Lua
+Summary(pl.UTF-8):     Moduł RRD dla języka Lua
+Group:         Development/Languages
+Requires:      %{name} = %{version}-%{release}
+Requires:      lua51
+
+%description -n lua-rrdtool
+Lua interface to RRDtool.
+
+%description -n lua-rrdtool -l pl.UTF-8
+Interfejs języka Lua do RRDtoola.
+
 %package -n perl-rrdtool
 Summary:       Access RRDtool from Perl
 Summary(pl.UTF-8):     Dostęp do RRDtoola z poziomu Perla
@@ -180,6 +217,20 @@ Python interface to RRDtool, the graphing and logging utility.
 Interfejs Pythona do RRDtoola - narzędzia do tworzenia wykresów i
 logowania.
 
+%package -n ruby-rrdtool
+Summary:       Ruby interface to RRDtool
+Summary(pl.UTF-8):     Interfejs języka Ruby do RRDtoola
+Group:         Development/Languages/Python
+Requires:      %{name} = %{version}-%{release}
+%{?ruby_mod_ver_requires_eq}
+
+%description -n ruby-rrdtool
+Ruby interface to RRDtool, the graphing and logging utility.
+
+%description -n ruby-rrdtool -l pl.UTF-8
+Interfejs języka Ruby do RRDtoola - narzędzia do tworzenia wykresów i
+logowania.
+
 %package -n tcl-rrdtool
 Summary:       Tcl extension to access the RRD library
 Summary(pl.UTF-8):     Rozszerzenie Tcl-a pozwalające na dostęp do biblioteki Tcl
@@ -197,19 +248,27 @@ Rozszerzenie Tcl-a pozwalające na dostęp do biblioteki Tcl.
 %setup -q
 %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
-%{__aclocal}
+%{__libtoolize}
+%{__aclocal} -I m4
 %{__autoconf}
+%{__autoheader}
 %{__automake}
 %configure \
-       --enable-latin2 \
-       --with-perl=%{__perl} \
+       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
 # (tried to install without DESTDIR on plain make)
 %{__make} \
-       RUBY_MAKE_OPTIONS=
+       RUBY_MAKE_OPTIONS= \
+       LUA_CFLAGS=-I/usr/include/lua51
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -219,11 +278,15 @@ install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
        DESTDIR=$RPM_BUILD_ROOT \
        perl_sitearch=%{perl_vendorarch} \
        pythondir=%{py_sitedir} \
-       examplesdir=%{_examplesdir}/%{name}-%{version}
+       examplesdir=%{_examplesdir}/%{name}-%{version} \
+       RUBYARCHDIR=$RPM_BUILD_ROOT%{ruby_archdir}
+
+%{__rm} $RPM_BUILD_ROOT%{_libdir}/lua/5.1/*.{la,a}
+%{__rm} $RPM_BUILD_ROOT%{perl_vendorarch}/auto/RRDs/.packlist
+
+%{__rm} $RPM_BUILD_ROOT%{_libdir}/librrd.la
 
-rm -rf $RPM_BUILD_ROOT%{_prefix}/{doc,html}
-rm -f $RPM_BUILD_ROOT%{perl_vendorarch}/ntmake.pl
-rm -f $RPM_BUILD_ROOT%{perl_vendorarch}/auto/RRDs/.packlist
+%{__rm} -r $RPM_BUILD_ROOT%{_docdir}
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -236,24 +299,33 @@ rm -rf $RPM_BUILD_ROOT
 %doc CHANGES CONTRIBUTORS NEWS README THREADS TODO doc/*.html
 %attr(755,root,root) %{_bindir}/rrd*
 %attr(755,root,root) %{_libdir}/librrd.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/librrd.so.4
 %attr(755,root,root) %{_libdir}/librrd_th.so.*.*.*
-%{_datadir}/rrdtool
-%{_mandir}/man1/*
+%attr(755,root,root) %ghost %{_libdir}/librrd_th.so.4
+%{_mandir}/man1/bin_dec_hex.1*
+%{_mandir}/man1/cdeftutorial.1*
+%{_mandir}/man1/rpntutorial.1*
+%{_mandir}/man1/rrd*.1*
 
 %files devel
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/librrd.so
 %attr(755,root,root) %{_libdir}/librrd_th.so
-%{_libdir}/librrd.la
 %{_libdir}/librrd_th.la
-%{_includedir}/rrd.h
+%{_includedir}/rrd*.h
+%{_pkgconfigdir}/librrd.pc
 %{_examplesdir}/%{name}-%{version}
+%{_mandir}/man3/librrd.3*
 
 %files static
 %defattr(644,root,root,755)
 %{_libdir}/librrd.a
 %{_libdir}/librrd_th.a
 
+%files -n lua-rrdtool
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/lua/5.1/rrd.so*
+
 %files -n perl-rrdtool
 %defattr(644,root,root,755)
 %{perl_vendorlib}/RRDp.pm
@@ -264,12 +336,24 @@ rm -rf $RPM_BUILD_ROOT
 %{_mandir}/man3/RRDp.3*
 %{_mandir}/man3/RRDs.3*
 
+%if %{with python}
 %files -n python-rrdtool
 %defattr(644,root,root,755)
 %attr(755,root,root) %{py_sitedir}/rrdtoolmodule.so
+%if "%{py_ver}" > "2.4"
 %{py_sitedir}/py_rrdtool-*.egg-info
+%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.132717 seconds and 4 git commands to generate.