From Fedora Project Wiki
(Undo revision 268687 by Remi (talk))
(apache requirement)
Line 10: Line 10:
= Actual Guidelines =
= Actual Guidelines =


== Macros and scriptlets ==
== Requires and Provides ==


No information on macro provided by php-devel
nothing about apache requirement


= Change proposal  =
= Change proposal  =


== Macros and scriptlets ==
== Requires and Provides ==


=== PHP ZTS extension ===
=== Apache requirement ===


When apache run in worker mode (instead of prefork mode), the ZTS (Zend Thread Safe) version of PHP is used.
A PHP library must not requires php nor httpd as is could be used with other webserver / SAPI (php-cli, php-cgi, php-fpm, ...).
 
If an extension maintainer want to provides a ZTS version of this extension, he must ensure that
* the extension is thread safe
* the libraries used by the extension are thread safe
 
The php-devel package in fedora >= 17 (5.4.0) provides the necessary files to build ZTS modules and provides several new macros:
 
For standard (NTS) extensions
<pre>
%{__php}          %{_bindir}/php
%{php_extdir}    %{_libdir}/php/modules
%{php_inidir}    %{_sysconfdir}/php.d
%{php_incldir    %{_includedir}/php
</pre>
 
For ZTS extensions
<pre>
%{__ztsphp}      %{_bindir}/zts-php
%{php_ztsextdir}  %{_libdir}/php-zts/modules
%{php_ztsinidir}  %{_sysconfdir}/php-zts.d
%{php_ztsincldir  %{_includedir}/php-zts/php
</pre>
 
php-devel provides the executables needed during the build of a ZTS extension, which are:
* zts-phpize
* zts-php-config
* zts-php (which is only useful to run test suite during build)


Only a PHP web application, which provide httpd configuration, should requires php and httpd.


[[Category:Packaging guidelines drafts]]
[[Category:Packaging guidelines drafts]]

Revision as of 16:14, 11 June 2012

[[TableOfContents(3)]

Proposed Changes to PHP Guidelines

Synopsis

This page describes items that need to be changed in the PHP Guidelines or other items that need to be reviewed or ratified by the Fedora Packaging Comittee and FESCo .


Actual Guidelines

Requires and Provides

nothing about apache requirement

Change proposal

Requires and Provides

Apache requirement

A PHP library must not requires php nor httpd as is could be used with other webserver / SAPI (php-cli, php-cgi, php-fpm, ...).

Only a PHP web application, which provide httpd configuration, should requires php and httpd.