From 90e49c714ca8d0f815a0f3e6ef058e4cc0e8cfd5 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Elan=20Ruusam=C3=A4e?= Date: Wed, 14 Apr 2010 15:13:18 +0000 Subject: [PATCH] - make sure cli programs work from any current dir; rel 8 Changed files: cacti.spec -> 1.118 cli-relpath.patch -> 1.1 --- cacti.spec | 4 +++- cli-relpath.patch | 13 +++++++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 cli-relpath.patch diff --git a/cacti.spec b/cacti.spec index 200b367..b93d94f 100644 --- a/cacti.spec +++ b/cacti.spec @@ -3,7 +3,7 @@ Summary: Cacti is a PHP frontend for rrdtool Summary(pl.UTF-8): Cacti - frontend w PHP do rrdtoola Name: cacti Version: 0.8.7e -Release: 7 +Release: 8 License: GPL Group: Applications/WWW Source0: http://www.cacti.net/downloads/%{name}-%{version}.tar.gz @@ -31,6 +31,7 @@ Patch6: %{name}-log-verbosity.patch Patch7: %{name}-ss_disk-array-indices.patch Patch8: %{name}-rrdresourcecheck.patch Patch9: host_name-url.patch +Patch10: cli-relpath.patch URL: http://www.cacti.net/ BuildRequires: rpm-perlprov BuildRequires: sed >= 4.0 @@ -131,6 +132,7 @@ Dokumentacja do Cacti w formacie HTML. %patch7 -p1 %patch8 -p1 %patch9 -p1 +%patch10 -p1 mkdir -p sql mv *.sql sql diff --git a/cli-relpath.patch b/cli-relpath.patch new file mode 100644 index 0000000..f58fdb5 --- /dev/null +++ b/cli-relpath.patch @@ -0,0 +1,13 @@ +--- cacti-0.8.7e/cli/import_template.php 2010-04-14 18:11:37.575631837 +0300 ++++ cacti-0.8.7e/cli/import_template.php 2010-04-14 18:07:35.956754241 +0300 +@@ -31,8 +31,8 @@ + /* We are not talking to the browser */ + $no_http_headers = true; + +-include(dirname(__FILE__)."/../include/global.php"); +-include_once("../lib/import.php"); ++require(dirname(__FILE__)."/../include/global.php"); ++require_once(dirname(__FILE__)."/../lib/import.php"); + + /* process calling arguments */ + $parms = $_SERVER["argv"]; -- 2.44.0