diff options
Diffstat (limited to 'php-symfony-polyfill.spec')
-rw-r--r-- | php-symfony-polyfill.spec | 51 |
1 files changed, 23 insertions, 28 deletions
diff --git a/php-symfony-polyfill.spec b/php-symfony-polyfill.spec index 8f8e9a6..9a034c8 100644 --- a/php-symfony-polyfill.spec +++ b/php-symfony-polyfill.spec @@ -2,7 +2,7 @@ # # Fedora spec file for php-symfony-polyfill # -# Copyright (c) 2015-2016 Shawn Iwinski <shawn@iwin.ski> +# Copyright (c) 2015-2017 Shawn Iwinski <shawn@iwin.ski> # # License: MIT # http://opensource.org/licenses/MIT @@ -12,8 +12,8 @@ %global github_owner symfony %global github_name polyfill -%global github_version 1.3.0 -%global github_commit 385d033a8e1d8778446d699ecbd886480716eba7 +%global github_version 1.4.0 +%global github_commit a80c6de45ebd2a041415ba17879ff7309ead51f6 %global composer_vendor symfony %global composer_project polyfill @@ -39,7 +39,6 @@ License: MIT URL: https://github.com/%{github_owner}/%{github_name} Source0: %{url}/archive/%{github_commit}/%{name}-%{github_version}-%{github_commit}.tar.gz -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch # Autoloader BuildRequires: php-fedora-autoloader-devel @@ -83,6 +82,7 @@ Provides: php-composer(%{composer_vendor}/%{composer_project}-php55) = %{ve Provides: php-composer(%{composer_vendor}/%{composer_project}-php56) = %{version} Provides: php-composer(%{composer_vendor}/%{composer_project}-php70) = %{version} Provides: php-composer(%{composer_vendor}/%{composer_project}-php71) = %{version} +Provides: php-composer(%{composer_vendor}/%{composer_project}-php72) = %{version} %description %{summary}. @@ -94,13 +94,14 @@ Autoloader: %{phpdir}/Symfony/Polyfill/autoload.php %setup -qn %{github_name}-%{github_commit} : Docs -mkdir -p docs/{Php54,Php55,Php56,Php70,Php71,Util} +mkdir -p docs/{Php54,Php55,Php56,Php70,Php71,Php72,Util} mv *.md composer.json docs/ mv src/Php54/{*.md,composer.json} docs/Php54/ mv src/Php55/{*.md,composer.json} docs/Php55/ mv src/Php56/{*.md,composer.json} docs/Php56/ mv src/Php70/{*.md,composer.json} docs/Php70/ mv src/Php71/{*.md,composer.json} docs/Php71/ +mv src/Php72/{*.md,composer.json} docs/Php72/ mv src/Util/{*.md,composer.json} docs/Util/ : Remove unneeded polyfills @@ -121,6 +122,7 @@ cat <<'AUTOLOAD' | tee -a src/autoload.php __DIR__ . '/Php56/bootstrap.php', __DIR__ . '/Php70/bootstrap.php', __DIR__ . '/Php71/bootstrap.php', + __DIR__ . '/Php72/bootstrap.php', '%{phpdir}/password_compat/password.php', '%{phpdir}/random_compat/autoload.php', )); @@ -128,7 +130,6 @@ AUTOLOAD %install -rm -rf %{buildroot} : Library mkdir -p %{buildroot}%{phpdir}/Symfony/Polyfill @@ -137,34 +138,23 @@ cp -rp src/* %{buildroot}%{phpdir}/Symfony/Polyfill/ %check %if %{with_tests} -# remirepo:11 -run=0 -ret=0 -if which php56; then - php56 %{_bindir}/phpunit --bootstrap %{buildroot}%{phpdir}/Symfony/Polyfill/autoload.php - run=1 -fi -if which php71; then - php71 %{_bindir}/phpunit --bootstrap %{buildroot}%{phpdir}/Symfony/Polyfill/autoload.php - run=1 -fi -if [ $run -eq 0 ]; then -%{_bindir}/phpunit --verbose \ - --bootstrap %{buildroot}%{phpdir}/Symfony/Polyfill/autoload.php -# remirepo:2 -fi -exit $ret +: Upstream tests +RETURN_CODE=0 +PHPUNIT=$(which phpunit) +for PHP_EXEC in "" %{?rhel:php54 php55} php56 php70 php71 php72; do + if [ -z "$PHP_EXEC" ] || which $PHP_EXEC; then + $PHP_EXEC $PHPUNIT --verbose \ + --bootstrap %{buildroot}%{phpdir}/Symfony/Polyfill/autoload.php \ + || RETURN_CODE=1 + fi +done +exit $RETURN_CODE %else : Tests skipped %endif -%clean -rm -rf %{buildroot} - - %files -%defattr(-,root,root,-) %{!?_licensedir:%global license %%doc} %license LICENSE %doc docs/* @@ -174,6 +164,11 @@ rm -rf %{buildroot} %changelog +* Sun Jul 09 2017 Shawn Iwinski <shawn.iwinski@gmail.com> - 1.4.0-1 +- Updated to 1.4.0 (RHBZ #1460473) +- Provide php-composer(symfony/polyfill-php72) +- Test with SCLs if available + * Mon Nov 14 2016 Remi Collet <remi@fedoraproject.org> - 1.3.0-1 - Updated to 1.3.0 - provide php-composer(symfony/polyfill-php71) |