rrdtool-vl.spec 8.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307
  1. # Basic Information
  2. Name: rrdtool
  3. Summary: RRDtool - Round Robin Database tool
  4. Summary(ja): RRDtool - ラウンドロビンデータベースツール
  5. Version: 1.9.0
  6. Release: 1%{?_dist_release}
  7. Group: admin-tools,graphics
  8. Vendor: Project Vine
  9. Distribution: Vine Linux
  10. Packager: yasumichi
  11. License: GPLv2+ with exceptions
  12. URL: https://oss.oetiker.ch/rrdtool/
  13. Source0: https://github.com/oetiker/rrdtool-1.x/releases/download/v%{version}/rrdtool-%{version}.tar.gz
  14. Patch3: rrdtool-1.6.0-ruby-2-fix.patch
  15. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  16. # Dependency
  17. BuildRequires: glib2-devel
  18. BuildRequires: glibc-devel
  19. BuildRequires: libdbi-devel
  20. BuildRequires: libxml2-devel
  21. BuildRequires: lua-devel
  22. BuildRequires: pango-devel
  23. BuildRequires: perl(ExtUtils::MakeMaker)
  24. BuildRequires: ruby-devel
  25. BuildRequires: tcl-devel
  26. %description
  27. It is pretty easy to gather status information from all sorts of things,
  28. ranging from the temperature in your office to the number of octets which
  29. have passed through the FDDI interface of your router. But it is not so
  30. trivial to store this data in a efficient and systematic manner. This is
  31. where RRDtool kicks in. It lets you log and analyze the data you gather from
  32. all kinds of data-sources (DS). The data analysis part of RRDtool is based
  33. on the ability to quickly generate graphical representations of the data
  34. values collected over a definable time period.
  35. #%%description -l ja
  36. %package devel
  37. Summary: Libraries and include files of RRDtool
  38. Group: system
  39. Requires: %{name} = %{version}-%{release}
  40. %description devel
  41. Libraries and include files of RRDtool
  42. %package doc
  43. Summary: RRDtool documentation
  44. Summary(ja): RRDtool のドキュメント
  45. Group: documentation
  46. BuildArch: noarch
  47. %description doc
  48. RRD is the Acronym for Round Robin Database. RRD is a system to store and
  49. display time-series data (i.e. network bandwidth, machine-room temperature,
  50. server load average). This package contains documentation on using RRD.
  51. %package tcl
  52. Summary: RRDTool modules for tcl
  53. Group: programming
  54. Requires: %{name} = %{version}-%{release}
  55. %description tcl
  56. RRDTool bindings for Tcl.
  57. %package -n perl-rrdtool
  58. Summary: Perl RRDtool bindings
  59. Summary(ja): RRDTool の perl バインディング
  60. Group: programming
  61. Requires: %{name} = %{version}-%{release}
  62. Requires: perl(:MODULE_COMPAT_%perl_abi_version)
  63. %description -n perl-rrdtool
  64. The Perl RRDTool bindings.
  65. %package -n python3-rrdtool
  66. Summary: Python3 RRDTool bindings
  67. Summary(ja): RRDTool の Python3 バインディング
  68. Group: programming
  69. BuildRequires: python3-devel
  70. BuildRequires: python3-rpm-macros
  71. BuildRequires: python3-setuptools
  72. Requires: %{name} = %{version}-%{release}
  73. Requires: python(abi) = %{python3_version}
  74. %description -n python3-rrdtool
  75. RDTool bindings for python3.
  76. %package -n ruby-rrdtool
  77. Summary: Ruby RRDTool bindings
  78. Summary(ja): RRDTool の ruby バインディング
  79. Group: programming
  80. Requires: %{name} = %{version}-%{release}
  81. %description -n ruby-rrdtool
  82. RRDtool bindings for Ruby.
  83. %debug_package
  84. %prep
  85. %setup -q
  86. %patch3 -p1 -b .ruby-2-fix
  87. # Fix to find correct python dir on lib64
  88. perl -pi -e 's|get_python_lib\(0,0,prefix|get_python_lib\(1,0,prefix|g' \
  89. configure
  90. # Most edits shouldn't be necessary when using --libdir, but
  91. # w/o, some introduce hardcoded rpaths where they shouldn't
  92. perl -pi.orig -e 's|/lib\b|/%{_lib}|g' \
  93. configure Makefile.in php4/configure php4/ltconfig*
  94. # Perl 5.10 seems to not like long version strings, hack around it
  95. perl -pi.orig -e 's|1.299907080300|1.29990708|' \
  96. bindings/perl-shared/RRDs.pm bindings/perl-piped/RRDp.pm
  97. ./bootstrap
  98. %build
  99. export PYTHON=%{__python3}
  100. %configure \
  101. --disable-rpath \
  102. --disable-static \
  103. --with-perl-options="INSTALLDIRS=vendor" \
  104. --enable-python \
  105. --enable-ruby \
  106. --with-pic
  107. # Fix another rpath issue
  108. %{__perl} -pi.orig -e 's|-Wl,--rpath -Wl,\$rp||g' \
  109. bindings/perl-shared/Makefile.PL
  110. # Remove Rpath from Ruby
  111. %{__perl} -pi.orig -e 's|-Wl,--rpath -Wl,\$\(EPREFIX\)/lib||g' \
  112. bindings/ruby/extconf.rb
  113. sed -i 's|/ruby/extconf.rb|/ruby/extconf.rb --vendor |' bindings/Makefile
  114. # Force RRDp bits where we want 'em, not sure yet why the
  115. # --with-perl-options and --libdir don't take
  116. pushd bindings/perl-piped/
  117. perl Makefile.PL INSTALLDIRS=vendor
  118. perl -pi.orig -e 's|/lib/perl|/%{_lib}/perl|g' Makefile
  119. popd
  120. %make_build
  121. # Fix @perl@ and @PERL@
  122. find examples/ -type f \
  123. -exec perl -pi -e 's|^#! \@perl\@|#!%{__perl}|gi' {} \;
  124. find examples/ -name "*.pl" \
  125. -exec perl -pi -e 's|\015||gi' {} \;
  126. # Rebuild python
  127. pushd bindings/python
  128. %py3_build
  129. popd
  130. %install
  131. export PYTHON=%{__python3}
  132. %make_install PYTHON="$PYTHON"
  133. # Install ruby module by force
  134. mkdir -p $RPM_BUILD_ROOT/%{ruby_vendorarchdir}
  135. make -C bindings/ruby install DESTDIR=$RPM_BUILD_ROOT
  136. # Pesky RRDp.pm...
  137. mv $RPM_BUILD_ROOT%{perl_vendorlib}/RRDp.pm $RPM_BUILD_ROOT%{perl_vendorarch}/
  138. # Dunno why this is getting installed here...
  139. rm -f $RPM_BUILD_ROOT%{perl_vendorlib}/leaktest.pl
  140. # We only want .txt and .html files for the main documentation
  141. mkdir -p doc2/html doc2/txt
  142. cp -a doc/*.txt doc2/txt/
  143. cp -a doc/*.html doc2/html/
  144. # Put perl docs in perl package
  145. mkdir -p doc3/html
  146. mv doc2/html/RRD*.html doc3/html/
  147. # Clean up the examples
  148. rm -f examples/Makefile* examples/*.in examples/rrdcached/Makefile*
  149. # This is so rpm doesn't pick up perl module dependencies automatically
  150. find examples/ -type f -exec chmod 0644 {} \;
  151. # Reinstall python
  152. pushd bindings/python
  153. %py3_install
  154. popd
  155. # Clean up the buildroot
  156. rm -rf $RPM_BUILD_ROOT%{_docdir}/%{name}-* \
  157. $RPM_BUILD_ROOT%{_libdir}/librrd.la \
  158. $RPM_BUILD_ROOT%{_libdir}/lua/*/rrd.la \
  159. $RPM_BUILD_ROOT%{perl_vendorarch}/ntmake.pl \
  160. $RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod \
  161. $RPM_BUILD_ROOT%{_datadir}/%{name}/examples \
  162. $RPM_BUILD_ROOT%{perl_vendorarch}/auto/*/{.packlist,*.bs}
  163. %find_lang %{name}
  164. %files -f %{name}.lang
  165. %license LICENSE
  166. %doc CONTRIBUTORS COPYRIGHT TODO NEWS CHANGES THREADS
  167. %{_bindir}/rrd*
  168. %{_libdir}/lua/*/rrd.so.*
  169. %{_libdir}/librrd*.so.*
  170. %{_mandir}/man1/*.1*
  171. %files devel
  172. %{_includedir}/rrd*.h
  173. %{_libdir}/lua/*/rrd.so
  174. %{_libdir}/librrd.so
  175. %{_libdir}/pkgconfig/librrd.pc
  176. %{_mandir}/man3/librrd.3*
  177. %files doc
  178. %doc examples doc2/html doc2/txt
  179. %files tcl
  180. %doc bindings/tcl/README
  181. #%{_datadir}/rrdtool/ifOctets.tcl
  182. #%{_datadir}/rrdtool/pkgIndex.tcl
  183. %{_libdir}/tclrrd*.so
  184. %{_libdir}/rrdtool/*.tcl
  185. %files -n perl-rrdtool
  186. %doc doc3/html
  187. %{perl_vendorarch}/RRDp.pm
  188. %{perl_vendorarch}/RRDs.pm
  189. %{perl_vendorarch}/auto/RRDs/RRDs.so
  190. %{_mandir}/man3/RRD?.3pm*
  191. %files -n python3-rrdtool
  192. %license bindings/python/COPYING
  193. %doc bindings/python/README*
  194. %{python3_sitearch}/rrdtool-*-py*.egg-info
  195. %{python3_sitearch}/rrdtool.*.so
  196. %files -n ruby-rrdtool
  197. %doc bindings/ruby/README
  198. %{ruby_vendorarchdir}/RRD.so
  199. %changelog
  200. * Mon Jun 16 2025 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.9.0-1
  201. - new upstream release.
  202. - built with perl-5.40.
  203. * Fri Nov 19 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.7.2-5
  204. - rebuilt with perl-5.34.0.
  205. - dropped ldconfig scriptlets.
  206. * Mon Nov 15 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.7.2-4
  207. - rebuilt with ruby-3.0.2.
  208. - dropped python2 support.
  209. * Wed Aug 19 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.7.2-3
  210. - fixed dependency.
  211. * Mon Aug 17 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.7.2-2
  212. - rebuilt with python-3.8.
  213. * Mon Mar 16 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.7.2-1
  214. - new upstream release.
  215. - built with ruby-2.6.5.
  216. - added python3 support.
  217. * Sat May 18 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.7.1-1
  218. - new upstream release.
  219. - rebuilt with perl-5.26.
  220. - rebuilt with ruby-2.4.6.
  221. - updated Patch3.
  222. * Sun Sep 13 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.4.9-3
  223. - rebuild with ruby-2.2.3
  224. * Sun Jan 25 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.4.9-2
  225. - rebuild with libdbi-0.9.0
  226. * Mon Jan 5 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 1.4.9-1
  227. - new upstream release.
  228. - added Group tag to subpackages
  229. - added ruby subpackages
  230. - split documents into subpackages
  231. - added %%post and %%postun section
  232. * Tue Jul 1 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.4.8-1
  233. - new upstream release.
  234. * Fri Feb 17 2012 Yasumichi Akahoshi <yasumichi@vinelinux.org> 1.4.7-1
  235. - initial build for Vine Linux