Browse Source

* updated rrdtool (1.2.19 -> 1.2.23)

* removed obsolete patches and related hacks in the conf file
	* disabled ruby support which seems to be broken at the moment 


git-svn-id: svn://svn.opensde.net/opensde/package/trunk@21048 10447126-35f2-4685-b0cf-6dd780d3921f
early
Christian Wiese 18 years ago
parent
commit
ae8c82c388
  1. 30
      database/rrdtool/rrdtool-1.2.19-parsetime.patch
  2. 114
      database/rrdtool/rrdtool-1.2.19-rrd_dump.patch
  3. 2741
      database/rrdtool/rrdtool-1.2.19-rrd_getopt.patch
  4. 66
      database/rrdtool/rrdtool-1.2.19-rrdcgi.patch
  5. 193
      database/rrdtool/rrdtool-1.2.19-setuppy.patch
  6. 4
      database/rrdtool/rrdtool.conf
  7. 4
      database/rrdtool/rrdtool.desc

30
database/rrdtool/rrdtool-1.2.19-parsetime.patch

@ -1,30 +0,0 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../rrdtool/rrdtool-1.2.19-parsetime.patch
# Copyright (C) 2007 The OpenSDE Project
#
# More information can be found in the files COPYING and README.
#
# This patch file is dual-licensed. It is available under the license the
# patched project is licensed under, as long as it is an OpenSource license
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
# of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or (at your option) any later
# version.
# --- SDE-COPYRIGHT-NOTE-END ---
parsing absolute time should not send us 30,000 years into the future
(Tatsuki Makino tatsuki_makino hotmail.com)
--- ./src/parsetime.c (Revision 1001)
+++ ./src/parsetime.c (Revision 1002)
@@ -850,7 +850,7 @@
if ( ptv->tm.tm_hour == 30 ){
ptv->tm.tm_hour = hour_sv;
}
- if ( ptv->tm.tm_hour == 30000 ){
+ if ( ptv->tm.tm_year == 30000 ){
ptv->tm.tm_year = year_sv;
}
};

114
database/rrdtool/rrdtool-1.2.19-rrd_dump.patch

