summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--27.patch30
-rw-r--r--php-bartlett-PHP-Reflect.spec9
2 files changed, 38 insertions, 1 deletions
diff --git a/27.patch b/27.patch
new file mode 100644
index 0000000..12ebe25
--- /dev/null
+++ b/27.patch
@@ -0,0 +1,30 @@
+From a24e257e3f4975723e3176942ca9bcafb4222429 Mon Sep 17 00:00:00 2001
+From: Remi Collet <remi@remirepo.net>
+Date: Wed, 13 Dec 2017 15:37:15 +0100
+Subject: [PATCH] Fix #26 regression with previous cache configuration
+
+---
+ src/Bartlett/Reflect/Plugin/PluginManager.php | 10 ++++++----
+ 1 file changed, 6 insertions(+), 4 deletions(-)
+
+diff --git a/src/Bartlett/Reflect/Plugin/PluginManager.php b/src/Bartlett/Reflect/Plugin/PluginManager.php
+index 483b200..fdf19c5 100644
+--- a/src/Bartlett/Reflect/Plugin/PluginManager.php
++++ b/src/Bartlett/Reflect/Plugin/PluginManager.php
+@@ -68,10 +68,12 @@ public function registerPlugins()
+ if (class_exists($plugin['class'])) {
+ if (isset($plugin['options'])) {
+ $options = $plugin['options'];
+- if (is_string($options) && class_exists($options)) {
+- $options = new $options;
+- } else {
+- $options = null;
++ if (is_string($options)) {
++ if (class_exists($options)) {
++ $options = new $options;
++ } else {
++ $options = null;
++ }
+ }
+ } else {
+ $options = null;
diff --git a/php-bartlett-PHP-Reflect.spec b/php-bartlett-PHP-Reflect.spec
index f8bb698..e5bb589 100644
--- a/php-bartlett-PHP-Reflect.spec
+++ b/php-bartlett-PHP-Reflect.spec
@@ -27,7 +27,7 @@
Name: php-bartlett-PHP-Reflect
Version: 4.2.1
-%global specrel 1
+%global specrel 2
Release: %{?gh_date:1%{specrel}.%{?prever}%{!?prever:%{gh_date}git%{gh_short}}}%{!?gh_date:%{specrel}}%{?dist}
Summary: Adds the ability to reverse-engineer PHP
@@ -42,6 +42,8 @@ Source1: %{name}-autoload.php
# Enable cache plugin
Patch0: %{name}-4.0.0-rpm.patch
+Patch1: https://patch-diff.githubusercontent.com/raw/llaville/php-reflect/pull/27.patch
+
BuildArch: noarch
BuildRequires: php(language) >= 5.5
%if %{with_tests}
@@ -162,6 +164,7 @@ Documentation: http://php5.laurent-laville.org/reflect/manual/current/en/
%patch0 -p1 -b .rpm
cp %{SOURCE1} src/Bartlett/Reflect/autoload.php
+%patch1 -p1
sed -e 's/@package_version@/%{version}%{?prever}/' \
-i $(find src -name \*.php) bin/phpreflect
@@ -214,6 +217,10 @@ fi
%changelog
+* Tue Dec 12 2017 Remi Collet <remi@remirepo.net> - 4.2.1-2
+- fix regression with cache configuration
+ from https://github.com/llaville/php-reflect/pull/27
+
* Tue Dec 12 2017 Remi Collet <remi@remirepo.net> - 4.2.1-1
- Update to 4.2.1 (no change)
- raise dependency on PHP 5.5