diff options
| -rw-r--r-- | php-sabre-uri-autoload.php | 4 | ||||
| -rw-r--r-- | php-sabre-uri.spec | 31 | 
2 files changed, 16 insertions, 19 deletions
diff --git a/php-sabre-uri-autoload.php b/php-sabre-uri-autoload.php index 8fc051f..b6268d1 100644 --- a/php-sabre-uri-autoload.php +++ b/php-sabre-uri-autoload.php @@ -6,5 +6,7 @@ require_once '/usr/share/php/Fedora/Autoloader/autoload.php';  \Fedora\Autoloader\Autoload::addPsr4('Sabre\\Uri\\', __DIR__);  // Functions -require_once __DIR__ . '/functions.php'; +if (!function_exists('Sabre\\Uri\\resolve')) { +	require_once __DIR__ . '/functions.php'; +} diff --git a/php-sabre-uri.spec b/php-sabre-uri.spec index eabf44f..d08e71a 100644 --- a/php-sabre-uri.spec +++ b/php-sabre-uri.spec @@ -1,6 +1,6 @@  # remirepo/fedora spec file for php-sabre-uri  # -# Copyright (c) 2016-2017 Remi Collet +# Copyright (c) 2016-2019 Remi Collet  # License: CC-BY-SA  # http://creativecommons.org/licenses/by-sa/4.0/  # @@ -15,7 +15,7 @@  Name:           php-sabre-%{gh_project}  Summary:        Functions for making sense out of URIs  Version:        1.2.1 -Release:        4%{?dist} +Release:        7%{?dist}  URL:            https://github.com/%{gh_owner}/%{gh_project}  License:        BSD @@ -84,23 +84,14 @@ cp -pr lib %{buildroot}%{_datadir}/php/Sabre/Uri  %if %{with_tests}  : Run upstream test suite against installed library  cd tests -# remirepo:11 -run=0  ret=0 -if which php56; then -   php56 %{_bindir}/phpunit --bootstrap=%{buildroot}%{_datadir}/php/Sabre/Uri/autoload.php || ret=1 -   run=1 -fi -if which php71; then -   php71 %{_bindir}/phpunit --bootstrap=%{buildroot}%{_datadir}/php/Sabre/Uri/autoload.php || ret=1 -   run=1 -fi -if [ $run -eq 0 ]; then -%{_bindir}/phpunit \ -  --bootstrap=%{buildroot}%{_datadir}/php/Sabre/Uri/autoload.php \ -  --verbose -# remirepo:2 -fi +for cmd in php php71 php72 php73 php74; do +  if which $cmd; then +    $cmd %{_bindir}/phpunit \ +      --bootstrap=%{buildroot}%{_datadir}/php/Sabre/Uri/autoload.php \ +      --verbose || ret=1 +  fi +done  exit $ret  %else  : Skip upstream test suite @@ -108,6 +99,7 @@ exit $ret  %files +# remirepo:1  %{!?_licensedir:%global license %%doc}  %license LICENSE  %doc *md @@ -117,6 +109,9 @@ exit $ret  %changelog +* Fri Jul  5 2019 Remi Collet <remi@remirepo.net> - 1.2.1-7 +- fix autoloader +  * Tue Jun  5 2018 Remi Collet <remi@remirepo.net> - 1.2.1-4  - fix project URL  | 
