summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--composer-dev.json66
-rw-r--r--composer.json23
-rw-r--r--php-sabre-dav-autoload.patch31
-rw-r--r--php-sabre-dav-autoload.php7
-rw-r--r--php-sabre-dav-php71.patch23
-rw-r--r--php-sabre-dav.spec68
6 files changed, 104 insertions, 114 deletions
diff --git a/composer-dev.json b/composer-dev.json
deleted file mode 100644
index 9994605..0000000
--- a/composer-dev.json
+++ /dev/null
@@ -1,66 +0,0 @@
-{
- "name": "sabre/dav",
- "type": "library",
- "description": "WebDAV Framework for PHP",
- "keywords": ["Framework", "WebDAV", "CalDAV", "CardDAV", "iCalendar"],
- "homepage": "http://sabre.io/",
- "license" : "BSD-3-Clause",
- "authors": [
- {
- "name": "Evert Pot",
- "email": "me@evertpot.com",
- "homepage" : "http://evertpot.com/",
- "role" : "Developer"
- }
- ],
- "require": {
- "php": ">=5.4.1",
- "sabre/vobject": "^3.3.4",
- "sabre/event" : "~2.0",
- "sabre/xml" : "~1.0",
- "sabre/http" : "~4.0",
- "sabre/uri" : "~1.0",
- "ext-dom": "*",
- "ext-pcre": "*",
- "ext-spl": "*",
- "ext-simplexml": "*",
- "ext-mbstring" : "*",
- "ext-ctype" : "*",
- "ext-date" : "*",
- "ext-iconv" : "*",
- "lib-libxml" : ">=2.7.0"
- },
- "require-dev" : {
- "phpunit/phpunit" : "~4.2",
- "evert/phpdoc-md" : "~0.1.0",
- "sabre/cs" : "~0.0.2"
- },
- "suggest" : {
- "ext-curl" : "*",
- "ext-pdo" : "*"
- },
- "autoload": {
- "psr-4" : {
- "Sabre\\DAV\\" : "lib/DAV/",
- "Sabre\\DAVACL\\" : "lib/DAVACL/",
- "Sabre\\CalDAV\\" : "lib/CalDAV/",
- "Sabre\\CardDAV\\" : "lib/CardDAV/"
- }
- },
- "support" : {
- "forum" : "https://groups.google.com/group/sabredav-discuss",
- "source" : "https://github.com/fruux/sabre-dav"
- },
- "bin" : [
- "bin/sabredav",
- "bin/naturalselection"
- ],
- "config" : {
- "bin-dir" : "./bin"
- },
- "extra" : {
- "branch-alias": {
- "dev-master": "3.0.0-dev"
- }
- }
-}
diff --git a/composer.json b/composer.json
index 71166ca..f85d965 100644
--- a/composer.json
+++ b/composer.json
@@ -14,10 +14,12 @@
}
],
"require": {
- "php": ">=5.4.1",
- "sabre/vobject": "^3.3.4",
- "sabre/event" : "^2.0.0",
- "sabre/http" : "^3.0.0",
+ "php": ">=5.5.0",
+ "sabre/vobject": "^4.1.0",
+ "sabre/event" : ">=2.0.0, <4.0.0",
+ "sabre/xml" : "^1.4.0",
+ "sabre/http" : "^4.2.1",
+ "sabre/uri" : "^1.0.1",
"ext-dom": "*",
"ext-pcre": "*",
"ext-spl": "*",
@@ -26,12 +28,14 @@
"ext-ctype" : "*",
"ext-date" : "*",
"ext-iconv" : "*",
- "ext-libxml" : "*"
+ "lib-libxml" : ">=2.7.0",
+ "psr/log": "^1.0"
},
"require-dev" : {
- "phpunit/phpunit" : "~4.2",
+ "phpunit/phpunit" : "> 4.8, <=6.0.0",
"evert/phpdoc-md" : "~0.1.0",
- "squizlabs/php_codesniffer": "~1.5.3"
+ "sabre/cs" : "~0.0.5",
+ "monolog/monolog": "^1.18"
},
"suggest" : {
"ext-curl" : "*",
@@ -55,5 +59,10 @@
],
"config" : {
"bin-dir" : "./bin"
+ },
+ "extra" : {
+ "branch-alias": {
+ "dev-master": "3.1.0-dev"
+ }
}
}
diff --git a/php-sabre-dav-autoload.patch b/php-sabre-dav-autoload.patch
index a1af77d..4e7c252 100644
--- a/php-sabre-dav-autoload.patch
+++ b/php-sabre-dav-autoload.patch
@@ -1,32 +1,33 @@
-diff -up tests/bootstrap.php.orig tests/bootstrap.php
---- tests/bootstrap.php.orig 2016-03-11 17:23:07.419944832 +0100
-+++ tests/bootstrap.php 2016-03-11 17:25:57.205599320 +0100
-@@ -1,21 +1,20 @@
+diff -up ./tests/bootstrap.php.rpm ./tests/bootstrap.php
+--- ./tests/bootstrap.php.rpm 2017-01-17 14:58:57.986380935 +0100
++++ ./tests/bootstrap.php 2017-01-17 15:00:56.261957259 +0100
+@@ -1,22 +1,21 @@
<?php
-set_include_path(__DIR__ . '/../lib/' . PATH_SEPARATOR . __DIR__ . PATH_SEPARATOR . get_include_path());
-
-$autoLoader = include __DIR__ . '/../vendor/autoload.php';
+require '@BUILDROOT@/usr/share/php/Sabre/DAV/autoload.php';
++require '/usr/share/php/Monolog/autoload.php';
// SabreDAV tests auto loading
-$autoLoader->add('Sabre\\', __DIR__);
+\Fedora\Autoloader\Autoload::addPsr0('Sabre\\', __DIR__);
-+
// VObject tests auto loading
--$autoLoader->addPsr4('Sabre\\VObject\\',__DIR__ . '/../vendor/sabre/vobject/tests/VObject');
--$autoLoader->addPsr4('Sabre\\Xml\\',__DIR__ . '/../vendor/sabre/xml/tests/Sabre/Xml');
-+//$autoLoader->addPsr4('Sabre\\VObject\\',__DIR__ . '/../vendor/sabre/vobject/tests/VObject');
-+//$autoLoader->addPsr4('Sabre\\Xml\\',__DIR__ . '/../vendor/sabre/xml/tests/Sabre/Xml');
+-$autoLoader->addPsr4('Sabre\\VObject\\', __DIR__ . '/../vendor/sabre/vobject/tests/VObject');
+-$autoLoader->addPsr4('Sabre\\Xml\\', __DIR__ . '/../vendor/sabre/xml/tests/Sabre/Xml');
++//$autoLoader->addPsr4('Sabre\\VObject\\', __DIR__ . '/../vendor/sabre/vobject/tests/VObject');
++//$autoLoader->addPsr4('Sabre\\Xml\\', __DIR__ . '/../vendor/sabre/xml/tests/Sabre/Xml');
date_default_timezone_set('UTC');
$config = [
'SABRE_TEMPDIR' => dirname(__FILE__) . '/temp/',
-- 'SABRE_HASSQLITE' => in_array('sqlite',PDO::getAvailableDrivers()),
-- 'SABRE_HASMYSQL' => in_array('mysql',PDO::getAvailableDrivers()),
-+ 'SABRE_HASSQLITE' => 1,
-+ 'SABRE_HASMYSQL' => 0,
- 'SABRE_MYSQLDSN' => 'mysql:host=127.0.0.1;dbname=sabredav',
- 'SABRE_MYSQLUSER' => 'root',
+ 'SABRE_HASSQLITE' => in_array('sqlite', PDO::getAvailableDrivers()),
+- 'SABRE_HASMYSQL' => in_array('mysql', PDO::getAvailableDrivers()),
+- 'SABRE_HASPGSQL' => in_array('pgsql', PDO::getAvailableDrivers()),
++ 'SABRE_HASMYSQL' => false,
++ 'SABRE_HASPGSQL' => false,
+ 'SABRE_MYSQLDSN' => 'mysql:host=127.0.0.1;dbname=sabredav_test',
+ 'SABRE_MYSQLUSER' => 'sabredav',
'SABRE_MYSQLPASS' => '',
diff --git a/php-sabre-dav-autoload.php b/php-sabre-dav-autoload.php
index 160dfab..edbbc4d 100644
--- a/php-sabre-dav-autoload.php
+++ b/php-sabre-dav-autoload.php
@@ -8,11 +8,12 @@ require_once '/usr/share/php/Fedora/Autoloader/autoload.php';
\Fedora\Autoloader\Autoload::addPsr4('Sabre\\CalDAV\\', dirname(__DIR__) . '/CalDAV');
\Fedora\Autoloader\Autoload::addPsr4('Sabre\\CardDAV\\', dirname(__DIR__) . '/CardDAV');
-\Fedora\Autoloader\Dependencies::required(array(
+\Fedora\Autoloader\Dependencies::required([
'/usr/share/php/Sabre/Event/autoload.php',
'/usr/share/php/Sabre/HTTP/autoload.php',
- '/usr/share/php/Sabre/VObject/autoload.php',
+ '/usr/share/php/Sabre/VObject4/autoload.php',
'/usr/share/php/Sabre/Xml/autoload.php',
'/usr/share/php/Sabre/Uri/autoload.php',
-));
+ '/usr/share/php/Psr/Log/autoload.php',
+]);
diff --git a/php-sabre-dav-php71.patch b/php-sabre-dav-php71.patch
new file mode 100644
index 0000000..8bbe179
--- /dev/null
+++ b/php-sabre-dav-php71.patch
@@ -0,0 +1,23 @@
+From 072589cd5dbce0f3e3a28b29ee778a1183c6d45d Mon Sep 17 00:00:00 2001
+From: Evert Pot <me@evertpot.com>
+Date: Fri, 7 Oct 2016 17:23:14 -0400
+Subject: [PATCH] PHP 7.1 tweak
+
+---
+ tests/Sabre/DAV/ServerEventsTest.php | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/tests/Sabre/DAV/ServerEventsTest.php b/tests/Sabre/DAV/ServerEventsTest.php
+index 7f995c6..e41b827 100644
+--- a/tests/Sabre/DAV/ServerEventsTest.php
++++ b/tests/Sabre/DAV/ServerEventsTest.php
+@@ -118,7 +118,8 @@ class ServerEventsTest extends AbstractS
+ );
+ } catch (Exception $e) {}
+
+- $this->assertEquals(2, $k);
++ // Fun fact, PHP 7.1 changes the order when sorting-by-callback.
++ $this->assertTrue($k>=2 && $k <=3);
+
+
+ }
diff --git a/php-sabre-dav.spec b/php-sabre-dav.spec
index 8ef73a6..6ee0080 100644
--- a/php-sabre-dav.spec
+++ b/php-sabre-dav.spec
@@ -6,7 +6,7 @@
#
# Please, preserve the changelog entries
#
-%global gh_commit b42593965211de1ce99f73bd3aede99c41258e08
+%global gh_commit 5b9737cc2f0182e368d14c80df7f6b2d77dc1457
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner fruux
%global gh_project sabre-dav
@@ -18,8 +18,8 @@
Name: php-%{gh_project}
Summary: WebDAV Framework for PHP
-Version: 3.0.9
-Release: 3%{?dist}
+Version: 3.2.0
+Release: 1%{?dist}
URL: https://github.com/%{gh_owner}/%{gh_project}
License: BSD
@@ -35,13 +35,12 @@ Patch1: %{name}-php71.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
%if %{with_tests}
-BuildRequires: php(language) >= 5.4.1
-BuildRequires: php-composer(phpunit/phpunit)
-BuildRequires: php-composer(sabre/vobject) >= 3.3.4
+BuildRequires: php(language) >= 5.5
+BuildRequires: php-composer(sabre/vobject) >= 4.1.0
BuildRequires: php-composer(sabre/event) >= 2.0
-BuildRequires: php-composer(sabre/xml) >= 1.0
-BuildRequires: php-composer(sabre/http) >= 4.0
-BuildRequires: php-composer(sabre/uri) >= 1.0
+BuildRequires: php-composer(sabre/xml) >= 1.4.0
+BuildRequires: php-composer(sabre/http) >= 4.2.1
+BuildRequires: php-composer(sabre/uri) >= 1.0.1
BuildRequires: php-dom
BuildRequires: php-pcre
BuildRequires: php-spl
@@ -51,20 +50,30 @@ BuildRequires: php-ctype
BuildRequires: php-date
BuildRequires: php-iconv
BuildRequires: php-libxml
+BuildRequires: php-composer(psr/log) >= 1.0.1
BuildRequires: php-curl
BuildRequires: php-pdo
+# From composer.json, "require-dev" : {
+# "phpunit/phpunit" : "> 4.8, <=6.0.0",
+# "evert/phpdoc-md" : "~0.1.0",
+# "squizlabs/php_codesniffer": "~1.5.3"
+# "sabre/cs" : "~0.0.5",
+# "monolog/monolog": "^1.18"
+BuildRequires: php-composer(phpunit/phpunit) >= 4.8
+BuildRequires: php-composer(monolog/monolog) >= 1.18
+
# Autoloader
BuildRequires: php-composer(fedora/autoloader)
BuildRequires: php-pdo_sqlite
%endif
# From composer.json, "require": {
-# "php": ">=5.4.1",
-# "sabre/vobject": "^3.3.4",
-# "sabre/event" : "~2.0",
-# "sabre/xml" : "~1.0",
-# "sabre/http" : "~4.0",
-# "sabre/uri" : "~1.0",
+# "php": ">=5.5.0",
+# "sabre/vobject": "^4.1.0",
+# "sabre/event" : ">=2.0.0, <4.0.0",
+# "sabre/xml" : "^1.4.0",
+# "sabre/http" : "^4.2.1",
+# "sabre/uri" : "^1.0.1",
# "ext-dom": "*",
# "ext-pcre": "*",
# "ext-spl": "*",
@@ -73,17 +82,18 @@ BuildRequires: php-pdo_sqlite
# "ext-ctype" : "*",
# "ext-date" : "*",
# "ext-iconv" : "*",
-# "ext-libxml" : "*"
+# "lib-libxml" : ">=2.7.0",
+# "psr/log": "^1.0"
Requires: php(language) >= 5.4.1
-Requires: php-composer(sabre/vobject) >= 3.3.4
-Requires: php-composer(sabre/vobject) < 4
+Requires: php-composer(sabre/vobject) >= 4.1.0
+Requires: php-composer(sabre/vobject) < 5
Requires: php-composer(sabre/event) >= 2.0
Requires: php-composer(sabre/event) < 3
-Requires: php-composer(sabre/xml) >= 1.0
+Requires: php-composer(sabre/xml) >= 1.4.0
Requires: php-composer(sabre/xml) < 2
-Requires: php-composer(sabre/http) >= 4.0
+Requires: php-composer(sabre/http) >= 4.2.1
Requires: php-composer(sabre/http) < 5
-Requires: php-composer(sabre/uri) >= 1.0
+Requires: php-composer(sabre/uri) >= 1.0.1
Requires: php-composer(sabre/uri) < 2
Requires: php-dom
Requires: php-pcre
@@ -94,6 +104,8 @@ Requires: php-ctype
Requires: php-date
Requires: php-iconv
Requires: php-libxml
+Requires: php-composer(psr/log) >= 1.0.1
+Requires: php-composer(psr/log) < 2
# From composer.json, "suggest" : {
# "ext-curl" : "*",
# "ext-pdo" : "*"
@@ -130,8 +142,9 @@ Autoloader: %{_datadir}/php/Sabre/DAV/autoload.php
%prep
%setup -q -n %{gh_project}-%{gh_commit}
-%patch0 -p0
-%patch1 -p1
+%patch0 -p1 -b .rpm
+%patch1 -p1 -b .php71
+
cp %{SOURCE1} lib/DAV/autoload.php
# drop executable as only provided as doc
@@ -195,6 +208,15 @@ exit $ret
%changelog
+* Tue Jan 17 2017 Remi Collet <remi@fedoraproject.org> - 3.2.0-1
+- update to 3.2.0
+- raise dependency on PHP version 5.5
+- raise dependency on sabre/vobject version 4.1
+- raise dependency on sabre/xml version 1.4
+- raise dependency on sabre/http version 4.2.1
+- raise dependency on sabre/uri version 1.0.1
+- add dependency on psr/log
+
* Wed Nov 23 2016 Remi Collet <remi@fedoraproject.org> - 3.0.9-3
- add upstream patch to fix FTBFS with php 7.1