From 7763b7110113f8496d63d1b5a6351e8b199e9953 Mon Sep 17 00:00:00 2001 From: Zhongling He Date: Tue, 18 Apr 2023 15:24:09 +0800 Subject: [PATCH] refactor rpm spec --- php.spec | 793 ++++++++++++++++++++++++++++--------------------------- 1 file changed, 397 insertions(+), 396 deletions(-) diff --git a/php.spec b/php.spec index aaa3faa..1e050c5 100644 --- a/php.spec +++ b/php.spec @@ -4,6 +4,17 @@ %global apiver 20220829 %global zendver 20220829 %global pdover 20170320 +%bcond_with zts +%bcond_with firebird +%bcond_with freetds +%bcond_with sodium +%bcond_with pspell +%bcond_with tidy +%bcond_with db4 +%bcond_with qdbm +%bcond_with modphp +%bcond_with imap +%bcond_without lmdb # we don't want -z defs linker flag %undefine _strict_symbol_defs_build @@ -27,19 +38,6 @@ # needed at srpm build time, when httpd-devel not yet installed %{!?_httpd_mmn: %{expand: %%global _httpd_mmn %%(cat %{_includedir}/httpd/.mmn 2>/dev/null || echo 0-0)}} -%bcond_with zts -%bcond_with firebird -%bcond_with freetds -%bcond_with sodium -%bcond_with pspell -%bcond_with tidy -%bcond_with db4 -%bcond_with qdbm -%bcond_with modphp -%bcond_with imap -%bcond_without lmdb - - Summary: PHP scripting language for creating dynamic web sites Name: php Version: 8.2.5 @@ -109,23 +107,23 @@ BuildRequires: httpd-filesystem BuildRequires: nginx-filesystem BuildRequires: libstdc++-devel # no pkgconfig to avoid compat-openssl10 -BuildRequires: openssl-devel >= 1.0.2 -BuildRequires: pkgconfig(sqlite3) >= 3.7.4 -BuildRequires: pkgconfig(zlib) >= 1.2.0.4 -BuildRequires: smtpdaemon -BuildRequires: pkgconfig(libedit) -BuildRequires: pkgconfig(libpcre2-8) >= 10.30 -BuildRequires: pkgconfig(libxcrypt) -BuildRequires: bzip2 -BuildRequires: perl-interpreter -BuildRequires: autoconf -BuildRequires: automake -BuildRequires: make -BuildRequires: gcc -BuildRequires: gcc-c++ -BuildRequires: libtool -BuildRequires: libtool-ltdl-devel BuildRequires: systemtap-sdt-devel +BuildRequires: libtool-ltdl-devel +BuildRequires: libtool +BuildRequires: gcc-c++ +BuildRequires: gcc +BuildRequires: make +BuildRequires: automake +BuildRequires: autoconf +BuildRequires: perl-interpreter +BuildRequires: bzip2 +BuildRequires: pkgconfig(libxcrypt) +BuildRequires: pkgconfig(libpcre2-8) >= 10.30 +BuildRequires: pkgconfig(libedit) +BuildRequires: smtpdaemon +BuildRequires: pkgconfig(zlib) >= 1.2.0.4 +BuildRequires: pkgconfig(sqlite3) >= 3.7.4 +BuildRequires: openssl-devel >= 1.0.2 # used for tests BuildRequires: %{_bindir}/ps BuildRequires: tzdata @@ -233,35 +231,35 @@ Provides: php(api) = %{apiver} Provides: php(zend-abi) = %{zendver} Provides: php(language) = %{version} # Provides for all builtin/shared modules: -Provides: php-bz2, php-bz2 -Provides: php-calendar -Provides: php-core = %{version} -Provides: php-ctype -Provides: php-curl -Provides: php-date -Provides: bundled(timelib) -Provides: php-exif -Provides: php-fileinfo -Provides: bundled(libmagic) = 5.29 -Provides: php-filter -Provides: php-ftp -Provides: php-gettext -Provides: php-hash -Provides: php-mhash = %{version} -Provides: php-iconv -Obsoletes: php-json < 8 -Provides: php-json = %{version} -Provides: php-libxml -Provides: php-openssl -Provides: php-phar -Provides: php-pcre -Provides: php-reflection -Provides: php-session -Provides: php-sockets -Provides: php-spl -Provides: php-standard = %{version} -Provides: php-tokenizer Provides: php-zlib +Provides: php-tokenizer +Provides: php-standard = %{version} +Provides: php-spl +Provides: php-sockets +Provides: php-session +Provides: php-reflection +Provides: php-pcre +Provides: php-phar +Provides: php-openssl +Provides: php-libxml +Provides: php-json = %{version} +Obsoletes: php-json < 8 +Provides: php-iconv +Provides: php-mhash = %{version} +Provides: php-hash +Provides: php-gettext +Provides: php-ftp +Provides: php-filter +Provides: bundled(libmagic) = 5.29 +Provides: php-fileinfo +Provides: php-exif +Provides: bundled(timelib) +Provides: php-date +Provides: php-curl +Provides: php-ctype +Provides: php-core = %{version} +Provides: php-calendar +Provides: php-bz2, php-bz2 %description common The php-common package contains files used by both the php @@ -294,200 +292,180 @@ The php-devel package contains the files needed for building PHP extensions. If you need to compile your own PHP extensions, you will need to install this package. -%package opcache -Summary: The Zend OPcache -License: PHP -Requires: php-common = %{version}-%{release} -Provides: php-pecl-zendopcache = %{version} -Provides: php-pecl(opcache) = %{version} +%package ffi +Summary: Foreign Function Interface +# All files licensed under PHP version 3.0.1 +License: PHP +Group: System Environment/Libraries +BuildRequires: pkgconfig(libffi) +Requires: php-common = %{version}-%{release} -%description opcache -The Zend OPcache provides faster PHP execution through opcode caching and -optimization. It improves PHP performance by storing precompiled script -bytecode in the shared memory. This eliminates the stages of reading code from -the disk and compiling it on future access. In addition, it applies a few -bytecode optimization patterns that make code execution faster. +%description ffi +FFI is one of the features that made Python and LuaJIT very useful for fast +prototyping. It allows calling C functions and using C data types from pure +scripting language and therefore develop “system code” more productively. -%if %{with imap} -%package imap -Summary: A module for PHP applications that use IMAP -# All files licensed under PHP version 3.01 +For PHP, FFI opens a way to write PHP extensions and bindings to C libraries +in pure PHP. + + +%if %{with sodium} +%package sodium +Summary: Wrapper for the Sodium cryptographic library +# All files licensed under PHP version 3.0.1 License: PHP +BuildRequires: pkgconfig(libsodium) >= 1.0.9 + Requires: php-common = %{version}-%{release} -BuildRequires: pkgconfig(krb5) -BuildRequires: pkgconfig(krb5-gssapi) -BuildRequires: openssl-devel >= 1.0.2 -BuildRequires: libc-client-devel +Obsoletes: php-pecl-libsodium2 < 3 +Provides: php-pecl(libsodium) = %{version} -%description imap -The php-imap module will add IMAP (Internet Message Access Protocol) -support to PHP. IMAP is a protocol for retrieving and uploading e-mail -messages on mail servers. PHP is an HTML-embedded scripting language. +%description sodium +The php-sodium package provides a simple, +low-level PHP extension for the libsodium cryptographic library. %endif -%package ldap -Summary: A module for PHP applications that use LDAP -# All files licensed under PHP version 3.01 +%package zip +Summary: ZIP archive management extension for PHP +# All files licensed under PHP version 3.0.1 License: PHP Requires: php-common = %{version}-%{release} -BuildRequires: pkgconfig(libsasl2) -BuildRequires: openldap-devel -BuildRequires: openssl-devel >= 1.0.2 +Obsoletes: php-pecl-zip < %{zipver} +Provides: php-pecl(zip) = %{zipver} +Provides: php-pecl-zip = %{zipver} +BuildRequires: pkgconfig(libzip) >= 0.11 -%description ldap -The php-ldap adds Lightweight Directory Access Protocol (LDAP) -support to PHP. LDAP is a set of protocols for accessing directory -services over the Internet. PHP is an HTML-embedded scripting -language. +%description zip +The php-zip package provides an extension that will add +support for ZIP archive management to PHP. -%package pdo -Summary: A database access abstraction module for PHP applications -# All files licensed under PHP version 3.01 +%package enchant +Summary: Enchant spelling extension for PHP applications +# All files licensed under PHP version 3.0 License: PHP Requires: php-common = %{version}-%{release} -# ABI/API check - Arch specific -Provides: php-pdo-abi = %{pdover} -Provides: php(pdo-abi) = %{pdover} -Provides: php-sqlite3 -Provides: php-pdo_sqlite +BuildRequires: pkgconfig(enchant-2) -%description pdo -The php-pdo package contains a dynamic shared object that will add -a database access abstraction layer to PHP. This module provides -a common interface for accessing MySQL, PostgreSQL or other -databases. +%description enchant +The php-enchant package contains a dynamic shared object that will add +support for using the enchant library to PHP. -%package mysqlnd -Summary: A module for PHP applications that use MySQL databases +%package intl +Summary: Internationalization extension for PHP applications # All files licensed under PHP version 3.01 License: PHP -Requires: php-pdo = %{version}-%{release} -Provides: php_database -Provides: php-mysqli = %{version}-%{release} -Provides: php-pdo_mysql - -%description mysqlnd -The php-mysqlnd package contains a dynamic shared object that will add -MySQL database support to PHP. MySQL is an object-relational database -management system. PHP is an HTML-embeddable scripting language. If -you need MySQL support for PHP applications, you will need to install -this package and the php package. +Requires: php-common = %{version}-%{release} +BuildRequires: pkgconfig(icu-i18n) >= 50.1 +BuildRequires: pkgconfig(icu-io) >= 50.1 +BuildRequires: pkgconfig(icu-uc) >= 50.1 -This package use the MySQL Native Driver +%description intl +The php-intl package contains a dynamic shared object that will add +support for using the ICU library to PHP. -%package pgsql -Summary: A PostgreSQL database module for PHP +%if %{with pspell} +%package pspell +Summary: A module for PHP applications for using pspell interfaces # All files licensed under PHP version 3.01 License: PHP -Requires: php-pdo = %{version}-%{release} -Provides: php_database -Provides: php-pdo_pgsql -BuildRequires: krb5-devel -BuildRequires: openssl-devel >= 1.0.2 -BuildRequires: libpq-devel +Requires: php-common = %{version}-%{release} +BuildRequires: aspell-devel >= 0.50.0 -%description pgsql -The php-pgsql package add PostgreSQL database support to PHP. -PostgreSQL is an object-relational database management -system that supports almost all SQL constructs. PHP is an -HTML-embedded scripting language. If you need back-end support for -PostgreSQL, you should install this package in addition to the main -php package. +%description pspell +The php-pspell package contains a dynamic shared object that will add +support for using the pspell library to PHP. +%endif -%package process -Summary: Modules for PHP script using system process interfaces -# All files licensed under PHP version 3.01 -License: PHP +%package embedded +Summary: PHP library for embedding in applications Requires: php-common = %{version}-%{release} -Provides: php-posix -Provides: php-shmop -Provides: php-sysvsem -Provides: php-sysvshm -Provides: php-sysvmsg +# doing a real -devel package for just the .so symlink is a bit overkill +Provides: php-embedded-devel = %{version}-%{release} -%description process -The php-process package contains dynamic shared objects which add -support to PHP using system interfaces for inter-process -communication. +%description embedded +The php-embedded package contains a library which can be embedded +into applications to provide PHP scripting language support. -%package odbc -Summary: A module for PHP applications that use ODBC databases -# All files licensed under PHP version 3.01, except -# pdo_odbc is licensed under PHP version 3.0 +%if %{with freetds} +%package pdo-dblib +Summary: PDO driver for Microsoft SQL Server and Sybase databases +# All files licensed under PHP version 3.01 License: PHP Requires: php-pdo = %{version}-%{release} -Provides: php_database -Provides: php-pdo_odbc -BuildRequires: unixODBC-devel +BuildRequires: freetds-devel +Provides: php-pdo_dblib -%description odbc -The php-odbc package contains a dynamic shared object that will add -database support through ODBC to PHP. ODBC is an open specification -which provides a consistent API for developers to use for accessing -data sources (which are often, but not always, databases). PHP is an -HTML-embeddable scripting language. If you need ODBC support for PHP -applications, you will need to install this package and the php -package. +%description pdo-dblib +The php-pdo-dblib package contains a dynamic shared object +that implements the PHP Data Objects (PDO) interface to enable access from +PHP to Microsoft SQL Server and Sybase databases through the FreeTDS library. +%endif -%package soap -Summary: A module for PHP applications that use the SOAP protocol +%if %{with tidy} +%package tidy +Summary: Standard PHP module provides tidy library support # All files licensed under PHP version 3.01 License: PHP Requires: php-common = %{version}-%{release} -BuildRequires: pkgconfig(libxml-2.0) +BuildRequires: libtidy-devel -%description soap -The php-soap package contains a dynamic shared object that will add -support to PHP for using the SOAP web services protocol. +%description tidy +The php-tidy package contains a dynamic shared object that will add +support for using the tidy library to PHP. +%endif -%if %{with firebird} -%package pdo-firebird -Summary: PDO driver for Interbase/Firebird databases +%package dba +Summary: A database abstraction layer module for PHP applications # All files licensed under PHP version 3.01 License: PHP -# for fb_config command -BuildRequires: firebird-devel -Requires: php-pdo = %{version}-%{release} -Provides: php_database -Provides: php-pdo_firebird - -%description pdo-firebird -The php-pdo-firebird package contains the PDO driver for -Interbase/Firebird databases. +%if %{with db4} +BuildRequires: libdb-devel %endif +BuildRequires: tokyocabinet-devel +%if %{with lmdb} +BuildRequires: lmdb-devel +%endif +%if %{with qdbm} +BuildRequires: qdbm-devel +%endif +Requires: php-common = %{version}-%{release} -%package snmp -Summary: A module for PHP applications that query SNMP-managed devices +%description dba +The php-dba package contains a dynamic shared object that will add +support for using the DBA database abstraction layer to PHP. + +%package gmp +Summary: A module for PHP applications for using the GNU MP library # All files licensed under PHP version 3.01 License: PHP -Requires: php-common = %{version}-%{release}, net-snmp -BuildRequires: net-snmp-devel +BuildRequires: gmp-devel +Requires: php-common = %{version}-%{release} -%description snmp -The php-snmp package contains a dynamic shared object that will add -support for querying SNMP devices to PHP. PHP is an HTML-embeddable -scripting language. If you need SNMP support for PHP applications, you -will need to install this package and the php package. +%description gmp +These functions allow you to work with arbitrary-length integers +using the GNU MP library. -%package xml -Summary: A module for PHP applications which use XML +%package bcmath +Summary: A module for PHP applications for using the bcmath library +# All files licensed under PHP version 3.01, except +# libbcmath is licensed under LGPLv2+ +License: PHP and LGPLv2+ +Requires: php-common = %{version}-%{release} + +%description bcmath +The php-bcmath package contains a dynamic shared object that will add +support for using the bcmath library to PHP. + +%package gd +Summary: A module for PHP applications for using the gd graphics library # All files licensed under PHP version 3.01 License: PHP Requires: php-common = %{version}-%{release} -Provides: php-dom -Provides: php-domxml -Provides: php-simplexml -Provides: php-xmlreader -Provides: php-xmlwriter -Provides: php-xsl -BuildRequires: pkgconfig(libxslt) >= 1.1 -BuildRequires: pkgconfig(libexslt) -BuildRequires: pkgconfig(libxml-2.0) >= 2.7.6 +BuildRequires: pkgconfig(gdlib) >= 2.1.1 -%description xml -The php-xml package contains dynamic shared objects which add support -to PHP for manipulating XML documents using the DOM tree, -and performing XSL transformations on XML documents. +%description gd +The php-gd package contains a dynamic shared object that will add +support for using the gd graphics library to PHP. %package mbstring Summary: A module for PHP applications which need multi-byte string handling @@ -503,181 +481,201 @@ Requires: php-common = %{version}-%{release} The php-mbstring package contains a dynamic shared object that will add support for multi-byte string handling to PHP. -%package gd -Summary: A module for PHP applications for using the gd graphics library +%package xml +Summary: A module for PHP applications which use XML # All files licensed under PHP version 3.01 License: PHP Requires: php-common = %{version}-%{release} -BuildRequires: pkgconfig(gdlib) >= 2.1.1 - -%description gd -The php-gd package contains a dynamic shared object that will add -support for using the gd graphics library to PHP. - -%package bcmath -Summary: A module for PHP applications for using the bcmath library -# All files licensed under PHP version 3.01, except -# libbcmath is licensed under LGPLv2+ -License: PHP and LGPLv2+ -Requires: php-common = %{version}-%{release} +Provides: php-dom +Provides: php-domxml +Provides: php-simplexml +Provides: php-xmlreader +Provides: php-xmlwriter +Provides: php-xsl +BuildRequires: pkgconfig(libxslt) >= 1.1 +BuildRequires: pkgconfig(libexslt) +BuildRequires: pkgconfig(libxml-2.0) >= 2.7.6 -%description bcmath -The php-bcmath package contains a dynamic shared object that will add -support for using the bcmath library to PHP. +%description xml +The php-xml package contains dynamic shared objects which add support +to PHP for manipulating XML documents using the DOM tree, +and performing XSL transformations on XML documents. -%package gmp -Summary: A module for PHP applications for using the GNU MP library +%package snmp +Summary: A module for PHP applications that query SNMP-managed devices # All files licensed under PHP version 3.01 License: PHP -BuildRequires: gmp-devel -Requires: php-common = %{version}-%{release} +Requires: php-common = %{version}-%{release}, net-snmp +BuildRequires: net-snmp-devel -%description gmp -These functions allow you to work with arbitrary-length integers -using the GNU MP library. +%description snmp +The php-snmp package contains a dynamic shared object that will add +support for querying SNMP devices to PHP. PHP is an HTML-embeddable +scripting language. If you need SNMP support for PHP applications, you +will need to install this package and the php package. -%package dba -Summary: A database abstraction layer module for PHP applications +%if %{with firebird} +%package pdo-firebird +Summary: PDO driver for Interbase/Firebird databases # All files licensed under PHP version 3.01 License: PHP -%if %{with db4} -BuildRequires: libdb-devel -%endif -BuildRequires: tokyocabinet-devel -%if %{with lmdb} -BuildRequires: lmdb-devel -%endif -%if %{with qdbm} -BuildRequires: qdbm-devel -%endif -Requires: php-common = %{version}-%{release} +# for fb_config command +BuildRequires: firebird-devel +Requires: php-pdo = %{version}-%{release} +Provides: php_database +Provides: php-pdo_firebird -%description dba -The php-dba package contains a dynamic shared object that will add -support for using the DBA database abstraction layer to PHP. +%description pdo-firebird +The php-pdo-firebird package contains the PDO driver for +Interbase/Firebird databases. +%endif -%if %{with tidy} -%package tidy -Summary: Standard PHP module provides tidy library support +%package soap +Summary: A module for PHP applications that use the SOAP protocol # All files licensed under PHP version 3.01 License: PHP Requires: php-common = %{version}-%{release} -BuildRequires: libtidy-devel +BuildRequires: pkgconfig(libxml-2.0) -%description tidy -The php-tidy package contains a dynamic shared object that will add -support for using the tidy library to PHP. -%endif +%description soap +The php-soap package contains a dynamic shared object that will add +support to PHP for using the SOAP web services protocol. -%if %{with freetds} -%package pdo-dblib -Summary: PDO driver for Microsoft SQL Server and Sybase databases -# All files licensed under PHP version 3.01 +%package odbc +Summary: A module for PHP applications that use ODBC databases +# All files licensed under PHP version 3.01, except +# pdo_odbc is licensed under PHP version 3.0 License: PHP Requires: php-pdo = %{version}-%{release} -BuildRequires: freetds-devel -Provides: php-pdo_dblib +Provides: php_database +Provides: php-pdo_odbc +BuildRequires: unixODBC-devel -%description pdo-dblib -The php-pdo-dblib package contains a dynamic shared object -that implements the PHP Data Objects (PDO) interface to enable access from -PHP to Microsoft SQL Server and Sybase databases through the FreeTDS library. -%endif +%description odbc +The php-odbc package contains a dynamic shared object that will add +database support through ODBC to PHP. ODBC is an open specification +which provides a consistent API for developers to use for accessing +data sources (which are often, but not always, databases). PHP is an +HTML-embeddable scripting language. If you need ODBC support for PHP +applications, you will need to install this package and the php +package. -%package embedded -Summary: PHP library for embedding in applications +%package process +Summary: Modules for PHP script using system process interfaces +# All files licensed under PHP version 3.01 +License: PHP Requires: php-common = %{version}-%{release} -# doing a real -devel package for just the .so symlink is a bit overkill -Provides: php-embedded-devel = %{version}-%{release} +Provides: php-posix +Provides: php-shmop +Provides: php-sysvsem +Provides: php-sysvshm +Provides: php-sysvmsg -%description embedded -The php-embedded package contains a library which can be embedded -into applications to provide PHP scripting language support. +%description process +The php-process package contains dynamic shared objects which add +support to PHP using system interfaces for inter-process +communication. -%if %{with pspell} -%package pspell -Summary: A module for PHP applications for using pspell interfaces +%package pgsql +Summary: A PostgreSQL database module for PHP # All files licensed under PHP version 3.01 License: PHP -Requires: php-common = %{version}-%{release} -BuildRequires: aspell-devel >= 0.50.0 +Requires: php-pdo = %{version}-%{release} +Provides: php_database +Provides: php-pdo_pgsql +BuildRequires: krb5-devel +BuildRequires: openssl-devel >= 1.0.2 +BuildRequires: libpq-devel -%description pspell -The php-pspell package contains a dynamic shared object that will add -support for using the pspell library to PHP. -%endif +%description pgsql +The php-pgsql package add PostgreSQL database support to PHP. +PostgreSQL is an object-relational database management +system that supports almost all SQL constructs. PHP is an +HTML-embedded scripting language. If you need back-end support for +PostgreSQL, you should install this package in addition to the main +php package. -%package intl -Summary: Internationalization extension for PHP applications +%package mysqlnd +Summary: A module for PHP applications that use MySQL databases # All files licensed under PHP version 3.01 License: PHP -Requires: php-common = %{version}-%{release} -BuildRequires: pkgconfig(icu-i18n) >= 50.1 -BuildRequires: pkgconfig(icu-io) >= 50.1 -BuildRequires: pkgconfig(icu-uc) >= 50.1 +Requires: php-pdo = %{version}-%{release} +Provides: php_database +Provides: php-mysqli = %{version}-%{release} +Provides: php-pdo_mysql -%description intl -The php-intl package contains a dynamic shared object that will add -support for using the ICU library to PHP. +%description mysqlnd +The php-mysqlnd package contains a dynamic shared object that will add +MySQL database support to PHP. MySQL is an object-relational database +management system. PHP is an HTML-embeddable scripting language. If +you need MySQL support for PHP applications, you will need to install +this package and the php package. -%package enchant -Summary: Enchant spelling extension for PHP applications -# All files licensed under PHP version 3.0 +This package use the MySQL Native Driver + +%package pdo +Summary: A database access abstraction module for PHP applications +# All files licensed under PHP version 3.01 License: PHP Requires: php-common = %{version}-%{release} -BuildRequires: pkgconfig(enchant-2) +# ABI/API check - Arch specific +Provides: php-pdo-abi = %{pdover} +Provides: php(pdo-abi) = %{pdover} +Provides: php-sqlite3 +Provides: php-pdo_sqlite -%description enchant -The php-enchant package contains a dynamic shared object that will add -support for using the enchant library to PHP. +%description pdo +The php-pdo package contains a dynamic shared object that will add +a database access abstraction layer to PHP. This module provides +a common interface for accessing MySQL, PostgreSQL or other +databases. -%package zip -Summary: ZIP archive management extension for PHP -# All files licensed under PHP version 3.0.1 +%package ldap +Summary: A module for PHP applications that use LDAP +# All files licensed under PHP version 3.01 License: PHP Requires: php-common = %{version}-%{release} -Obsoletes: php-pecl-zip < %{zipver} -Provides: php-pecl(zip) = %{zipver} -Provides: php-pecl-zip = %{zipver} -BuildRequires: pkgconfig(libzip) >= 0.11 +BuildRequires: pkgconfig(libsasl2) +BuildRequires: openldap-devel +BuildRequires: openssl-devel >= 1.0.2 -%description zip -The php-zip package provides an extension that will add -support for ZIP archive management to PHP. +%description ldap +The php-ldap adds Lightweight Directory Access Protocol (LDAP) +support to PHP. LDAP is a set of protocols for accessing directory +services over the Internet. PHP is an HTML-embedded scripting +language. -%if %{with sodium} -%package sodium -Summary: Wrapper for the Sodium cryptographic library -# All files licensed under PHP version 3.0.1 +%if %{with imap} +%package imap +Summary: A module for PHP applications that use IMAP +# All files licensed under PHP version 3.01 License: PHP -BuildRequires: pkgconfig(libsodium) >= 1.0.9 - Requires: php-common = %{version}-%{release} -Obsoletes: php-pecl-libsodium2 < 3 -Provides: php-pecl(libsodium) = %{version} +BuildRequires: pkgconfig(krb5) +BuildRequires: pkgconfig(krb5-gssapi) +BuildRequires: openssl-devel >= 1.0.2 +BuildRequires: libc-client-devel -%description sodium -The php-sodium package provides a simple, -low-level PHP extension for the libsodium cryptographic library. +%description imap +The php-imap module will add IMAP (Internet Message Access Protocol) +support to PHP. IMAP is a protocol for retrieving and uploading e-mail +messages on mail servers. PHP is an HTML-embedded scripting language. %endif -%package ffi -Summary: Foreign Function Interface -# All files licensed under PHP version 3.0.1 -License: PHP -Group: System Environment/Libraries -BuildRequires: pkgconfig(libffi) -Requires: php-common = %{version}-%{release} - -%description ffi -FFI is one of the features that made Python and LuaJIT very useful for fast -prototyping. It allows calling C functions and using C data types from pure -scripting language and therefore develop “system code” more productively. - -For PHP, FFI opens a way to write PHP extensions and bindings to C libraries -in pure PHP. +%package opcache +Summary: The Zend OPcache +License: PHP +Requires: php-common = %{version}-%{release} +Provides: php-pecl-zendopcache = %{version} +Provides: php-pecl(opcache) = %{version} +%description opcache +The Zend OPcache provides faster PHP execution through opcode caching and +optimization. It improves PHP performance by storing precompiled script +bytecode in the shared memory. This eliminates the stages of reading code from +the disk and compiling it on future access. In addition, it applies a few +bytecode optimization patterns that make code execution faster. %prep %setup -q -n php-%{version} @@ -700,14 +698,14 @@ in pure PHP. # Prevent %%doc confusion over LICENSE files -cp Zend/LICENSE ZEND_LICENSE -cp TSRM/LICENSE TSRM_LICENSE -cp Zend/asm/LICENSE BOOST_LICENSE -cp sapi/fpm/LICENSE fpm_LICENSE -cp ext/mbstring/libmbfl/LICENSE libmbfl_LICENSE -cp ext/fileinfo/libmagic/LICENSE libmagic_LICENSE -cp ext/bcmath/libbcmath/LICENSE libbcmath_LICENSE cp ext/date/lib/LICENSE.rst timelib_LICENSE +cp ext/bcmath/libbcmath/LICENSE libbcmath_LICENSE +cp ext/fileinfo/libmagic/LICENSE libmagic_LICENSE +cp ext/mbstring/libmbfl/LICENSE libmbfl_LICENSE +cp sapi/fpm/LICENSE fpm_LICENSE +cp Zend/asm/LICENSE BOOST_LICENSE +cp TSRM/LICENSE TSRM_LICENSE +cp Zend/LICENSE ZEND_LICENSE # Multiple builds for multiple SAPIs mkdir build-cgi build-embedded \ @@ -833,28 +831,28 @@ mkdir Zend && cp ../Zend/zend_{language,ini}_{parser,scanner}.[ch] Zend ln -sf ../configure %configure \ - --enable-rtld-now \ - --cache-file=../config.cache \ - --with-libdir=%{_lib} \ - --with-config-file-path=%{_sysconfdir} \ - --with-config-file-scan-dir=%{_sysconfdir}/php.d \ - --disable-debug \ - --with-pic \ - --disable-rpath \ - --without-pear \ - --without-gdbm \ - --with-openssl \ - --with-system-ciphers \ - --with-external-pcre \ - --with-external-libcrypt \ - --with-zlib \ - --with-layout=GNU \ - --with-kerberos \ - --with-libxml \ - --with-system-tzdata \ - --with-mhash \ - --without-password-argon2 \ --enable-dtrace \ + --without-password-argon2 \ + --with-mhash \ + --with-system-tzdata \ + --with-libxml \ + --with-kerberos \ + --with-layout=GNU \ + --with-zlib \ + --with-external-libcrypt \ + --with-external-pcre \ + --with-system-ciphers \ + --with-openssl \ + --without-gdbm \ + --without-pear \ + --disable-rpath \ + --with-pic \ + --disable-debug \ + --with-config-file-scan-dir=%{_sysconfdir}/php.d \ + --with-config-file-path=%{_sysconfdir} \ + --with-libdir=%{_lib} \ + --cache-file=../config.cache \ + --enable-rtld-now \ $* if test $? != 0; then tail -500 config.log @@ -894,19 +892,6 @@ build --libdir=%{_libdir}/php \ %endif %if %{with qdbm} --with-qdbm=%{_prefix} \ -%endif - --enable-exif=shared \ - --enable-ftp=shared \ - --with-gettext=shared \ - --with-iconv=shared \ - --enable-sockets=shared \ - --enable-tokenizer=shared \ - --with-ldap=shared --with-ldap-sasl \ - --enable-mysqlnd=shared \ - --with-mysqli=shared,mysqlnd \ - --with-mysql-sock=%{mysql_sock} \ -%if %{with firebird} - --with-pdo-firebird=shared \ %endif --enable-dom=shared \ --with-pgsql=shared \ @@ -922,6 +907,19 @@ build --libdir=%{_libdir}/php \ --with-pdo-mysql=shared,mysqlnd \ --with-pdo-pgsql=shared,%{_prefix} \ --with-pdo-sqlite=shared \ +%if %{with firebird} + --with-pdo-firebird=shared \ +%endif + --enable-exif=shared \ + --enable-ftp=shared \ + --with-gettext=shared \ + --with-iconv=shared \ + --enable-sockets=shared \ + --enable-tokenizer=shared \ + --with-ldap=shared --with-ldap-sasl \ + --enable-mysqlnd=shared \ + --with-mysqli=shared,mysqlnd \ + --with-mysql-sock=%{mysql_sock} \ %if %{with freetds} --with-pdo-dblib=shared,%{_prefix} \ %endif @@ -952,18 +950,18 @@ build --libdir=%{_libdir}/php \ popd without_shared="--disable-gd \ - --disable-dom --disable-dba --without-unixODBC \ - --disable-opcache \ - --disable-phpdbg \ - --without-ffi \ - --disable-xmlreader --disable-xmlwriter \ - --without-sodium \ - --without-sqlite3 --disable-phar --disable-fileinfo \ - --without-pspell \ - --without-curl --disable-posix --disable-xml \ - --disable-simplexml --disable-exif --without-gettext \ - --without-iconv --disable-ftp --without-bz2 --disable-ctype \ --disable-shmop --disable-sockets --disable-tokenizer \ + --without-iconv --disable-ftp --without-bz2 --disable-ctype \ + --disable-simplexml --disable-exif --without-gettext \ + --without-curl --disable-posix --disable-xml \ + --without-pspell \ + --without-sqlite3 --disable-phar --disable-fileinfo \ + --without-sodium \ + --disable-xmlreader --disable-xmlwriter \ + --without-ffi \ + --disable-phpdbg \ + --disable-opcache \ + --disable-dom --disable-dba --without-unixODBC \ --disable-sysvmsg --disable-sysvshm --disable-sysvsem" %if %{with modphp} @@ -1046,20 +1044,20 @@ build --includedir=%{_includedir}/php-zts \ %if %{with firebird} --with-pdo-firebird=shared \ %endif - --enable-dom=shared \ - --with-pgsql=shared \ - --enable-simplexml=shared \ - --enable-xml=shared \ - --with-snmp=shared,%{_prefix} \ - --enable-soap=shared \ - --with-xsl=shared,%{_prefix} \ - --enable-xmlreader=shared --enable-xmlwriter=shared \ - --with-curl=shared \ - --enable-pdo=shared \ - --with-pdo-odbc=shared,unixODBC,%{_prefix} \ - --with-pdo-mysql=shared,mysqlnd \ - --with-pdo-pgsql=shared,%{_prefix} \ --with-pdo-sqlite=shared \ + --with-pdo-pgsql=shared,%{_prefix} \ + --with-pdo-mysql=shared,mysqlnd \ + --with-pdo-odbc=shared,unixODBC,%{_prefix} \ + --enable-pdo=shared \ + --with-curl=shared \ + --enable-xmlreader=shared --enable-xmlwriter=shared \ + --with-xsl=shared,%{_prefix} \ + --enable-soap=shared \ + --with-snmp=shared,%{_prefix} \ + --enable-xml=shared \ + --enable-simplexml=shared \ + --with-pgsql=shared \ + --enable-dom=shared \ %if %{with freetds} --with-pdo-dblib=shared,%{_prefix} \ %endif @@ -1508,6 +1506,9 @@ systemctl try-restart php-fpm.service >/dev/null 2>&1 || : %changelog +* Tue Apr 18 2023 Zhongling He - 8.2.5-2 +- refactor rpm spec + * Wed Apr 12 2023 Funda Wang - 8.2.5-1 - New version 8.2.5 -- Gitee