diff --git a/.gitignore b/.gitignore index 9aae347..5cf5e7d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,33 +1,12 @@ -clog -/php-nikic-php-parser4-4.2.5-b76bbc3.tgz -/php-nikic-php-parser4-4.3.0-9a9981c.tgz -/php-nikic-php-parser4-4.4.0-bd43ec7.tgz -/php-nikic-php-parser4-4.5.0-53c2753.tgz -/php-nikic-php-parser4-4.6.0-c346bbf.tgz -/php-nikic-php-parser4-4.8.0-8c58eb4.tgz -/php-nikic-php-parser4-4.9.0-aaee038.tgz -/php-nikic-php-parser4-4.9.1-88e5197.tgz -/php-nikic-php-parser4-4.10.0-1c13d05.tgz -/php-nikic-php-parser4-4.10.1-1b479e7.tgz -/php-nikic-php-parser4-4.10.2-658f1be.tgz -/php-nikic-php-parser4-4.10.3-dbe56d2.tgz -/php-nikic-php-parser4-4.10.4-c6d052f.tgz -/php-nikic-php-parser4-4.10.5-4432ba3.tgz -/php-nikic-php-parser4-4.11.0-fe14cf3.tgz -/php-nikic-php-parser4-4.12.0-6608f01.tgz -/php-nikic-php-parser4-4.13.0-50953a2.tgz -/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 -/php-nikic-php-parser4-4.15.2-f59bbe4.tgz -/php-nikic-php-parser4-4.15.3-570e980.tgz -/php-nikic-php-parser4-4.15.4-6bb5176.tgz -/php-nikic-php-parser4-4.15.5-11e2663.tgz -/php-nikic-php-parser4-4.16.0-19526a3.tgz -/php-nikic-php-parser4-4.17.1-a6303e5.tgz -/php-nikic-php-parser4-4.18.0-1bcbb21.tgz -/php-nikic-php-parser4-4.19.1-4e1b88d.tgz -/php-nikic-php-parser4-4.19.2-0ed4c89.tgz -/php-nikic-php-parser4-4.19.4-715f4d2.tgz -/php-nikic-php-parser4-4.19.5-51bd93c.tgz +/php-nikic-php-parser4-4.0.0-9c18e3d.tar.gz +/php-nikic-php-parser4-4.0.1-e4a54fa.tar.gz +/php-nikic-php-parser4-4.0.2-35b8caf.tar.gz +/php-nikic-php-parser4-4.0.3-bd088dc.tar.gz +/php-nikic-php-parser4-4.0.4-fa6ee28.tar.gz +/php-nikic-php-parser4-4.1.0-d0230c5.tar.gz +/php-nikic-php-parser4-4.1.1-8aae5b5.tar.gz +/php-nikic-php-parser4-4.2.0-594bcae.tar.gz +/php-nikic-php-parser4-4.2.1-5221f49.tar.gz +/php-nikic-php-parser4-4.2.2-1bd73cc.tar.gz +/php-nikic-php-parser4-4.2.3-e612609.tar.gz +/php-nikic-php-parser4-4.2.4-97e59c7.tar.gz diff --git a/makesrc.sh b/makesrc.sh deleted file mode 100755 index 7d752c6..0000000 --- a/makesrc.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/bash - -NAME=$(basename $PWD) -OWNER=$(sed -n '/^%global gh_owner/{s/.* //;p}' $NAME.spec) -PROJECT=$(sed -n '/^%global gh_project/{s/.* //;p}' $NAME.spec) -VERSION=$(sed -n '/^Version:/{s/.* //;p}' $NAME.spec) -COMMIT=$(sed -n '/^%global gh_commit/{s/.* //;p}' $NAME.spec) -SHORT=${COMMIT:0:7} - -echo -e "\nCreate git snapshot\nName=$NAME, Owner=$OWNER, Project=$PROJECT, Version=$VERSION, Commit=$COMMIT\n" - -echo "Cloning..." -git clone https://github.com/$OWNER/$PROJECT.git $PROJECT-$COMMIT - -echo "Getting commit..." -pushd $PROJECT-$COMMIT -git checkout $COMMIT -cp composer.json ../composer.json -popd - -echo "Archiving..." -tar czf $NAME-$VERSION-$SHORT.tgz --exclude-vcs $PROJECT-$COMMIT - -echo "Cleaning..." -rm -rf $PROJECT-$COMMIT - -echo "Done." - diff --git a/php-nikic-php-parser4.spec b/php-nikic-php-parser4.spec index 5658e8c..03d2ffa 100644 --- a/php-nikic-php-parser4.spec +++ b/php-nikic-php-parser4.spec @@ -1,47 +1,41 @@ # remirepo/fedora spec file for php-nikic-php-parser4 # -# SPDX-FileCopyrightText: Copyright 2016-2025 Remi Collet -# SPDX-License-Identifier: CECILL-2.1 -# http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt +# Copyright (c) 2016-2019 Remi Collet +# License: CC-BY-SA +# http://creativecommons.org/licenses/by-sa/4.0/ # # Please, preserve the changelog entries # +# For compatibility with SCL +%undefine __brp_mangle_shebangs -%if 0%{?fedora} -%bcond_without tests -%else -# disabled as phpunit not availble -%bcond_with tests -%endif - -%global gh_commit 51bd93cc741b7fc3d63d20b6bdcd99fdaa359837 +%global gh_commit 97e59c7a16464196a8b9c77c47df68e4a39a45c4 %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.19.5 +Version: 4.2.4 Release: 1%{?dist} Summary: A PHP parser written in PHP - version %{major} -License: BSD-3-Clause +License: BSD URL: https://github.com/%{gh_owner}/%{gh_project} -Source0: %{name}-%{version}-%{gh_short}.tgz -Source1: makesrc.sh +Source: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{name}-%{version}-%{gh_short}.tar.gz # Autoloader Patch0: %{name}-rpm.patch BuildArch: noarch -%if %{with tests} +%if %{with_tests} # For tests -# as we use phpunit9 -BuildRequires: php(language) >= 7.3 +BuildRequires: php(language) >= 7.0 BuildRequires: php-tokenizer BuildRequires: php-reflection BuildRequires: php-ctype @@ -49,18 +43,17 @@ BuildRequires: php-json BuildRequires: php-pcre BuildRequires: php-spl # From composer.json, "require-dev": { -# "phpunit/phpunit": "^7.0 || ^8.0 || ^9.0", -# "ircmaxell/php-yacc": "0.0.7" -%global phpunit %{_bindir}/phpunit9 -BuildRequires: phpunit9 +# "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0" +%global phpunit %{_bindir}/phpunit8 +BuildRequires: phpunit8 # Autoloader +BuildRequires: php-composer(fedora/autoloader) %endif -BuildRequires: php-fedora-autoloader-devel # From composer.json, "require": { -# "php": ">=7.1", +# "php": ">=7.0", # "ext-tokenizer": "*" -Requires: php(language) >= 7.1 +Requires: php(language) >= 7.0 Requires: php-tokenizer # From phpcompatinfo report for version 4.0.0 Requires: php-reflection @@ -70,13 +63,13 @@ Requires: php-pcre Requires: php-spl Requires: php-cli # Autoloader -Requires: php-composer(fedora/autoloader) +BuildRequires: php-composer(fedora/autoloader) Provides: php-composer(%{gh_owner}/%{pk_project}) = %{version} %description -This is a PHP parser written in PHP. +This is a PHP 5.2 to PHP 7.2 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. @@ -89,14 +82,18 @@ Autoloader: %{php_home}/%{ns_project}%{major}/autoload.php %prep %setup -q -n %{gh_project}-%{gh_commit} -%patch -P0 -p1 -b .rpm +%patch0 -p1 -b .rpm %build -: Generate an simple classmap autoloader -phpab --template fedora \ - --output lib/%{ns_project}/autoload.php \ - lib/%{ns_project} +: Generate an simple PSR-4 autoloader +cat << 'AUTOLOAD' | tee lib/%{ns_project}/autoload.php + bin/php-parse-test @@ -119,19 +116,18 @@ php bin/php-parse-test --help mkdir vendor cat << 'AUTOLOAD' | tee vendor/autoload.php - 4.19.5-1 -- update to 4.19.5 -- re-license spec file to CECILL-2.1 - -* Fri Jul 25 2025 Fedora Release Engineering - 4.19.4-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild - -* Sat Jan 18 2025 Fedora Release Engineering - 4.19.4-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild - -* Mon Sep 30 2024 Remi Collet - 4.19.4-1 -- update to 4.19.4 - -* Wed Sep 18 2024 Remi Collet - 4.19.2-1 -- update to 4.19.2 - -* Fri Jul 19 2024 Fedora Release Engineering - 4.19.1-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild - -* Tue Mar 19 2024 Remi Collet - 4.19.1-1 -- update to 4.19.1 -- raise dependency on PHP 7.1 - -* Thu Jan 25 2024 Fedora Release Engineering - 4.18.0-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild - -* Sun Jan 21 2024 Fedora Release Engineering - 4.18.0-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild - -* Mon Dec 11 2023 Remi Collet - 4.18.0-1 -- update to 4.18.0 - -* Fri Aug 18 2023 Remi Collet - 4.17.1-1 -- update to 4.17.1 - -* Fri Jul 21 2023 Fedora Release Engineering - 4.16.0-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild - -* Mon Jun 26 2023 Remi Collet - 4.16.0-1 -- update to 4.16.0 - -* Wed May 24 2023 Remi Collet - 4.15.5-1 -- update to 4.15.5 - -* Mon Mar 6 2023 Remi Collet - 4.15.4-1 -- update to 4.15.4 - -* Fri Jan 20 2023 Fedora Release Engineering - 4.15.3-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild - -* Tue Jan 17 2023 Remi Collet - 4.15.3-1 -- update to 4.15.3 - -* Mon Nov 14 2022 Remi Collet - 4.15.2-1 -- update to 4.15.2 - -* Thu Sep 8 2022 Remi Collet - 4.15.1-1 -- update to 4.15.1 - -* Fri Jul 22 2022 Fedora Release Engineering - 4.14.0-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild - -* Mon Jun 13 2022 Remi Collet - 4.14.0-2 -- only run test suite on Fedora, not on EL - -* Wed Jun 1 2022 Remi Collet - 4.14.0-1 -- update to 4.14.0 - -* Fri Jan 21 2022 Fedora Release Engineering - 4.13.2-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild - -* Wed Dec 1 2021 Remi Collet - 4.13.2-1 -- update to 4.13.2 - -* Thu Nov 4 2021 Remi Collet - 4.13.1-1 -- update to 4.13.1 - -* Tue Sep 21 2021 Remi Collet - 4.13.0-1 -- update to 4.13.0 - -* Wed Jul 21 2021 Remi Collet - 4.12.0-1 -- update to 4.12.0 - -* Mon Jul 5 2021 Remi Collet - 4.11.0-1 -- update to 4.11.0 -- switch to phpunit9 - -* Tue May 4 2021 Remi Collet - 4.10.5-1 -- update to 4.10.5 - -* Wed Jan 27 2021 Fedora Release Engineering - 4.10.4-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild - -* Mon Dec 21 2020 Remi Collet - 4.10.4-1 -- update to 4.10.4 - -* Fri Dec 4 2020 Remi Collet - 4.10.3-1 -- update to 4.10.3 - -* Mon Sep 28 2020 Remi Collet - 4.10.2-1 -- update to 4.10.2 - -* Thu Sep 24 2020 Remi Collet - 4.10.1-1 -- update to 4.10.1 - -* Sun Sep 20 2020 Remi Collet - 4.10.0-1 -- update to 4.10.0 - -* Mon Aug 31 2020 Remi Collet - 4.9.1-1 -- update to 4.9.1 - -* Wed Aug 19 2020 Remi Collet - 4.9.0-1 -- update to 4.9.0 - -* Mon Aug 10 2020 Remi Collet - 4.8.0-1 -- update to 4.8.0 - -* Tue Jul 28 2020 Fedora Release Engineering - 4.6.0-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild - -* Fri Jul 3 2020 Remi Collet - 4.6.0-1 -- update to 4.6.0 - -* Thu Jun 25 2020 Remi Collet - 4.5.0-2 -- switch to classmap autoloader -- add missing dependency on fedora/autoloader - -* Wed Jun 3 2020 Remi Collet - 4.5.0-1 -- update to 4.5.0 - -* Mon Apr 13 2020 Remi Collet - 4.4.0-1 -- update to 4.4.0 - -* Thu Jan 30 2020 Fedora Release Engineering - 4.3.0-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild - -* Tue Nov 12 2019 Remi Collet - 4.3.0-1 -- update to 4.3.0 - -* Mon Oct 28 2019 Remi Collet - 4.2.5-1 -- update to 4.2.5 -- sources from git snapshot - * Mon Sep 2 2019 Remi Collet - 4.2.4-1 - update to 4.2.4 @@ -299,18 +152,12 @@ exit $ret - update to 4.2.3 - use phpunit8 -* Fri Jul 26 2019 Fedora Release Engineering - 4.2.2-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild - * Mon May 27 2019 Remi Collet - 4.2.2-1 - update to 4.2.2 * Mon Feb 18 2019 Remi Collet - 4.2.1-1 - update to 4.2.1 -* Sat Feb 02 2019 Fedora Release Engineering - 4.2.0-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild - * Sun Jan 13 2019 Remi Collet - 4.2.0-1 - update to 4.2.0 diff --git a/sources b/sources index 619d1c0..22cd820 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (php-nikic-php-parser4-4.19.5-51bd93c.tgz) = 739cb8134ca83bfaeb8189dc40ef7603e2c7c7813d28841b279306f6e2d3f77910eb5033aae0c2bad0f38d0dc6490953cc3518bf433c4f99cecf2007c10d17cc +SHA512 (php-nikic-php-parser4-4.2.4-97e59c7.tar.gz) = 5feedb3a891146729901e89d2e088f2a90007e21f6845a95d4a773d77c5db575eb93b2bc7424de2f862b91a113b6086334981b1c9e4ed039d366e74d0bc08c68