@ -1,114 +0,0 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../rrdtool/rrdtool-1.2.19-rrd_dump.patch
# Copyright (C) 2007 The OpenSDE Project
#
# More information can be found in the files COPYING and README.
#
# This patch file is dual-licensed. It is available under the license the
# patched project is licensed under, as long as it is an OpenSource license
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
# of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or (at your option) any later
# version.
# --- SDE-COPYRIGHT-NOTE-END ---
fix memmory problem in rrd_dump.c
--- ./src/rrd_dump.c (Revision 1009)
+++ ./src/rrd_dump.c (Revision 1010)
@@ -115,39 +115,39 @@
fprintf(out_file, "\t<lastupdate> %ld </lastupdate> <!-- %s -->\n\n",
rrd.live_head->last_up,somestring);
for(i=0;i<rrd.stat_head->ds_cnt;i++){
- fprintf(out_file, "\t<ds>\n");
- fprintf(out_file, "\t\t<name> %s </name>\n",rrd.ds_def[i].ds_nam);
- fprintf(out_file, "\t\t<type> %s </type>\n",rrd.ds_def[i].dst);
- if (dst_conv(rrd.ds_def[i].dst) != DST_CDEF) {
- fprintf(out_file, "\t\t<minimal_heartbeat> %lu </minimal_heartbeat>\n",rrd.ds_def[i].par[DS_mrhb_cnt].u_cnt);
- if (isnan(rrd.ds_def[i].par[DS_min_val].u_val)){
- fprintf(out_file, "\t\t<min> NaN </min>\n");
- } else {
- fprintf(out_file, "\t\t<min> %0.10e </min>\n",rrd.ds_def[i].par[DS_min_val].u_val);
- }
- if (isnan(rrd.ds_def[i].par[DS_max_val].u_val)){
- fprintf(out_file, "\t\t<max> NaN </max>\n");
- } else {
- fprintf(out_file, "\t\t<max> %0.10e </max>\n",rrd.ds_def[i].par[DS_max_val].u_val);
- }
- } else { /* DST_CDEF */
- char *str;
- rpn_compact2str((rpn_cdefds_t *) &(rrd.ds_def[i].par[DS_cdef]),rrd.ds_def,&str);
- fprintf(out_file, "\t\t<cdef> %s </cdef>\n", str);
- free(str);
- }
- fprintf(out_file, "\n\t\t<!-- PDP Status -->\n");
- fprintf(out_file, "\t\t<last_ds> %s </last_ds>\n",rrd.pdp_prep[i].last_ds);
- if (isnan(rrd.pdp_prep[i].scratch[PDP_val].u_val)){
- fprintf(out_file, "\t\t<value> NaN </value>\n");
- } else {
- fprintf(out_file, "\t\t<value> %0.10e </value>\n",rrd.pdp_prep[i].scratch[PDP_val].u_val);
- }
- fprintf(out_file, "\t\t<unknown_sec> %lu </unknown_sec>\n",
- rrd.pdp_prep[i].scratch[PDP_unkn_sec_cnt].u_cnt);
+ fprintf(out_file, "\t<ds>\n");
+ fprintf(out_file, "\t\t<name> %s </name>\n",rrd.ds_def[i].ds_nam);
+ fprintf(out_file, "\t\t<type> %s </type>\n",rrd.ds_def[i].dst);
+ if (dst_conv(rrd.ds_def[i].dst) != DST_CDEF) {
+ fprintf(out_file, "\t\t<minimal_heartbeat> %lu </minimal_heartbeat>\n",rrd.ds_def[i].par[DS_mrhb_cnt].u_cnt);
+ if (isnan(rrd.ds_def[i].par[DS_min_val].u_val)){
+ fprintf(out_file, "\t\t<min> NaN </min>\n");
+ } else {
+ fprintf(out_file, "\t\t<min> %0.10e </min>\n",rrd.ds_def[i].par[DS_min_val].u_val);
+ }
+ if (isnan(rrd.ds_def[i].par[DS_max_val].u_val)){
+ fprintf(out_file, "\t\t<max> NaN </max>\n");
+ } else {
+ fprintf(out_file, "\t\t<max> %0.10e </max>\n",rrd.ds_def[i].par[DS_max_val].u_val);
+ }
+ } else { /* DST_CDEF */
+ char *str=NULL;
+ rpn_compact2str((rpn_cdefds_t *) &(rrd.ds_def[i].par[DS_cdef]),rrd.ds_def,&str);
+ fprintf(out_file, "\t\t<cdef> %s </cdef>\n", str);
+ free(str);
+ }
+ fprintf(out_file, "\n\t\t<!-- PDP Status -->\n");
+ fprintf(out_file, "\t\t<last_ds> %s </last_ds>\n",rrd.pdp_prep[i].last_ds);
+ if (isnan(rrd.pdp_prep[i].scratch[PDP_val].u_val)){
+ fprintf(out_file, "\t\t<value> NaN </value>\n");
+ } else {
+ fprintf(out_file, "\t\t<value> %0.10e </value>\n",rrd.pdp_prep[i].scratch[PDP_val].u_val);
+ }
+ fprintf(out_file, "\t\t<unknown_sec> %lu </unknown_sec>\n",
+ rrd.pdp_prep[i].scratch[PDP_unkn_sec_cnt].u_cnt);
- fprintf(out_file, "\t</ds>\n\n");
- }
+ fprintf(out_file, "\t</ds>\n\n");
+ }
fputs("<!-- Round Robin Archives -->", out_file);
--- ./src/rrd_tune.c (Revision 1009)
+++ ./src/rrd_tune.c (Revision 1010)
@@ -290,7 +290,7 @@
rrd.ds_def[i].par[DS_min_val].u_val,
rrd.ds_def[i].par[DS_max_val].u_val);
} else {
- char *buffer;
+ char *buffer = NULL;
rpn_compact2str((rpn_cdefds_t *) &(rrd.ds_def[i].par[DS_cdef]),rrd.ds_def,&buffer);
printf("DS[%s] typ: %s\tcdef: %s\n", rrd.ds_def[i].ds_nam,rrd.ds_def[i].dst,buffer);
free(buffer);
--- ./src/rrd_info.c (Revision 1009)
+++ ./src/rrd_info.c (Revision 1010)
@@ -117,7 +117,7 @@
switch (current_ds) {
case DST_CDEF:
{
- char *buffer = 0;
+ char *buffer = NULL;
rpn_compact2str((rpn_cdefds_t *) &(rrd.ds_def[i].par[DS_cdef]),
rrd.ds_def, &buffer);
info.u_str = buffer;

2741
database/rrdtool/rrdtool-1.2.19-rrd_getopt.patch

File diff suppressed because it is too large Load Diff

66
database/rrdtool/rrdtool-1.2.19-rrdcgi.patch

@ -1,66 +0,0 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../rrdtool/rrdtool-1.2.19-rrdcgi.patch
# Copyright (C) 2007 The OpenSDE Project
#
# More information can be found in the files COPYING and README.
#
# This patch file is dual-licensed. It is available under the license the
# patched project is licensed under, as long as it is an OpenSource license
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
# of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or (at your option) any later
# version.
# --- SDE-COPYRIGHT-NOTE-END ---
Printstrftime on rrd_cgi.c returns an illegal value.
It causes segmentation fault error. (Tatsuki Makino tatsuki_makino hotmail.com)
--- ./src/rrd_cgi.c (Revision 1000)
+++ ./src/rrd_cgi.c (Revision 1001)
@@ -574,7 +574,7 @@
/* Make sure that we were given the right number of args */
if( argc != 4) {
rrd_set_error( "wrong number of args %d", argc);
- return (char *) -1;
+ return stralloc("");
}
/* Init start and end time */
@@ -584,14 +584,14 @@
/* Parse the start and end times we were given */
if( (parsetime_error = parsetime( args[1], &start_tv))) {
rrd_set_error( "start time: %s", parsetime_error);
- return (char *) -1;
+ return stralloc("");
}
if( (parsetime_error = parsetime( args[2], &end_tv))) {
rrd_set_error( "end time: %s", parsetime_error);
- return (char *) -1;
+ return stralloc("");
}
if( proc_start_end( &start_tv, &end_tv, &start_tmp, &end_tmp) == -1) {
- return (char *) -1;
+ return stralloc("");
}
/* Do we do the start or end */
@@ -603,7 +603,7 @@
}
else {
rrd_set_error( "start/end not found in '%s'", args[0]);
- return (char *) -1;
+ return stralloc("");
}
/* now format it */
@@ -612,7 +612,7 @@
}
else {
rrd_set_error( "strftime failed");
- return (char *) -1;
+ return stralloc("");
}
}

