From be0c3984eb64975b0448533100fb27281cc2ad2f Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 22 Jun 2016 18:15:49 +0200 Subject: glpi: add upstream patch, drop dependency on zend-version --- glpi-0.90-autoload.patch | 2 +- glpi-0.90-cron.patch | 4 ++-- glpi-0.90-upstream.patch | 36 ++++++++++++++++++++++++++++++++++++ glpi.spec | 9 +++++++-- 4 files changed, 46 insertions(+), 5 deletions(-) create mode 100644 glpi-0.90-upstream.patch diff --git a/glpi-0.90-autoload.patch b/glpi-0.90-autoload.patch index 6af92b7..898b286 100644 --- a/glpi-0.90-autoload.patch +++ b/glpi-0.90-autoload.patch @@ -1,7 +1,7 @@ diff -up inc/autoload.function.php.old inc/autoload.function.php --- inc/autoload.function.php.old 2016-02-18 14:45:41.167015090 +0100 +++ inc/autoload.function.php 2016-02-18 14:47:19.277404208 +0100 -@@ -328,10 +328,14 @@ function glpi_autoload($classname) { +@@ -332,10 +332,14 @@ function glpi_autoload($classname) { // Use spl autoload to allow stackable autoload. spl_autoload_register('glpi_autoload'); diff --git a/glpi-0.90-cron.patch b/glpi-0.90-cron.patch index 7a9eba7..8cde99c 100644 --- a/glpi-0.90-cron.patch +++ b/glpi-0.90-cron.patch @@ -1,7 +1,7 @@ diff -up install/install.php.rpm install/install.php --- install/install.php.rpm 2014-12-17 13:36:22.420558338 +0100 +++ install/install.php 2014-12-17 13:38:45.278209044 +0100 -@@ -382,6 +382,10 @@ function step4 ($databasename, $newdatab +@@ -383,6 +383,10 @@ function step4 ($databasename, $newdatab $query = "UPDATE `glpi_users` SET `language` = NULL"; $DB->queryOrDie($query, "4203"); @@ -15,7 +15,7 @@ diff -up install/install.php.rpm install/install.php diff -up install/update.php.rpm install/update.php --- install/update.php.rpm 2014-12-11 14:16:55.000000000 +0100 +++ install/update.php 2014-12-17 13:36:22.420558338 +0100 -@@ -818,6 +818,10 @@ function updateDbUpTo031() { +@@ -830,6 +830,10 @@ function updateDbUpTo031() { $plugin = new Plugin(); $plugin->unactivateAll(); diff --git a/glpi-0.90-upstream.patch b/glpi-0.90-upstream.patch new file mode 100644 index 0000000..213f8e2 --- /dev/null +++ b/glpi-0.90-upstream.patch @@ -0,0 +1,36 @@ +Adapted for 0.90 from: + + +From efdec2554b4b65e72de049ea9897ddab5a2b7971 Mon Sep 17 00:00:00 2001 +From: Remi Collet +Date: Tue, 19 Apr 2016 11:30:16 +0200 +Subject: [PATCH] Drop Zend\Version usage + +This component is no more relevant as it reports its +own version, not the one of the framework. +--- + inc/config.class.php | 3 +- + lib/Zend/Version/README.md | 15 --- + lib/Zend/Version/Version.php | 226 ----------------------------------------- + lib/Zend/Version/composer.json | 32 ------ + tools/composer.json | 1 - + 5 files changed, 1 insertion(+), 276 deletions(-) + delete mode 100644 lib/Zend/Version/README.md + delete mode 100644 lib/Zend/Version/Version.php + delete mode 100644 lib/Zend/Version/composer.json + +diff --git a/inc/config.class.php b/inc/config.class.php +index 477ded2..f1008db 100644 +--- a/inc/config.class.php ++++ b/inc/config.class.php +@@ -1553,8 +1553,7 @@ static function showLibrariesInformation() { + "): ".(class_exists('ezcGraph') ? 'OK' : 'KO'). "\n"; + + // Zend +- $zv = new Zend\Version\Version; +- echo "Zend Framework version " . $zv::VERSION . " in (" . realpath(GLPI_ZEND_PATH) . ")\n"; ++ echo "Zend Framework in (" . realpath(GLPI_ZEND_PATH) . ")\n"; + + // SimplePie : + $sp = new SimplePie(); + diff --git a/glpi.spec b/glpi.spec index 24b0f30..e454691 100644 --- a/glpi.spec +++ b/glpi.spec @@ -28,7 +28,7 @@ Name: glpi Version: 0.90.3 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Free IT asset management software Summary(fr): Gestion Libre de Parc Informatique @@ -47,6 +47,8 @@ Source4: glpi-nginx.conf Patch0: glpi-0.90-cron.patch # Fix autoloader Patch1: glpi-0.90-autoload.patch +# Upstream patch +Patch2: glpi-0.90-upstream.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch @@ -84,7 +86,6 @@ Requires: php-simplepie Requires: php-composer(zendframework/zend-cache) Requires: php-composer(zendframework/zend-i18n) Requires: php-composer(zendframework/zend-loader) -Requires: php-composer(zendframework/zend-version) Requires: php-composer(ircmaxell/password-compat) %if 0%{?fedora} >= 11 || 0%{?rhel} >= 6 Requires: php-composer(zetacomponents/graph) @@ -130,6 +131,7 @@ techniciens grâce à une maintenance plus cohérente. %patch0 -p0 %patch1 -p0 +%patch2 -p1 find . -name \*.orig -exec rm {} \; -print @@ -327,6 +329,9 @@ fi %changelog +* Wed Jun 22 2016 Remi Collet - 0.90.3-2 +- add upstream patch, drop dependency on zend-version + * Tue Apr 12 2016 Remi Collet - 0.90.3-1 - update to 0.90.3 https://github.com/glpi-project/glpi/issues?q=milestone:0.90.3 -- cgit