- Fixed mixed tabs and spaces rpmlint warning

- Fixed tcl-site configure option (upstream ticket #281)
- Removed Rpath from Ruby
- Enabled Lua bindings (#656080), thanks to Tim Niemueller
This commit is contained in:
Jaroslav Škarvada 2010-11-23 23:21:16 +01:00
parent 106ac5f076
commit 96b5903fe3
2 changed files with 67 additions and 4 deletions

View File

@ -0,0 +1,23 @@
--- rrdtool-1.4.4/configure.old 2010-11-23 14:39:42.000000000 +0100
+++ rrdtool-1.4.4/configure 2010-11-23 14:40:32.656140783 +0100
@@ -1036,6 +1036,7 @@
enable_lua_site_install
enable_tcl
with_tcllib
+enable_tcl_site
enable_python
'
ac_precious_vars='build_alias
@@ -28584,9 +28585,9 @@
TCL_INCLUDE_SPEC="$TCL_INCLUDE_SPEC -I$TCL_INC_DIR"
fi
fi
- # Check whether --enable-tcl was given.
-if test "${enable_tcl+set}" = set; then
- enableval=$enable_tcl;
+ # Check whether --enable-tcl-site was given.
+if test "${enable_tcl_site+set}" = set; then
+ enableval=$enable_tcl_site;
else
enable_tcl_site=yes
fi

View File

@ -2,6 +2,7 @@
%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 with_lua %{?_without_lua: 0} %{?!_without_lua: 1}
%define php_extdir %(php-config --extension-dir 2>/dev/null || echo %{_libdir}/php4)
%define svnrev r1190
#define pretag 1.2.99908020600
@ -9,12 +10,14 @@
Summary: Round Robin Database Tool to store and display time-series data
Name: rrdtool
Version: 1.4.4
Release: 1%{?dist}
Release: 2%{?dist}
License: GPLv2+ with exceptions
Group: Applications/Databases
URL: http://oss.oetiker.ch/rrdtool/
Source0: http://oss.oetiker.ch/%{name}/pub/%{name}-%{version}.tar.gz
Source1: php4-%{svnrev}.tar.gz
# Fix tcl-site configure option (upstream ticket #281)
Patch0: rrdtool-1.4.4-fix-tcl-site-option.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires: dejavu-sans-mono-fonts, dejavu-lgc-sans-mono-fonts
BuildRequires: gcc-c++, openssl-devel, freetype-devel
@ -22,7 +25,7 @@ BuildRequires: libpng-devel, zlib-devel, intltool >= 0.35.0
BuildRequires: cairo-devel >= 1.4.6, pango-devel >= 1.17
BuildRequires: libtool, groff
BuildRequires: gettext, libxml2-devel
BuildRequires: perl-ExtUtils-MakeMaker perl-devel
BuildRequires: perl-ExtUtils-MakeMaker, perl-devel
%description
RRD is the Acronym for Round Robin Database. RRD is a system to store and
@ -137,8 +140,25 @@ Requires: %{name} = %{version}-%{release}
The %{name}-ruby package includes RRDtool bindings for Ruby.
%endif
%if %{with_lua}
%define luaver 5.1
%define lualibdir %{_libdir}/lua/%{luaver}
%define luapkgdir %{_datadir}/lua/%{luaver}
%package lua
Summary: Lua RRDtool bindings
Group: Development/Languages
BuildRequires: lua, lua-devel
Requires: lua = %{luaver}
Requires: %{name} = %{version}-%{release}
%description lua
The %{name}-lua package includes RRDtool bindings for Lua.
%endif
%prep
%setup -q -n %{name}-%{version} %{?with_php: -a 1}
%patch0 -p1 -b .fix-tcl-site-option
# Fix to find correct python dir on lib64
%{__perl} -pi -e 's|get_python_lib\(0,0,prefix|get_python_lib\(1,0,prefix|g' \
@ -161,6 +181,7 @@ cp -p /usr/lib/rpm/config.{guess,sub} php4/
%build
%configure \
--with-perl-options='INSTALLDIRS="vendor"' \
--disable-rpath \
%if %{with_tcl}
--enable-tcl-site \
--with-tcllib=%{_libdir} \
@ -182,6 +203,12 @@ cp -p /usr/lib/rpm/config.{guess,sub} php4/
%{__perl} -pi.orig -e 's|-Wl,--rpath -Wl,\$rp||g' \
bindings/perl-shared/Makefile.PL
%if %{with_ruby}
# Remove Rpath from Ruby
%{__perl} -pi.orig -e 's|-Wl,--rpath -Wl,\$\(EPREFIX\)/lib||g' \
bindings/ruby/extconf.rb
%endif
# Force RRDp bits where we want 'em, not sure yet why the
# --with-perl-options and --libdir don't take
pushd bindings/perl-piped/
@ -253,8 +280,8 @@ find examples/ -type f -exec chmod 0644 {} \;
# Clean up the buildroot
%{__rm} -rf $RPM_BUILD_ROOT%{_docdir}/%{name}-* \
$RPM_BUILD_ROOT%{perl_vendorarch}/ntmake.pl \
$RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod \
$RPM_BUILD_ROOT%{perl_vendorarch}/ntmake.pl \
$RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod \
$RPM_BUILD_ROOT%{_datadir}/%{name}/examples \
$RPM_BUILD_ROOT%{perl_vendorarch}/auto/*/{.packlist,*.bs}
@ -322,7 +349,20 @@ find examples/ -type f -exec chmod 0644 {} \;
%{ruby_sitearch}/RRD.so
%endif
%if %{with_lua}
%files lua
%defattr(-,root,root,-)
%doc bindings/lua/README
%{lualibdir}/*
%endif
%changelog
* Tue Nov 23 2010 Jaroslav Škarvada <jskarvad@redhat.com> - 1.4.4-2
- Fixed mixed tabs and spaces rpmlint warning
- Fixed tcl-site configure option (upstream ticket #281)
- Removed Rpath from Ruby
- Enabled Lua bindings (#656080), thanks to Tim Niemueller
* Tue Nov 16 2010 Jaroslav Škarvada <jskarvad@redhat.com> - 1.4.4-1
- Update to rrdtool 1.4.4