(cherry picked from commit 3ac55d0d06)
This commit is contained in:
Remi Collet 2022-09-08 12:25:20 +02:00
commit 50eb0b6e07
3 changed files with 19 additions and 8 deletions

1
.gitignore vendored
View file

@ -19,3 +19,4 @@ clog
/php-nikic-php-parser4-4.13.1-63a79e8.tgz
/php-nikic-php-parser4-4.13.2-210577f.tgz
/php-nikic-php-parser4-4.14.0-34bea19.tgz
/php-nikic-php-parser4-4.15.1-0ef6c55.tgz

View file

@ -10,18 +10,24 @@
# For compatibility with SCL
%undefine __brp_mangle_shebangs
%global gh_commit 34bea19b6e03d8153165d8f30bba4c3be86184c1
%if 0%{?fedora}
%bcond_without tests
%else
# disabled as phpunit not availble
%bcond_with tests
%endif
%global gh_commit 0ef6c55a3f47f89d7a374e6f835197a0b5fcf900
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner nikic
%global gh_project PHP-Parser
%global pk_project php-parser
%global php_home %{_datadir}/php
%global ns_project PhpParser
%global with_tests 0%{!?_without_tests:1}
%global major 4
Name: php-%{gh_owner}-%{pk_project}%{major}
Version: 4.14.0
Version: 4.15.1
Release: 1%{?dist}
Summary: A PHP parser written in PHP - version %{major}
@ -34,7 +40,7 @@ Source1: makesrc.sh
Patch0: %{name}-rpm.patch
BuildArch: noarch
%if %{with_tests}
%if %{with tests}
# For tests
# as we use phpunit9
BuildRequires: php(language) >= 7.3
@ -50,8 +56,8 @@ BuildRequires: php-spl
%global phpunit %{_bindir}/phpunit9
BuildRequires: phpunit9
# Autoloader
BuildRequires: php-fedora-autoloader-devel
%endif
BuildRequires: php-fedora-autoloader-devel
# From composer.json, "require": {
# "php": ">=7.0",
@ -72,7 +78,7 @@ Provides: php-composer(%{gh_owner}/%{pk_project}) = %{version}
%description
This is a PHP 5.2 to PHP 7.4 parser written in PHP.
This is a PHP parser written in PHP.
Its purpose is to simplify static code analysis and manipulation.
This package provides the library version %{major} and the php-parse%{major} command.
@ -105,7 +111,7 @@ install -Dpm 0755 bin/php-parse %{buildroot}%{_bindir}/php-parse%{major}
%check
%if %{with_tests}
%if %{with tests}
: Test the command
sed -e 's:%{php_home}:%{buildroot}%{php_home}:' \
bin/php-parse > bin/php-parse-test
@ -151,6 +157,10 @@ exit $ret
%changelog
* Thu Sep 8 2022 Remi Collet <remi@remirepo.net> - 4.15.1-1
- update to 4.15.1
- only run test suite on Fedora, not on EL
* Wed Jun 1 2022 Remi Collet <remi@remirepo.net> - 4.14.0-1
- update to 4.14.0

View file

@ -1 +1 @@
SHA512 (php-nikic-php-parser4-4.14.0-34bea19.tgz) = 1b20f8e9989e1b28e17c9513f092b7fced41ce6668349a48e871645451941ce21459649da1d384fdd27adc45d9287b10a09b7a5930cc2f1ceb749bb1a082ee44
SHA512 (php-nikic-php-parser4-4.15.1-0ef6c55.tgz) = 5f68d6ffa512727cb30dacd5b4f057103a8a3be804b7008a41fff52d5add1c5e71c80f9046782b1399eccc9a99266b7f332106fd77420cd1ff0fc77d2615c408