[php-pecl-selinux] PHP 5.4.0 Build

Remi Collet remi at fedoraproject.org
Fri Jan 20 18:13:30 UTC 2012


commit fb6a629e469e4b44b944765a7a3be2857460cda5
Author: remi <fedora at famillecollet.com>
Date:   Fri Jan 20 19:13:01 2012 +0100

    PHP 5.4.0 Build

 php-pecl-selinux.spec |   24 ++++++++++++++++++++++--
 1 files changed, 22 insertions(+), 2 deletions(-)
---
diff --git a/php-pecl-selinux.spec b/php-pecl-selinux.spec
index 0323e54..ff76a2e 100644
--- a/php-pecl-selinux.spec
+++ b/php-pecl-selinux.spec
@@ -5,7 +5,7 @@
 Summary: SELinux binding for PHP scripting language
 Name: php-pecl-selinux
 Version: 0.3.1
-Release: 7%{?dist}
+Release: 8%{?dist}
 License: PHP
 Group: Development/Languages
 URL: http://pecl.php.net/package/%{pecl_name}
@@ -15,7 +15,7 @@ BuildRequires: php-devel >= 5.2.0, php-pear, libselinux-devel >= 2.0.80
 Requires: php >= 5.2.0, libselinux >= 2.0.80
 Requires(post): %{__pecl}
 Requires(postun): %{__pecl}
-%if 0%{?php_zend_api}
+%if 0%{?php_zend_api:1}
 Requires: php(zend-abi) = %{php_zend_api}
 Requires: php(api) = %{php_core_api}
 %else
@@ -23,6 +23,13 @@ Requires: php-api = %{php_apiver}
 %endif
 Provides: php-pecl(%{pecl_name}) = %{version}-%{release}
 
+# RPM 4.8
+%{?filter_provides_in: %filter_provides_in %{php_extdir}/.*\.so$}
+%{?filter_setup}
+# RPM 4.9
+%global __provides_exclude_from %{?__provides_exclude_from:%__provides_exclude_from|}%{php_extdir}/.*\\.so$
+
+
 %description
 This package is an extension to the PHP Hypertext Preprocessor.
 It wraps the libselinux library and provides a set of interfaces
@@ -54,6 +61,14 @@ install -D -p -m 0644 selinux.ini %{buildroot}%{_sysconfdir}/php.d/selinux.ini
 %{__install} -m 644 ../package.xml %{buildroot}%{pecl_xmldir}/%{name}.xml
 popd
 
+%check
+cd %{pecl_name}-%{version}
+php -n \
+    -d extension_dir=modules \
+    -d extension=%{pecl_name}.so \
+    --modules | grep %{pecl_name}
+
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -77,6 +92,11 @@ fi
 %{pecl_xmldir}/%{name}.xml
 
 %changelog
+* Thu Jan 19 2012 Remi Collet <remi at fedoraproject.org> - 0.3.1-8
+- build against php 5.4
+- add filter to fix private-shared-object-provides
+- add %%check for php extension
+
 * Sat Jan 14 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.3.1-7
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
 


More information about the scm-commits mailing list