From 2231abb4cb2d51630660ccc7ce377f21c2870fe9 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 24 Nov 2016 15:24:05 +0100 Subject: php-ast: cleanup for Fedora review --- php-ast-dev.spec | 7 ------- php-ast.spec | 53 +++++++++++++---------------------------------------- 2 files changed, 13 insertions(+), 47 deletions(-) diff --git a/php-ast-dev.spec b/php-ast-dev.spec index 276fb5d..462e86b 100644 --- a/php-ast-dev.spec +++ b/php-ast-dev.spec @@ -31,7 +31,6 @@ Group: Development/Languages URL: https://github.com/%{gh_owner}/%{gh_project} Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{gh_project}-%{version}-%{gh_short}.tar.gz -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildRequires: %{?scl_prefix}php-devel > 7 BuildRequires: %{?scl_prefix}php-tokenizer @@ -107,7 +106,6 @@ make %{?_smp_mflags} %install -rm -rf %{buildroot} # Install the NTS stuff make -C NTS install INSTALL_ROOT=%{buildroot} install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} @@ -150,12 +148,7 @@ REPORT_EXIT_STATUS=1 \ %endif -%clean -rm -rf %{buildroot} - - %files -%defattr(-,root,root,-) %{!?_licensedir:%global license %%doc} %license NTS/LICENSE %doc NTS/EXPERIMENTAL diff --git a/php-ast.spec b/php-ast.spec index 276fb5d..5bf9b11 100644 --- a/php-ast.spec +++ b/php-ast.spec @@ -1,3 +1,6 @@ +# Fedora spec file for php-ast +# Without SCL compatibility stuff, from: +# # remirepo spec file for php-ast # # Copyright (c) 2015-2016 Remi Collet @@ -6,61 +9,35 @@ # # Please, preserve the changelog entries # -%{?scl: %scl_package php-ast} - %global gh_commit abfef40846cb5454dafa1808769fde851ba8dd70 %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner nikic %global gh_project php-ast -#global gh_date 20160608 %global pecl_name ast %global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} # After 20-tokenizer.ini %global ini_name 40-%{pecl_name}.ini Summary: Abstract Syntax Tree -Name: %{?scl_prefix}php-ast +Name: php-ast Version: 0.1.2 -%if 0%{?gh_date:1} -Release: 0.2.%{gh_date}git%{gh_short}%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} -%else -Release: 2%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} -%endif +Release: 1%{?dist} License: PHP Group: Development/Languages URL: https://github.com/%{gh_owner}/%{gh_project} Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{gh_project}-%{version}-%{gh_short}.tar.gz -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root -BuildRequires: %{?scl_prefix}php-devel > 7 -BuildRequires: %{?scl_prefix}php-tokenizer - -Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} -Requires: %{?scl_prefix}php(api) = %{php_core_api} -Requires: %{?scl_prefix}php-tokenizer%{?_isa} -%{?_sclreq:Requires: %{?scl_prefix}runtime%{?_sclreq}%{?_isa}} - -%if "%{?vendor}" == "Remi Collet" && 0%{!?scl:1} -Obsoletes: php70u-%{pecl_name} <= %{version} -Obsoletes: php70w-%{pecl_name} <= %{version} -%if "%{php_version}" > "7.1" -Obsoletes: php71u-%{pecl_name} <= %{version} -Obsoletes: php71w-%{pecl_name} <= %{version} -%endif -%endif +BuildRequires: php-devel > 7 +BuildRequires: php-tokenizer -%if 0%{?fedora} < 20 && 0%{?rhel} < 7 -# Filter shared private -%{?filter_provides_in: %filter_provides_in %{_libdir}/.*\.so$} -%{?filter_setup} -%endif +Requires: php(zend-abi) = %{php_zend_api} +Requires: php(api) = %{php_core_api} +Requires: php-tokenizer%{?_isa} %description This extension exposes the abstract syntax tree generated by PHP 7. -Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')%{?scl: as Software Collection (%{scl} by %{?scl_vendor}%{!?scl_vendor:rh})}. - %prep %setup -qc @@ -107,7 +84,6 @@ make %{?_smp_mflags} %install -rm -rf %{buildroot} # Install the NTS stuff make -C NTS install INSTALL_ROOT=%{buildroot} install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} @@ -150,13 +126,7 @@ REPORT_EXIT_STATUS=1 \ %endif -%clean -rm -rf %{buildroot} - - %files -%defattr(-,root,root,-) -%{!?_licensedir:%global license %%doc} %license NTS/LICENSE %doc NTS/EXPERIMENTAL %doc NTS/README.md @@ -173,6 +143,9 @@ rm -rf %{buildroot} %changelog +* Thu Nov 24 2016 Remi Collet - 0.1.2-1 +- drop SCL stuff for Fedora review + * Wed Sep 14 2016 Remi Collet - 0.1.2-2 - rebuild for PHP 7.1 new API version -- cgit