193
database/rrdtool/rrdtool-1.2.19-setuppy.patch

@ -1,193 +0,0 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../rrdtool/rrdtool-1.2.19-setuppy.patch
# Copyright (C) 2007 The OpenSDE Project
#
# More information can be found in the files COPYING and README.
#
# This patch file is dual-licensed. It is available under the license the
# patched project is licensed under, as long as it is an OpenSource license
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
# of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or (at your option) any later
# version.
# --- SDE-COPYRIGHT-NOTE-END ---
use setup.py for python install and build work instad of trying todo
it on our own
--- /dev/null 2007-03-06 16:53:58.620152249 +0200
+++ ./bindings/python/setup.py 2007-03-08 14:42:01.000000000 +0200
@@ -0,0 +1,56 @@
+#! /usr/bin/env python
+#
+# setup.py
+#
+# py-rrdtool distutil setup
+#
+# Author : Hye-Shik Chang <perky@fallin.lv>
+# Date : $Date: 2003/02/14 02:38:16 $
+# Created : 24 May 2002
+#
+# $Revision: 1.7 $
+#
+# ==========================================================================
+# This file is part of py-rrdtool.
+#
+# py-rrdtool is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published
+# by the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# py-rrdtool is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with Foobar; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+#
+
+from distutils.core import setup, Extension
+import sys, os
+
+RRDBASE = os.environ.get('LOCALBASE', '../../src')
+library_dir = os.environ.get('LIBDIR', os.path.join(RRDBASE, 'lib'))
+include_dir = os.environ.get('INCDIR', RRDBASE)
+
+setup(name = "py-rrdtool",
+ version = "0.2.1",
+ description = "Python Interface to RRDTool",
+ author = "Hye-Shik Chang",
+ author_email = "perky@fallin.lv",
+ license = "LGPL",
+ url = "http://oss.oetiker.ch/rrdtool",
+ #packages = ['rrdtool'],
+ ext_modules = [
+ Extension(
+ "rrdtoolmodule",
+ ["rrdtoolmodule.c"],
+ libraries=['rrd'],
+ runtime_library_dirs=[library_dir],
+ library_dirs=[library_dir],
+ include_dirs=[include_dir],
+ )
+ ]
+)
--- ./bindings/python/Makefile.am (Revision 990)
+++ ./bindings/python/Makefile.am (Revision 993)
@@ -1,12 +0,0 @@
-AM_CPPFLAGS = @CFLAGS@ -I$(top_srcdir)/src @PYTHON_INCLUDES@
-
-pyexec_PROGRAMS = rrdtoolmodule.so
-
-rrdtoolmodule_so_LDADD = $(top_builddir)/src/librrd.la
-rrdtoolmodule_so_SOURCES = rrdtoolmodule.c
-
-noinst_HEADERS = rrd_extra.h
-
-clean-local:
- rm -rf build
-
--- ./bindings/Makefile.am (Revision 990)
+++ ./bindings/Makefile.am (Revision 993)
@@ -1,3 +1,5 @@
+.PHONY: python ruby
+
if BUILD_TCL
SUB_tcl = tcl
endif
@@ -2,16 +4,13 @@
-if BUILD_PYTHON
-SUB_python = python
-endif
+SUBDIRS = $(SUB_tcl)
-SUBDIRS = $(SUB_tcl) $(SUB_python)
-
# the following files are not mentioned in any other Makefile
EXTRA_DIST = perl-piped/MANIFEST perl-piped/README perl-piped/Makefile.PL perl-piped/RRDp.pm perl-piped/t/base.t \
- perl-shared/ntmake.pl perl-shared/MANIFEST perl-shared/README perl-shared/Makefile.PL perl-shared/RRDs.pm perl-shared/RRDs.xs perl-shared/t/base.t \
- ruby/CHANGES ruby/README ruby/extconf.rb ruby/main.c ruby/test.rb
+ perl-shared/ntmake.pl perl-shared/MANIFEST perl-shared/README perl-shared/Makefile.PL perl-shared/RRDs.pm perl-shared/RRDs.xs perl-shared/t/base.t \
+ ruby/CHANGES ruby/README ruby/extconf.rb ruby/main.c ruby/test.rb \
+ python/ACKNOWLEDGEMENT python/AUTHORS python/COPYING python/README python/rrd_extra.h python/rrdtoolmodule.c python/setup.py
# add the following to the all target
-all-local: @COMP_PERL@ @COMP_RUBY@
+all-local: @COMP_PERL@ @COMP_RUBY@ @COMP_PYTHON@
@@ -21,11 +20,16 @@
test -f perl-piped/Makefile && cd perl-piped && $(MAKE) install || true
test -f perl-shared/Makefile && cd perl-shared && $(MAKE) install || true
test -f ruby/Makefile && cd ruby && $(MAKE) EPREFIX=$(exec_prefix) $(RUBY_MAKE_OPTIONS) install || true
+ test -d python/build && cd python && rm -rf build && env LIBDIR=$(libdir) $(PYTHON) setup.py install --prefix=$(prefix) --exec-prefix=$(exec_prefix) || true
# rules for buildung the ruby module
ruby:
cd ruby && $(RUBY) extconf.rb && $(MAKE) EPREFIX=$(exec_prefix) $(RUBY_MAKE_OPTIONS)
+# rules for buildung the pyton module
+python:
+ cd python && env LIBDIR=../../src/.libs $(PYTHON) setup.py build
+
# rules for building the perl module
perl_piped: perl-piped/Makefile
cd perl-piped && $(MAKE)
@@ -46,5 +50,5 @@
test -f perl-shared/Makefile && cd perl-shared && $(MAKE) clean || true
test -f perl-shared/Makefile && rm -f perl-shared/Makefile || true
test -f ruby/Makefile && cd ruby && $(MAKE) clean && rm Makefile || true
-
+ test -d python/build && cd python && rm -rf build || true
##END##
--- ./configure.ac (Revision 990)
+++ ./configure.ac (Revision 993)
@@ -504,6 +504,7 @@
fi
+
AC_MSG_CHECKING(Ruby Modules to build)
AC_MSG_RESULT(${COMP_RUBY:-No Ruby Modules will be built})
@@ -583,8 +584,14 @@
AM_CHECK_PYTHON_HEADERS(,[enable_python=no;AC_MSG_WARN(could not find Python headers)])
fi
-AM_CONDITIONAL(BUILD_PYTHON,[test "$enable_python" = "yes"])
+if test x$enable_python = xno; then
+ COMP_PYTHON=
+else
+ COMP_PYTHON="python"
+fi
+AC_SUBST(COMP_PYTHON)
+
dnl Check for nroff
AC_PATH_PROGS(NROFF, gnroff nroff)
AC_PATH_PROGS(TROFF, groff troff)
--- ./Makefile.am (Revision 990)
+++ ./Makefile.am (Revision 993)
@@ -45,6 +45,6 @@
cd bindings/tcl && $(MAKE) tcl-install
site-python-install: all
- cd bindings/python && $(MAKE) python-install
+ cd bindings/python && $(PYTHON) setup.py install
##END##
--- ./configure.ac (Revision 994)
+++ ./configure.ac (Revision 995)
@@ -616,7 +616,6 @@
AC_CONFIG_FILES([bindings/Makefile])
AC_CONFIG_FILES([bindings/tcl/Makefile])
AC_CONFIG_FILES([bindings/tcl/ifOctets.tcl])
-AC_CONFIG_FILES([bindings/python/Makefile])
AC_CONFIG_FILES([Makefile])
AC_CONFIG_COMMANDS([default],[[ chmod +x examples/*.pl]],[[]])

4
database/rrdtool/rrdtool.conf

@ -16,7 +16,7 @@
# we have to run auto*crap because we patch .am and .ac files
# for rrdtool-1.2.19
hook_add preconf 5 "aclocal && automake --add-missing ; autoconf"
# hook_add preconf 5 "aclocal && automake --add-missing ; autoconf"
var_append extraconfopt " " "--enable-shared"
@ -33,3 +33,5 @@ else
var_append extraconfopt ' ' "--disable-perl"
fi
# ruby support is broken right now (2007-05-13)
var_append extraconfopt ' ' "--disable-ruby"

4
database/rrdtool/rrdtool.desc

@ -35,7 +35,7 @@
[L] GPL
[S] Stable
[V] 1.2.19
[V] 1.2.23
[P] X -----5---9 125.000
[D] 3686089427 rrdtool-1.2.19.tar.gz http://oss.oetiker.ch/rrdtool/pub/
[D] 2708609138 rrdtool-1.2.23.tar.gz http://oss.oetiker.ch/rrdtool/pub/

Loading…
Cancel
Save