summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--composer.json43
-rw-r--r--php-kdyby-events-autoload.php1
-rw-r--r--php-kdyby-events-tester2.patch10
-rw-r--r--php-kdyby-events.spec101
4 files changed, 64 insertions, 91 deletions
diff --git a/composer.json b/composer.json
index 6ed83ee..440bd22 100644
--- a/composer.json
+++ b/composer.json
@@ -17,42 +17,27 @@
"issues": "https://github.com/kdyby/events/issues"
},
"require": {
- "nette/di": "~2.3@dev",
- "nette/utils": "~2.3@dev"
+ "nette/di": "^2.4@dev",
+ "nette/utils": "^2.4@dev",
+ "nette/reflection": "^2.4@dev"
},
"require-dev": {
- "nette/application": "~2.3@dev",
- "nette/bootstrap": "~2.3@dev",
- "nette/caching": "~2.3@dev",
- "nette/component-model": "~2.2@dev",
- "nette/database": "~2.3@dev",
- "nette/deprecated": "~2.3@dev",
- "nette/di": "~2.3@dev",
- "nette/finder": "~2.3@dev",
- "nette/forms": "~2.3@dev",
- "nette/http": "~2.3@dev",
- "nette/mail": "~2.3@dev",
- "nette/neon": "~2.3@dev",
- "nette/php-generator": "~2.3@dev",
- "nette/reflection": "~2.3@dev",
- "nette/robot-loader": "~2.3@dev",
- "nette/safe-stream": "~2.3@dev",
- "nette/security": "~2.3@dev",
- "nette/tokenizer": "~2.2@dev",
- "latte/latte": "~2.3@dev",
- "tracy/tracy": "~2.3@dev",
- "nette/utils": "~2.3@dev",
+ "nette/application": "^2.4@dev",
+ "nette/bootstrap": "^2.4@dev",
+ "nette/security": "^2.4@dev",
+ "nette/http": "^2.4@dev",
+ "tracy/tracy": "^2.4@dev",
- "symfony/event-dispatcher": "~2.3|~3.0",
+ "symfony/event-dispatcher": "^3.0",
- "nette/tester": "~1.4"
+ "nette/tester": "~1.7"
},
"autoload": {
- "psr-0": {
- "Kdyby\\Events\\": "src/"
+ "psr-4": {
+ "Kdyby\\Events\\": "src/Events"
},
"classmap": [
- "src/Kdyby/Events/exceptions.php"
+ "src/Events/exceptions.php"
],
"files": [
"src/Doctrine/compatibility.php"
@@ -60,7 +45,7 @@
},
"extra": {
"branch-alias": {
- "dev-master": "3.0-dev"
+ "dev-master": "3.1-dev"
}
}
}
diff --git a/php-kdyby-events-autoload.php b/php-kdyby-events-autoload.php
index a83a6de..e9738fc 100644
--- a/php-kdyby-events-autoload.php
+++ b/php-kdyby-events-autoload.php
@@ -8,4 +8,5 @@ require_once '/usr/share/php/Fedora/Autoloader/autoload.php';
'/usr/share/php/Doctrine/Common/autoload.php',
'/usr/share/php/Nette/DI/autoload.php',
'/usr/share/php/Nette/Utils/autoload.php',
+ '/usr/share/php/Nette/Reflection/autoload.php',
));
diff --git a/php-kdyby-events-tester2.patch b/php-kdyby-events-tester2.patch
deleted file mode 100644
index 8c2a31c..0000000
--- a/php-kdyby-events-tester2.patch
+++ /dev/null
@@ -1,10 +0,0 @@
-diff -up tests/KdybyTests/bootstrap.php.old tests/KdybyTests/bootstrap.php
---- tests/KdybyTests/bootstrap.php.old 2016-08-04 16:10:59.039641276 +0200
-+++ tests/KdybyTests/bootstrap.php 2016-08-04 16:11:04.206667988 +0200
-@@ -33,5 +33,5 @@ function id($val) {
- }
-
- function run(Tester\TestCase $testCase) {
-- $testCase->run(isset($_SERVER['argv'][1]) ? $_SERVER['argv'][1] : NULL);
-+ $testCase->run();
- }
diff --git a/php-kdyby-events.spec b/php-kdyby-events.spec
index c9836a3..d22e69b 100644
--- a/php-kdyby-events.spec
+++ b/php-kdyby-events.spec
@@ -6,7 +6,7 @@
#
# Please, preserve the changelog entries
#
-%global gh_commit 05de56c633167ed218939cfc8cdff984d78c0d9c
+%global gh_commit f63b92eaf75df33d0a449af80de8e9f1d85dd6f6
#global gh_date 20150728
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner kdyby
@@ -17,9 +17,9 @@
%global with_tests 0%{!?_without_tests:1}
Name: php-%{gh_owner}-%{gh_project}
-Version: 3.0.2
-%global specrel 2
-Release: %{?gh_date:0.%{specrel}.%{?prever}%{!?prever:%{gh_date}git%{gh_short}}}%{!?gh_date:%{specrel}}%{?dist}
+Version: 3.1.0
+%global specrel 1
+Release: %{?gh_date:1%{specrel}.%{?prever}%{!?prever:%{gh_date}git%{gh_short}}}%{!?gh_date:%{specrel}}%{?dist}
Summary: Events for Nette Framework
Group: Development/Libraries
@@ -31,10 +31,6 @@ Source1: makesrc.sh
# Autoloader
Source2: %{name}-autoload.php
-# see https://github.com/Kdyby/Events/pull/103
-# fix for nette/tester > 2
-Patch0: %{name}-tester2.patch
-
BuildArch: noarch
%if %{with_tests}
BuildRequires: php-pcre
@@ -43,50 +39,44 @@ BuildRequires: php-composer(nette/di) < 3
BuildRequires: php-composer(nette/di) >= 2.3
BuildRequires: php-composer(nette/utils) < 3
BuildRequires: php-composer(nette/utils) >= 2.3
+BuildRequires: php-composer(nette/reflection) < 3
+BuildRequires: php-composer(nette/reflection) >= 2.3
BuildRequires: php-composer(doctrine/common) < 3
BuildRequires: php-composer(doctrine/common) >= 2.5.0
BuildRequires: php-composer(fedora/autoloader)
# From composer.json, "require-dev": {
-# "nette/application": "~2.3@dev",
-# "nette/bootstrap": "~2.3@dev",
-# "nette/caching": "~2.3@dev",
-# "nette/component-model": "~2.2@dev",
-# "nette/database": "~2.3@dev",
-# "nette/deprecated": "~2.3@dev",
-# "nette/di": "~2.3@dev",
-# "nette/finder": "~2.3@dev",
-# "nette/forms": "~2.3@dev",
-# "nette/http": "~2.3@dev",
-# "nette/mail": "~2.3@dev",
-# "nette/neon": "~2.3@dev",
-# "nette/php-generator": "~2.3@dev",
-# "nette/reflection": "~2.3@dev",
-# "nette/robot-loader": "~2.3@dev",
-# "nette/safe-stream": "~2.3@dev",
-# "nette/security": "~2.3@dev",
-# "nette/tokenizer": "~2.2@dev",
-# "latte/latte": "~2.3@dev",
-# "tracy/tracy": "~2.3@dev",
-# "nette/utils": "~2.3@dev",
-# "symfony/event-dispatcher": "~2.3|~3.0",
-# "nette/tester": "~1.4@",
-# The framework is enough as it requires everything
-BuildRequires: php-composer(nette/nette) < 3
-BuildRequires: php-composer(nette/nette) >= 2.3
-BuildRequires: php-composer(nette/tester) >= 1.4
+# "nette/application": "^2.4@dev",
+# "nette/bootstrap": "^2.4@dev",
+# "nette/security": "^2.4@dev",
+# "nette/http": "^2.4@dev",
+# "tracy/tracy": "^2.4@dev",
+# "symfony/event-dispatcher": "^3.0",
+# "nette/tester": "~1.7"
+BuildRequires: php-composer(nette/application) < 3
+BuildRequires: php-composer(nette/application) >= 2.4
+BuildRequires: php-composer(nette/bootstrap) < 3
+BuildRequires: php-composer(nette/bootstrap) >= 2.4
+BuildRequires: php-composer(nette/security) < 3
+BuildRequires: php-composer(nette/security) >= 2.4
+BuildRequires: php-composer(nette/http) < 3
+BuildRequires: php-composer(nette/http) >= 2.4
+BuildRequires: php-composer(tracy/tracy) < 3
+BuildRequires: php-composer(tracy/tracy) >= 2.4
+BuildRequires: php-composer(nette/tester) >= 1.7
BuildRequires: php-composer(symfony/event-dispatcher) < 4
-BuildRequires: php-composer(symfony/event-dispatcher) >= 2.3
+BuildRequires: php-composer(symfony/event-dispatcher) >= 3.0
%endif
-# Temporary workaround for doctrine
-BuildRequires: php-symfony-class-loader
# from composer.json, "require": {
-# "nette/di": "~2.3@dev",
-# "nette/utils": "~2.3@dev"
-Requires: php-composer(nette/di) >= 2.3
+# "nette/di": "~2.4@dev",
+# "nette/utils": "~2.4@dev"
+# "nette/reflection": "^2.4@dev"
+Requires: php-composer(nette/di) >= 2.4
Requires: php-composer(nette/di) < 3
-Requires: php-composer(nette/utils) >= 2.3
+Requires: php-composer(nette/utils) >= 2.4
Requires: php-composer(nette/utils) < 3
+Requires: php-composer(nette/reflection) >= 2.4
+Requires: php-composer(nette/reflection) < 3
# To avoid having to provide the compatibility layer
# version 2.5.0 for autoloader
Requires: php-composer(doctrine/common) >= 2.5.0
@@ -110,8 +100,7 @@ To use this library, you just have to add, in your project:
%prep
%setup -q -n %{gh_project}-%{gh_commit}
-cp %{SOURCE2} src/%{ns_vendor}/%{ns_project}/autoload.php
-%patch0 -p0 -b .tester2
+cp %{SOURCE2} src/%{ns_project}/autoload.php
%build
@@ -119,8 +108,8 @@ cp %{SOURCE2} src/%{ns_vendor}/%{ns_project}/autoload.php
%install
-mkdir -p %{buildroot}%{php_home}
-cp -pr src/%{ns_vendor} %{buildroot}%{php_home}/%{ns_vendor}
+mkdir -p %{buildroot}%{php_home}/%{ns_vendor}
+cp -pr src/%{ns_project} %{buildroot}%{php_home}/%{ns_vendor}/%{ns_project}
%check
@@ -134,11 +123,12 @@ cat << 'EOF' | tee vendor/autoload.php
require_once '%{buildroot}%{php_home}/%{ns_vendor}/%{ns_project}/autoload.php';
\Fedora\Autoloader\Dependencies::required(array(
'%{php_home}/Tester/autoload.php',
- '%{php_home}/Nette/autoload.php',
- array(
- '%{php_home}/Symfony3/Component/EventDispatcher/autoload.php',
- '%{php_home}/Symfony/Component/EventDispatcher/autoload.php',
- ),
+ '%{php_home}/Nette/Application/autoload.php',
+ '%{php_home}/Nette/Bootstrap/autoload.php',
+ '%{php_home}/Nette/Security/autoload.php',
+ '%{php_home}/Nette/Http/autoload.php',
+ '%{php_home}/Tracy/autoload.php',
+ '%{php_home}/Symfony3/Component/EventDispatcher/autoload.php',
));
EOF
@@ -147,7 +137,7 @@ php -r 'require "vendor/autoload.php";'
: Run test suite in sources tree
ret=0
-# PHP 7.2, 2 failures
+# PHP 7.2: https://github.com/Kdyby/Events/issues/108
for cmd in php php56 php70 php71; do
if which $cmd; then
$cmd %{_bindir}/nette-tester --colors 0 -p $cmd -C tests/KdybyTests -s || ret=1
@@ -168,6 +158,13 @@ exit $ret
%changelog
+* Mon May 15 2017 Remi Collet <remi@remirepo.net> - 3.1.0-1
+- Update to 3.1.0
+- add dependency on nette/reflection
+- reduce build dependency to only needed components
+- raise build dependency on Symfony 3
+- raise dependency on nette 2.4
+
* Tue May 9 2017 Remi Collet <remi@fedoraproject.org> - 3.0.2-2
- switch to fedora/autoloader