package init
This commit is contained in:
parent
0cbf785267
commit
d60a870f2a
BIN
php4-r1190.tar.gz
Normal file
BIN
php4-r1190.tar.gz
Normal file
Binary file not shown.
100
rrdtool-1.4.4-php54.patch
Normal file
100
rrdtool-1.4.4-php54.patch
Normal file
@ -0,0 +1,100 @@
|
|||||||
|
diff -up rrdtool-1.4.4/php4/rrdtool.c.php54 rrdtool-1.4.4/php4/rrdtool.c
|
||||||
|
--- rrdtool-1.4.4/php4/rrdtool.c.php54 2011-12-29 08:57:00.790784347 +0100
|
||||||
|
+++ rrdtool-1.4.4/php4/rrdtool.c 2011-12-29 09:00:55.960794927 +0100
|
||||||
|
@@ -39,7 +39,7 @@
|
||||||
|
ZEND_DECLARE_MODULE_GLOBALS(rrdtool)
|
||||||
|
*/
|
||||||
|
|
||||||
|
-function_entry rrdtool_functions[] = {
|
||||||
|
+zend_function_entry rrdtool_functions[] = {
|
||||||
|
PHP_FE(rrd_graph, NULL)
|
||||||
|
PHP_FE(rrd_fetch, NULL)
|
||||||
|
PHP_FE(rrd_error, NULL)
|
||||||
|
@@ -119,8 +119,8 @@ PHP_MINFO_FUNCTION(rrdtool)
|
||||||
|
Creates a graph based on options passed via an array */
|
||||||
|
PHP_FUNCTION(rrd_graph)
|
||||||
|
{
|
||||||
|
- pval *file, *args, *p_argc;
|
||||||
|
- pval *entry;
|
||||||
|
+ zval *file, *args, *p_argc;
|
||||||
|
+ zval *entry;
|
||||||
|
zval *p_calcpr;
|
||||||
|
HashTable *args_arr;
|
||||||
|
int i, xsize, ysize, argc;
|
||||||
|
@@ -155,7 +155,7 @@ PHP_FUNCTION(rrd_graph)
|
||||||
|
|
||||||
|
for (i = 3; i < argc; i++)
|
||||||
|
{
|
||||||
|
- pval **dataptr;
|
||||||
|
+ zval **dataptr;
|
||||||
|
|
||||||
|
if ( zend_hash_get_current_data(args_arr, (void *) &dataptr) == FAILURE )
|
||||||
|
continue;
|
||||||
|
@@ -216,9 +216,8 @@ PHP_FUNCTION(rrd_graph)
|
||||||
|
Fetch info from an RRD file */
|
||||||
|
PHP_FUNCTION(rrd_fetch)
|
||||||
|
{
|
||||||
|
- pval *file, *args, *p_argc;
|
||||||
|
- pval *entry;
|
||||||
|
- pval *p_start, *p_end, *p_step, *p_ds_cnt;
|
||||||
|
+ zval *file, *args, *p_argc;
|
||||||
|
+ zval *entry;
|
||||||
|
HashTable *args_arr;
|
||||||
|
zval *p_ds_namv, *p_data;
|
||||||
|
int i, j, argc;
|
||||||
|
@@ -254,7 +253,7 @@ PHP_FUNCTION(rrd_fetch)
|
||||||
|
|
||||||
|
for (i = 3; i < argc; i++)
|
||||||
|
{
|
||||||
|
- pval **dataptr;
|
||||||
|
+ zval **dataptr;
|
||||||
|
|
||||||
|
if ( zend_hash_get_current_data(args_arr, (void *) &dataptr) == FAILURE )
|
||||||
|
continue;
|
||||||
|
@@ -361,7 +360,7 @@ PHP_FUNCTION(rrd_clear_error)
|
||||||
|
Update an RRD file with values specified */
|
||||||
|
PHP_FUNCTION(rrd_update)
|
||||||
|
{
|
||||||
|
- pval *file, *opt;
|
||||||
|
+ zval *file, *opt;
|
||||||
|
char **argv;
|
||||||
|
|
||||||
|
if ( rrd_test_error() )
|
||||||
|
@@ -404,7 +403,7 @@ PHP_FUNCTION(rrd_update)
|
||||||
|
Gets last update time of an RRD file */
|
||||||
|
PHP_FUNCTION(rrd_last)
|
||||||
|
{
|
||||||
|
- pval *file;
|
||||||
|
+ zval *file;
|
||||||
|
unsigned long retval;
|
||||||
|
|
||||||
|
char **argv = (char **) emalloc(3 * sizeof(char *));
|
||||||
|
@@ -439,8 +438,8 @@ PHP_FUNCTION(rrd_last)
|
||||||
|
Create an RRD file with the options passed (passed via array) */
|
||||||
|
PHP_FUNCTION(rrd_create)
|
||||||
|
{
|
||||||
|
- pval *file, *args, *p_argc;
|
||||||
|
- pval *entry;
|
||||||
|
+ zval *file, *args, *p_argc;
|
||||||
|
+ zval *entry;
|
||||||
|
char **argv;
|
||||||
|
HashTable *args_arr;
|
||||||
|
int argc, i;
|
||||||
|
@@ -449,7 +448,7 @@ PHP_FUNCTION(rrd_create)
|
||||||
|
rrd_clear_error();
|
||||||
|
|
||||||
|
if ( ZEND_NUM_ARGS() == 3 &&
|
||||||
|
- getParameters(ht, 3, &file, &args, &p_argc) == SUCCESS )
|
||||||
|
+ zend_get_parameters(ht, 3, &file, &args, &p_argc) == SUCCESS )
|
||||||
|
{
|
||||||
|
if ( args->type != IS_ARRAY )
|
||||||
|
{
|
||||||
|
@@ -473,7 +472,7 @@ PHP_FUNCTION(rrd_create)
|
||||||
|
|
||||||
|
for (i = 3; i < argc; i++)
|
||||||
|
{
|
||||||
|
- pval **dataptr;
|
||||||
|
+ zval **dataptr;
|
||||||
|
|
||||||
|
if ( zend_hash_get_current_data(args_arr, (void *) &dataptr) == FAILURE )
|
||||||
|
continue;
|
||||||
83
rrdtool-1.4.7-php55.patch
Normal file
83
rrdtool-1.4.7-php55.patch
Normal file
@ -0,0 +1,83 @@
|
|||||||
|
--- rrdtool-1.4.7/php4/rrdtool.c.orig 2013-03-22 14:54:18.520877577 +0100
|
||||||
|
+++ rrdtool-1.4.7/php4/rrdtool.c 2013-03-22 14:59:23.056303502 +0100
|
||||||
|
@@ -20,13 +20,11 @@
|
||||||
|
|
||||||
|
/* PHP Includes */
|
||||||
|
#include "php.h"
|
||||||
|
-#include "php_logos.h"
|
||||||
|
#include "ext/standard/info.h"
|
||||||
|
#include "SAPI.h"
|
||||||
|
|
||||||
|
/* rrdtool includes */
|
||||||
|
#include "php_rrdtool.h"
|
||||||
|
-#include "rrdtool_logo.h"
|
||||||
|
#include <rrd.h>
|
||||||
|
|
||||||
|
#ifdef HAVE_CONFIG_H
|
||||||
|
@@ -48,7 +46,6 @@
|
||||||
|
PHP_FE(rrd_last, NULL)
|
||||||
|
PHP_FE(rrd_create, NULL)
|
||||||
|
PHP_FE(rrdtool_info, NULL)
|
||||||
|
- PHP_FE(rrdtool_logo_guid, NULL)
|
||||||
|
{NULL, NULL, NULL}
|
||||||
|
};
|
||||||
|
|
||||||
|
@@ -83,8 +80,6 @@
|
||||||
|
/* {{{ PHP_MINIT_FUNCTION */
|
||||||
|
PHP_MINIT_FUNCTION(rrdtool)
|
||||||
|
{
|
||||||
|
- php_register_info_logo(RRDTOOL_LOGO_GUID , "image/gif", rrdtool_logo , sizeof(rrdtool_logo));
|
||||||
|
-
|
||||||
|
return SUCCESS;
|
||||||
|
}
|
||||||
|
/* }}} */
|
||||||
|
@@ -92,8 +87,6 @@
|
||||||
|
/* {{{ PHP_MSHUTDOWN_FUNCTION */
|
||||||
|
PHP_MSHUTDOWN_FUNCTION(rrdtool)
|
||||||
|
{
|
||||||
|
- php_unregister_info_logo(RRDTOOL_LOGO_GUID);
|
||||||
|
-
|
||||||
|
return SUCCESS;
|
||||||
|
}
|
||||||
|
/* }}} */
|
||||||
|
@@ -102,11 +95,6 @@
|
||||||
|
PHP_MINFO_FUNCTION(rrdtool)
|
||||||
|
{
|
||||||
|
php_info_print_box_start(1);
|
||||||
|
- PUTS("<a href=\"http://people.ee.ethz.ch/~oetiker/webtools/rrdtool/\" target=\"rrdtool\"><img border=\"0\" src=\"");
|
||||||
|
- if (SG(request_info).request_uri) {
|
||||||
|
- PUTS(SG(request_info).request_uri);
|
||||||
|
- }
|
||||||
|
- PUTS("?="RRDTOOL_LOGO_GUID"\" alt=\"ClamAV logo\" /></a>\n");
|
||||||
|
php_printf("<h1 class=\"p\">rrdtool Version %s</h1>\n", PHP_RRD_VERSION_STRING);
|
||||||
|
php_info_print_box_end();
|
||||||
|
php_info_print_table_start();
|
||||||
|
@@ -548,11 +536,6 @@
|
||||||
|
PUTS("<body><div class=\"center\">\n");
|
||||||
|
|
||||||
|
php_info_print_box_start(1);
|
||||||
|
- PUTS("<a href=\"http://people.ee.ethz.ch/~oetiker/webtools/rrdtool/\" target=\"rrdtool\"><img border=\"0\" src=\"");
|
||||||
|
- if (SG(request_info).request_uri) {
|
||||||
|
- PUTS(SG(request_info).request_uri);
|
||||||
|
- }
|
||||||
|
- PUTS("?="RRDTOOL_LOGO_GUID"\" alt=\"ClamAV logo\" /></a>\n");
|
||||||
|
php_printf("<h1 class=\"p\">rrdtool Version %s</h1>\n", PHP_RRD_VERSION_STRING);
|
||||||
|
php_info_print_box_end();
|
||||||
|
php_info_print_table_start();
|
||||||
|
@@ -590,16 +573,6 @@
|
||||||
|
}
|
||||||
|
/* }}} */
|
||||||
|
|
||||||
|
-PHP_FUNCTION(rrdtool_logo_guid)
|
||||||
|
-{
|
||||||
|
- if (ZEND_NUM_ARGS() != 0) {
|
||||||
|
- WRONG_PARAM_COUNT;
|
||||||
|
- }
|
||||||
|
-
|
||||||
|
- RETURN_STRINGL(RRDTOOL_LOGO_GUID, sizeof(RRDTOOL_LOGO_GUID)-1, 1);
|
||||||
|
-}
|
||||||
|
-/* }}} */
|
||||||
|
-
|
||||||
|
#endif /* HAVE_RRDTOOL */
|
||||||
|
|
||||||
|
/*
|
||||||
11
rrdtool-1.4.8-php-ppc-fix.patch
Normal file
11
rrdtool-1.4.8-php-ppc-fix.patch
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
--- a/php4/ltconfig 2014-08-11 13:01:13.020065855 +0000
|
||||||
|
+++ a/php4/ltconfig 2014-08-11 13:01:23.870060274 +0000
|
||||||
|
@@ -1939,7 +1939,7 @@
|
||||||
|
else
|
||||||
|
# Only the GNU ld.so supports shared libraries on MkLinux.
|
||||||
|
case "$host_cpu" in
|
||||||
|
- powerpc*) dynamic_linker=no ;;
|
||||||
|
+# powerpc*) dynamic_linker=no ;;
|
||||||
|
*) dynamic_linker='Linux ld.so' ;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
26
rrdtool-1.6.0-ruby-2-fix.patch
Normal file
26
rrdtool-1.6.0-ruby-2-fix.patch
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
diff --git a/bindings/Makefile.am b/bindings/Makefile.am
|
||||||
|
index 54f5c23..ee85c23 100644
|
||||||
|
--- a/bindings/Makefile.am
|
||||||
|
+++ b/bindings/Makefile.am
|
||||||
|
@@ -35,8 +35,9 @@ install-data-local:
|
||||||
|
&& $(MAKE) install ) \
|
||||||
|
|| true
|
||||||
|
$(AM_V_GEN)test -f ${builddir}/ruby/Makefile \
|
||||||
|
- && ( cd ${builddir}/ruby \
|
||||||
|
- && $(MAKE) EPREFIX=$(DESTDIR)$(exec_prefix) $(RUBY_MAKE_OPTIONS) install ) \
|
||||||
|
+ && ( $(MKDIR_P) $(DESTDIR)$(libdir)/ruby/vendor_ruby && cd ${builddir}/ruby \
|
||||||
|
+ && $(MAKE) EPREFIX=$(DESTDIR)$(exec_prefix) $(RUBY_MAKE_OPTIONS) \
|
||||||
|
+ hdrdir="$(includedir)" rubyhdrdir="$(includedir)" includedir="$(includedir)" install ) \
|
||||||
|
|| true
|
||||||
|
$(AM_V_GEN)test -d ${builddir}/python/build \
|
||||||
|
&& ( cd ${builddir}/python \
|
||||||
|
@@ -57,7 +58,8 @@ ruby:
|
||||||
|
EPREFIX=$(exec_prefix) \
|
||||||
|
ABS_TOP_SRCDIR=${abs_top_srcdir} \
|
||||||
|
ABS_TOP_BUILDDIR=${abs_top_builddir} \
|
||||||
|
- $(RUBY_MAKE_OPTIONS) RUBYARCHDIR= )
|
||||||
|
+ $(RUBY_MAKE_OPTIONS) hdrdir="$(includedir)" \
|
||||||
|
+ rubyhdrdir="$(includedir)" includedir="$(includedir)" RUBYARCHDIR= )
|
||||||
|
|
||||||
|
# rules for building the python module
|
||||||
|
python:
|
||||||
49
rrdtool-1.7.0-fix-configure-parameters.patch
Normal file
49
rrdtool-1.7.0-fix-configure-parameters.patch
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
--- ./configure.ac.orig 2017-05-16 10:32:11.000000000 +0200
|
||||||
|
+++ ./configure.ac 2018-01-05 14:00:09.261806009 +0100
|
||||||
|
@@ -512,7 +512,11 @@
|
||||||
|
|
||||||
|
have_libdbi=no
|
||||||
|
|
||||||
|
-AC_ARG_ENABLE(libdbi,AS_HELP_STRING([--disable-libdbi],[do not build in support for libdbi]),[],[
|
||||||
|
+AC_ARG_ENABLE(libdbi,AS_HELP_STRING([--disable-libdbi],[do not build in support for libdbi]),
|
||||||
|
+[],
|
||||||
|
+[enable_libdbi=yes])
|
||||||
|
+
|
||||||
|
+AS_IF([test "x$enable_libdbi" != xno], [
|
||||||
|
AC_CHECK_HEADER(dbi/dbi.h, [
|
||||||
|
AC_CHECK_LIB(dbi, dbi_initialize, [
|
||||||
|
AC_DEFINE(HAVE_LIBDBI,[1],[have got libdbi installed])
|
||||||
|
@@ -526,7 +530,11 @@
|
||||||
|
|
||||||
|
have_librados=no
|
||||||
|
|
||||||
|
-AC_ARG_ENABLE(librados,AS_HELP_STRING([--disable-librados],[do not build in support for librados]),[],[
|
||||||
|
+AC_ARG_ENABLE(librados,AS_HELP_STRING([--disable-librados],[do not build in support for librados]),
|
||||||
|
+[],
|
||||||
|
+[enable_librados=yes])
|
||||||
|
+
|
||||||
|
+AS_IF([test "x$enable_librados" != xno], [
|
||||||
|
AC_CHECK_HEADER(rados/librados.h, [
|
||||||
|
AC_DEFINE(HAVE_LIBRADOS,[1],[have got librados installed])
|
||||||
|
LIBS="${LIBS} -lrados"
|
||||||
|
@@ -538,7 +546,11 @@
|
||||||
|
|
||||||
|
have_libwrap=no
|
||||||
|
|
||||||
|
-AC_ARG_ENABLE(libwrap, AS_HELP_STRING([--disable-libwrap], [do not build in support for libwrap (tcp wrapper)]),[],[
|
||||||
|
+AC_ARG_ENABLE(libwrap, AS_HELP_STRING([--disable-libwrap], [do not build in support for libwrap (tcp wrapper)]),
|
||||||
|
+[],
|
||||||
|
+[enable_libwrap=yes])
|
||||||
|
+
|
||||||
|
+AS_IF([test "x$enable_libwrap" != xno], [
|
||||||
|
AC_CHECK_HEADER(tcpd.h,[
|
||||||
|
AC_CHECK_FUNCS(hosts_access, [
|
||||||
|
AC_DEFINE(HAVE_LIBWRAP,[1],[have got libwrap installed])
|
||||||
|
@@ -554,7 +566,6 @@
|
||||||
|
])
|
||||||
|
])
|
||||||
|
|
||||||
|
-
|
||||||
|
AM_CONDITIONAL(BUILD_LIBWRAP,[test $have_libwrap != no])
|
||||||
|
|
||||||
|
AM_CONDITIONAL(BUILD_RRDGRAPH,[test $enable_rrd_graph != no])
|
||||||
BIN
rrdtool-1.7.0.tar.gz
Normal file
BIN
rrdtool-1.7.0.tar.gz
Normal file
Binary file not shown.
218
rrdtool.spec
Normal file
218
rrdtool.spec
Normal file
@ -0,0 +1,218 @@
|
|||||||
|
Name: rrdtool
|
||||||
|
Version: 1.7.0
|
||||||
|
Release: 18
|
||||||
|
Summary: RA tool for data logging and analysis
|
||||||
|
License: GPLv2+ with exceptions
|
||||||
|
URL: http://oss.oetiker.ch/rrdtool/
|
||||||
|
Source0: http://oss.oetiker.ch/%{name}/pub/%{name}-%{version}.tar.gz
|
||||||
|
Source1: php4-r1190.tar.gz
|
||||||
|
Patch0001: rrdtool-1.6.0-ruby-2-fix.patch
|
||||||
|
Patch0002: rrdtool-1.4.8-php-ppc-fix.patch
|
||||||
|
Patch0003: rrdtool-1.7.0-fix-configure-parameters.patch
|
||||||
|
|
||||||
|
Requires(post): systemd
|
||||||
|
Requires(preun): systemd
|
||||||
|
Requires(postun): systemd
|
||||||
|
BuildRequires: gcc-c++ openssl-devel freetype-devel libpng-devel zlib-devel
|
||||||
|
BuildRequires: intltool >= 0.35.0 cairo-devel >= 1.4.6, pango-devel >= 1.17
|
||||||
|
BuildRequires: libtool groff gettext libxml2-devel systemd automake autoconf
|
||||||
|
BuildRequires: perl-ExtUtils-MakeMaker perl-generators perl-Pod-Html perl-devel
|
||||||
|
BuildRequires: libdbi-devel
|
||||||
|
Requires: dejavu-sans-mono-fonts
|
||||||
|
|
||||||
|
%description
|
||||||
|
A tool to log and analyze data gathered from all kinds of data sources.
|
||||||
|
The data analysis part of RRDtool is based on the ability to quickly
|
||||||
|
generate graphical representations of the data values collected over a
|
||||||
|
definable time period.
|
||||||
|
|
||||||
|
%package devel
|
||||||
|
Summary: RRDtool header files
|
||||||
|
Requires: %{name} = %{version}-%{release} pkgconfig
|
||||||
|
|
||||||
|
%description devel
|
||||||
|
RRD stands for Round Robin Database. RRD is a system to store and
|
||||||
|
display time-series data (i.e. network bandwidth, machine-room temperature,
|
||||||
|
server load average). This package allow you to build programs making
|
||||||
|
use of the library.
|
||||||
|
|
||||||
|
%package help
|
||||||
|
Summary: Help document files for %{name}
|
||||||
|
Provides: %{name}-doc = %{version}-%{release}
|
||||||
|
Obsoletes: %{name}-doc < %{version}-%{release}
|
||||||
|
|
||||||
|
%description help
|
||||||
|
Help document files for %{name}.
|
||||||
|
|
||||||
|
%package perl
|
||||||
|
Summary: Perl RRDtool bindings module
|
||||||
|
Requires: %{name} = %{version}-%{release}
|
||||||
|
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
|
||||||
|
Provides: perl-%{name} = %{version}-%{release}
|
||||||
|
Obsoletes: perl-%{name} < %{version}-%{release}
|
||||||
|
|
||||||
|
%description perl
|
||||||
|
The Perl RRDtool bindings module.
|
||||||
|
|
||||||
|
%{!?rrd_python3_version: %global rrd_python3_version %(%{__python3} -c 'import sys; print(sys.version.split(" ")[0])' || echo "3.14")}
|
||||||
|
|
||||||
|
%package -n python3-rrdtool
|
||||||
|
Summary: Python RRDtool bindings module
|
||||||
|
BuildRequires: python3-devel python3-setuptools
|
||||||
|
Requires: python3 >= %{rrd_python3_version} %{name} = %{version}-%{release}
|
||||||
|
%{?python_provide:%python_provide python3-rrdtool}
|
||||||
|
|
||||||
|
%description -n python3-rrdtool
|
||||||
|
Python RRDtool bindings module.
|
||||||
|
|
||||||
|
%package tcl
|
||||||
|
Summary: Tcl RRDtool bindings module
|
||||||
|
BuildRequires: tcl-devel >= 8.0
|
||||||
|
Requires: tcl >= 8.0 %{name} = %{version}-%{release}
|
||||||
|
Provides: tcl-%{name} = %{version}-%{release}
|
||||||
|
Obsoletes: tcl-%{name} < %{version}-%{release}
|
||||||
|
|
||||||
|
%description tcl
|
||||||
|
The %{name}-tcl package includes RRDtool bindings for Tcl.
|
||||||
|
|
||||||
|
%{!?ruby_vendorarchdir: %global ruby_vendorarchdir %(ruby -rrbconfig -e 'puts Config::CONFIG["vendorarchdir"]')}
|
||||||
|
|
||||||
|
%package ruby
|
||||||
|
Summary: Ruby RRDtool bindings module
|
||||||
|
BuildRequires: ruby ruby-devel
|
||||||
|
Requires: %{name} = %{version}-%{release}
|
||||||
|
|
||||||
|
%description ruby
|
||||||
|
The %{name}-ruby package includes RRDtool bindings for Ruby.
|
||||||
|
|
||||||
|
%{!?luaver: %global luaver %(lua -e "print(string.sub(_VERSION, 5))")}
|
||||||
|
%global luapkgdir %{_datadir}/lua/%{luaver}
|
||||||
|
|
||||||
|
%package lua
|
||||||
|
Summary: Lua RRDtool bindings module
|
||||||
|
BuildRequires: lua lua-devel
|
||||||
|
Requires: lua(abi) = %{luaver}
|
||||||
|
Requires: %{name} = %{version}-%{release}
|
||||||
|
|
||||||
|
%description lua
|
||||||
|
The %{name}-lua package includes RRDtool bindings for Lua.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%autosetup -n %{name}-%{version} -a 1 -p1
|
||||||
|
|
||||||
|
perl -pi -e 's|get_python_lib\(0,0,prefix|get_python_lib\(1,0,prefix|g' configure
|
||||||
|
perl -pi.orig -e 's|/lib\b|/%{_lib}|g' configure Makefile.in php4/configure php4/ltconfig*
|
||||||
|
perl -pi.orig -e 's|1.299907080300|1.29990708|' bindings/perl-shared/RRDs.pm bindings/perl-piped/RRDp.pm
|
||||||
|
cp -p /usr/lib/rpm/config.{guess,sub} php4/
|
||||||
|
|
||||||
|
%build
|
||||||
|
./bootstrap
|
||||||
|
%configure --with-perl-options='INSTALLDIRS="vendor"' --disable-rpath \
|
||||||
|
--enable-tcl-site --with-tcllib=%{_libdir} --enable-python \
|
||||||
|
--enable-ruby --enable-libdbi --disable-static --with-pic
|
||||||
|
|
||||||
|
perl -pi.orig -e 's|-Wl,--rpath -Wl,\$rp||g' bindings/perl-shared/Makefile.PL
|
||||||
|
perl -pi.orig -e 's|-Wl,--rpath -Wl,\$\(EPREFIX\)/lib||g' bindings/ruby/extconf.rb
|
||||||
|
sed -i 's|extconf.rb \\|extconf.rb --vendor \\|' bindings/Makefile
|
||||||
|
|
||||||
|
cd bindings/perl-piped/
|
||||||
|
perl Makefile.PL INSTALLDIRS=vendor
|
||||||
|
perl -pi.orig -e 's|/lib/perl|/%{_lib}/perl|g' Makefile
|
||||||
|
cd -
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
find examples/ -type f -exec perl -pi -e 's|^#! \@perl\@|#!%{__perl}|gi' {} \;
|
||||||
|
find examples/ -name "*.pl" -exec perl -pi -e 's|\015||gi' {} \;
|
||||||
|
|
||||||
|
cd bindings/python
|
||||||
|
%py3_build
|
||||||
|
cd -
|
||||||
|
|
||||||
|
%install
|
||||||
|
export PYTHON=%{__python3}
|
||||||
|
%make_install PYTHON="%{__python3}"
|
||||||
|
|
||||||
|
mv $RPM_BUILD_ROOT%{perl_vendorlib}/RRDp.pm $RPM_BUILD_ROOT%{perl_vendorarch}/
|
||||||
|
install -d doc2/html doc2/txt
|
||||||
|
cp -a doc/*.txt doc2/txt/
|
||||||
|
cp -a doc/*.html doc2/html/
|
||||||
|
|
||||||
|
install -d doc3/html
|
||||||
|
mv doc2/html/RRD*.html doc3/html/
|
||||||
|
rm -f examples/Makefile* examples/*.in
|
||||||
|
find examples/ -type f -exec chmod 0644 {} \;
|
||||||
|
|
||||||
|
cd bindings/python
|
||||||
|
%py3_install
|
||||||
|
cd -
|
||||||
|
|
||||||
|
%find_lang %{name}
|
||||||
|
|
||||||
|
%check
|
||||||
|
|
||||||
|
%post
|
||||||
|
/sbin/ldconfig
|
||||||
|
%systemd_post rrdcached.service rrdcached.socket
|
||||||
|
|
||||||
|
%preun
|
||||||
|
%systemd_post rrdcached.service rrdcached.socket
|
||||||
|
|
||||||
|
%postun
|
||||||
|
/sbin/ldconfig
|
||||||
|
%systemd_post rrdcached.service rrdcached.socket
|
||||||
|
|
||||||
|
%files -f %{name}.lang
|
||||||
|
%license LICENSE
|
||||||
|
%doc CONTRIBUTORS COPYRIGHT TODO NEWS CHANGES THREADS
|
||||||
|
%{_bindir}/*
|
||||||
|
%{_libdir}/*.so.*
|
||||||
|
%{_unitdir}/rrdcached.service
|
||||||
|
%{_unitdir}/rrdcached.socket
|
||||||
|
%{_datadir}/%{name}
|
||||||
|
|
||||||
|
%files tcl
|
||||||
|
%doc bindings/tcl/README
|
||||||
|
%{_libdir}/tclrrd*.so
|
||||||
|
%{_libdir}/rrdtool/*.tcl
|
||||||
|
|
||||||
|
%files devel
|
||||||
|
%{_includedir}/*.h
|
||||||
|
%{_libdir}/lib*.so
|
||||||
|
%{_libdir}/pkgconfig/*.pc
|
||||||
|
%exclude %{_libdir}/*.la
|
||||||
|
%exclude %{perl_vendorlib}/leaktest.pl
|
||||||
|
%exclude %{_docdir}/%{name}-*
|
||||||
|
%exclude %{perl_vendorarch}/ntmake.pl
|
||||||
|
%exclude %{perl_archlib}/perllocal.pod
|
||||||
|
%exclude %{_datadir}/%{name}/examples
|
||||||
|
%exclude %{perl_vendorarch}/auto/*/{.packlist,*.bs}
|
||||||
|
|
||||||
|
%files ruby
|
||||||
|
%doc bindings/ruby/README
|
||||||
|
%{ruby_vendorarchdir}/RRD.so
|
||||||
|
|
||||||
|
%files perl
|
||||||
|
%doc doc3/html
|
||||||
|
%{perl_vendorarch}/*.pm
|
||||||
|
%attr(0755,root,root) %{perl_vendorarch}/auto/RRDs/
|
||||||
|
|
||||||
|
%files lua
|
||||||
|
%doc bindings/lua/README
|
||||||
|
%exclude %{_libdir}/lua/%{luaver}/*.la
|
||||||
|
%{_libdir}/lua/%{luaver}/*
|
||||||
|
|
||||||
|
%files -n python3-rrdtool
|
||||||
|
%doc bindings/python/COPYING bindings/python/README.md
|
||||||
|
%{python3_sitearch}/rrdtool*.so
|
||||||
|
%{python3_sitearch}/rrdtool-*.egg-info
|
||||||
|
|
||||||
|
%files help
|
||||||
|
%doc examples doc2/html doc2/txt
|
||||||
|
%{_mandir}/man1/*
|
||||||
|
%{_mandir}/man3/*
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Mon Dec 23 2019 wangzhishun <wangzhishun1@huawei.com> - 1.7.0-18
|
||||||
|
- Package init
|
||||||
|
|
||||||
Loading…
x
Reference in New Issue
Block a user