# $Id$ PNAME="php" PVER="7.3.7" PBUILD="r2" SPLIT_PACKAGES="php php-cgi php-apache php-embedded php-pear php-bcmath php-curl php-dba php-gd php-gmp php-intl php-mbstring php-pdo php-mysql php-opcache php-process php-soap php-sqlite php-xml php-xmlrpc php-json" #php-pdo-dblib #php-imap #php-mcrypt #php-snmp #php-pgsql #php-recode # alx disabled: #php-fpm #php-enchant #php-ldap #php-odbc #php-pspell #php-tidy #php-phpdbg # splits with more then one module: # php-odbc = odbc, pdo_odbc # php-mysql = mysqlnd, mysqli, pdo_mysql # php-xml = xsl, wddx, dom, xmlreader, xmlwriter # php-process = sysvmsg, sysvsem, sysvshm, posix # php-sqlite = sqlite, sqlite3, pdo_sqlite # # todo: mssql -> requires freetds # mcrypt -> requires libmcrypt # pdo-dpblib -> requires freetds # recode -> requires librecode # ToDO: mcrypt, mhash, maintainer-zts, pgsql, interbase/firebird, pdo-dblib PCAT="dev-lang" HOMEPAGE="http://php.net/" DEPEND_COMMON=">= sys-libs/ncurses-6.1 >= sys-libs/zlib-1.2 >= app-arch/bzip2-1 >= dev-libs/openssl-1.1" DEPEND_COMMON_DEV=">= sys-libs/ncurses-dev-6.1 >= sys-libs/zlib-dev-1.2 >= app-arch/bzip2-dev-1 >= dev-libs/openssl-dev-1.1" #>= sys-libs/readline-7.0 DEPEND_STDCPP=">= sys-libs/libstdc++-8.3" DEPEND_STDCPP_DEV=">= sys-libs/libstdc++-dev-8.3" DEPEND_APACHE=">= net-www/apache2-2.4" #DEPEND_ASPELL=">= app-text/aspell-0.60" DEPEND_BDB=">= dev-db/db-6.2" DEPEND_BDB_DEV=">= dev-db/db-dev-6.2" DEPEND_CURL=">= net-libs/libcurl-7.61" DEPEND_CURL_DEV=">= net-libs/libcurl-dev-7.61" #DEPEND_ENCHANT=">= app-text/enchant-1.6" DEPEND_GD=">= virtual/libjpeg >= media-libs/libpng-1.5 >= x11-libs/libXpm-4 >= media-libs/freetype-2.6 >= media-libs/gd-2.1 >= media-libs/t1lib-5.1" DEPEND_GD_DEV=">= virtual/libjpeg-dev >= media-libs/libpng-dev-1.5 >= x11-libs/libXpm-dev-4 >= media-libs/freetype-dev-2.6 >= media-libs/gd-dev-2.1 >= media-libs/t1lib-dev-5.1" DEPEND_GMP=">= dev-libs/gmp-6" DEPEND_GMP_DEV=">= dev-libs/gmp-dev-6" DEPEND_INTL=">= dev-libs/icu-64.2 >= sys-libs/libgcc-8.3" DEPEND_INTL_DEV=">= dev-libs/icu-dev-64.2 >= sys-libs/libgcc-dev-8.3" #DEPEND_LDAP=">= net-nds/libldap-2.4" DEPEND_MYSQL=">= virtual/mysql" #DEPEND_ODBC=">= dev-db/unixodbc-2.3" DEPEND_PCRE=">= dev-libs/libpcre-8.37" DEPEND_PCRE_DEV=">= dev-libs/libpcre-dev-8.37" #DEPEMD_SASL=">= dev-libs/cyrus-sasl-2.1.23" DEPEND_SQLITE=">= dev-db/sqlite-3.20" DEPEND_SQLITE_DEV=">= dev-db/sqlite-dev-3.20" #DEPEND_TIDY=">= app-text/htmltidy-5.4" DEPEND_XML=">= dev-libs/libxml2-2.9" DEPEND_XML_DEV=">= dev-libs/libxml2-dev-2.9" DEPEND_XSLT=">= dev-libs/libxslt-1.1.26" DEPEND_XSLT_DEV=">= dev-libs/libxslt-dev-1.1.26" DEPEND_SYSTEMD=">= sys-apps/systemd-230" DEPEND_SYSTEMD_DEV=">= sys-apps/systemd-dev-230" ALX_DEV_DEPEND="${DEPEND_COMMON_DEV} ${DEPEND_STDCPP_DEV} ${DEPEND_BDB_DEV} ${DEPEND_CURL_DEV} ${DEPEND_GD_DEV} ${DEPEND_GMP_DEV} ${DEPEND_INTL_DEV} ${DEPEND_PCRE_DEV} ${DEPEND_SQLITE_DEV} ${DEPEND_XML_DEV} ${DEPEND_XSLT_DEV} ${DEPEND_SYSTEMD_DEV}" SDEPEND="${DEPEND_COMMON} ${DEPEND_STDCPP} ${DEPEND_APACHE} ${DEPEND_ASPELL} ${DEPEND_BDB} ${DEPEND_CURL} ${DEPEND_GD} ${DEPEND_GMP} ${DEPEND_INTL} ${DEPEND_MYSQL} ${DEPEND_PCRE} ${DEPEND_SQLITE} ${DEPEND_XML} ${DEPEND_XSLT} ${DEPEND_SYSTEMD} >= sys-dev/m4-1.4 >= sys-dev/libtool-1.5 >= sys-dev/gettext-0.17 >= virtual/sed >= sys-dev/bison-2.5 ${ALX_DEV_DEPEND}" #${DEPEND_ENCHANT} #${DEPEND_LDAP} #${DEPEND_ODBC} #${DEPEND_SASL} #${DEPEND_TIDY} SRCFILE="${PNAME/5/}-${PVER}.tar.bz2" SRCDIR="${BUILDDIR}/${PNAME/5/}-${PVER}" sminclude mtools php systemd msetfeature "!check" # no check target SRC_URI=( http://de2.php.net/distributions/${SRCFILE} http://us2.php.net/distributions/${SRCFILE} mirror://${PNAME}/${SRCFILE} mirror://${PNAME}/${PNAME}-5.4.19-db6.patch mirror://${PNAME}/${PNAME}-5.2.4-multilib.patch mirror://${PNAME}/${PNAME}-7.1.6-httpd-config.patch mirror://${PNAME}/php${PVER%%.*}_module.conf mirror://${PNAME}/php-fpm.conf mirror://${PNAME}/php-fpm-www.conf mirror://${PNAME}/php-fpm.service mirror://${PNAME}/php-fpm.logrotate mirror://${PNAME}/php-fpm.confd mirror://${PNAME}/php-fpm.tmpfilesd ) # 7.3 stable series UP2TAG="7.3" UP2DATE="updatecmd ${HOMEPAGE} | grep 'Current.*${UP2TAG}.*Stable' | sed 's/.*\:\ \(.*\)/\1/'" split_info_php() { DESCRIPTION="PHP Hypertext Preprocessor, a scripting language especially suited for web development." DEPEND="${DEPEND_COMMON} ${DEPEND_XML} ${DEPEND_PCRE} ${DEPEND_SYSTEMD}" } split_info_php-cgi() { DESCRIPTION="GI and FCGI SAPI for PHP." DEPEND="== dev-lang/php-${PVER} ${DEPEND_XML} ${DEPEND_PCRE}" PCAT="dev-php" } split_info_php-apache() { DESCRIPTION="Apache SAPI for PHP." DEPEND="== dev-lang/php-${PVER} ${DEPEND_XML} ${DEPEND_PCRE} ${DEPEND_APACHE} ${DEPEND_STDCPP}" PCAT="dev-php" } split_info_php-embedded() { DESCRIPTION="PHP library for embedding in applications." DEPEND="== dev-lang/php-${PVER} ${DEPEND_XML} ${DEPEND_PCRE} ${DEPEND_STDCPP}" PCAT="dev-php" } split_info_php-pear() { DESCRIPTION="PHP Extension and Application Repository." DEPEND="== dev-lang/php-${PVER}" PCAT="dev-php" } #split_info_php-fpm() #{ # DESCRIPTION="PHP FastCGI Process Manager." # DEPEND="== dev-lang/php-${PVER} # ${DEPEND_SYSTEMD}" # PCAT="dev-php" #} split_info_php-bcmath() { DESCRIPTION="A module for PHP applications for using the bcmath library." DEPEND="== dev-lang/php-${PVER}" PCAT="dev-php" } split_info_php-curl() { DESCRIPTION="A module for PHP applications that use curl." DEPEND="== dev-lang/php-${PVER} ${DEPEND_CURL}" PCAT="dev-php" } split_info_php-dba() { DESCRIPTION="A database abstraction layer module for PHP applications." DEPEND="== dev-lang/php-${PVER}" PCAT="dev-php" } #split_info_php-enchant() #{ # DESCRIPTION="Human Language and Character Encoding Support." # DEPEND="== dev-lang/php-${PVER} # ${DEPEND_ENCHANT}" # PCAT="dev-php" #} split_info_php-gd() { DESCRIPTION="A module for PHP applications for using the gd graphics library." DEPEND="== dev-lang/php-${PVER} ${DEPEND_GD}" PCAT="dev-php" } split_info_php-gmp() { DESCRIPTION="A module for PHP applications for using the gmp library." DEPEND="== dev-lang/php-${PVER} ${DEPEND_GMP}" PCAT="dev-php" } split_info_php-intl() { DESCRIPTION="Internationalization extension for PHP applications." DEPEND="== dev-lang/php-${PVER} ${DEPEND_INTL}" PCAT="dev-php" } #split_info_php-ldap() #{ # DESCRIPTION="A module for PHP applications that use LDAP." # DEPEND="== dev-lang/php-${PVER} # ${DEPEND_SASL} # ${DEPEND_LDAP}" # PCAT="dev-php" #} split_info_php-mbstring() { DESCRIPTION="A module for PHP applications which need multi-byte string handling." DEPEND="== dev-lang/php-${PVER}" PCAT="dev-php" } split_info_php-mysql() { DESCRIPTION="Modules for PHP applications that use MySQL databases." DEPEND="== dev-lang/php-${PVER} == dev-php/php-pdo-${PVER} ${DEPEND_MYSQL}" PCAT="dev-php" } #split_info_php-odbc() #{ # DESCRIPTION="Modules for PHP applications that use ODBC databases." # DEPEND="== dev-lang/php-${PVER} # == dev-php/php-pdo-${PVER} # ${DEPEND_ODBC}" # PCAT="dev-php" #} split_info_php-opcache() { DESCRIPTION="The Zend OPcache." DEPEND="== dev-lang/php-${PVER}" PCAT="dev-php" } split_info_php-pdo() { DESCRIPTION="A database access abstraction module for PHP applications." DEPEND="== dev-lang/php-${PVER}" PCAT="dev-php" } split_info_php-process() { DESCRIPTION="Modules for PHP script using system process interfaces." DEPEND="== dev-lang/php-${PVER}" PCAT="dev-php" } #split_info_php-pspell() #{ # DESCRIPTION="A module for PHP applications for using pspell interfaces." # DEPEND="== dev-lang/php-${PVER} # ${DEPEND_ASPELL}" # PCAT="dev-php" #} split_info_php-soap() { DESCRIPTION="A module for PHP applications that use the SOAP protocol." DEPEND="== dev-lang/php-${PVER} ${DEPEND_XML}" PCAT="dev-php" } split_info_php-sqlite() { DESCRIPTION="Modules for PHP applications that use SQLite databases." DEPEND="== dev-lang/php-${PVER} == dev-php/php-pdo-${PVER} ${DEPEND_SQLITE}" PCAT="dev-php" } #split_info_php-tidy() #{ # DESCRIPTION="Standard PHP module provides tidy library support." # DEPEND="== dev-lang/php-${PVER} # ${DEPEND_TIDY}" # PCAT="dev-php" #} split_info_php-xml() { DESCRIPTION="Modules for PHP applications which use XML." DEPEND="== dev-lang/php-${PVER} ${DEPEND_XML} ${DEPEND_XSLT}" PCAT="dev-php" } split_info_php-xmlrpc() { DESCRIPTION="A module for PHP applications which use the XML-RPC protocol." DEPEND="== dev-lang/php-${PVER} ${DEPEND_XML}" PCAT="dev-php" } split_info_php-json() { DESCRIPTION="JavaScript Object Notation extension for PHP." DEPEND="== dev-lang/php-${PVER}" PCAT="dev-php" } split_info_php-phpdbg() { DESCRIPTION="The interactive PHP debugger." DEPEND="== dev-lang/php-${PVER}" PCAT="dev-php" } # install-helper function install_php_extensions() { local extensions="$@" [[ -z ${extensions} ]] && die "no extensions given" # set default PHP_BUILD_DIR, env can override this : ${PHP_BUILD_DIR="${BUILDDIR}/build-php"} cd ${PHP_BUILD_DIR} # needed directories minstalldir ${PHP_CONFIG_SCAN_DIR} || die minstalldir ${PHP_EXTENSIONS_DIR} || die local MCONFIG local ext for ext in ${extensions} do # install extensions and the config ini minstallexec modules/${ext}.so ${PHP_EXTENSIONS_DIR} || die "mod ${ext}" MCONFIG="${PHP_CONFIG_SCAN_DIR}/${ext}.ini" mclearconfig || die "ini ${ext}" # -hack -fixme - mysqlnd must be loaded before mysqli if [[ ${ext} = mysqli ]] then maddconfig "extension=mysqlnd" || die "ini ${ext}" fi maddconfig "extension=${ext}" || die "ini ${ext}" done } src_prepare() { munpack ${SRCFILE} || die cd ${SRCDIR} # version branding sed -i "s:^\(PHP_EXTRA_VERSION=\).*:\1-magellan-${PBUILD}:" configure.ac || die # support >= db-6.0 # see for more issues: https://bugs.php.net/bug.php?id=65426 mpatch ${PNAME}-5.4.19-db6.patch || die # fixes multilib search pathes mpatch ${PNAME}-5.2.4-multilib.patch || die # do not touch the system httpd.conf mpatch ${PNAME}-7.1.6-httpd-config.patch || die # fully regenerate aclocal too if [ -f aclocal.m4 ] then rm aclocal.m4 || die fi # rebuild configure mautoreconf || die # force use of system libtool mlibtoolize || die } src_compile() { local php_base_config local php_extensions local php_disable_shared_extensions local current_run # --with-libdir needed, doesn't honor --libdir php_base_config="--libdir=/usr/lib \ --with-libdir=$(mlibdir) \ --with-config-file-path=${PHP_CONFIG_DIR} \ --with-config-file-scan-dir=${PHP_CONFIG_SCAN_DIR} \ --enable-inline-optimization \ --disable-rpath \ --disable-debug \ --disable-static \ --enable-shared \ --without-pear" # --with-pdo-dblib=shared,/usr , mssql support, requires freetds php_extensions="--with-zlib \ --with-bz2=shared \ --enable-bcmath=shared \ --enable-calendar=shared \ --enable-exif=shared \ --enable-ftp=shared \ --with-gettext=shared \ --enable-mbstring=shared \ --enable-mbregex \ --with-ncurses=shared \ --with-openssl=shared \ --with-jpeg-dir=/usr \ --with-png-dir=/usr \ --with-xpm-dir=/usr \ --with-gd=shared \ --enable-gd-native-ttf \ --with-freetype-dir=shared,/usr \ --with-ttf \ --with-t1lib=/usr \ --with-pcre-regex \ --with-gmp=shared \ --with-curl=shared \ --with-curlwrappers \ --enable-dba=shared \ --with-db4=shared \ --enable-mysqlnd=shared \ --with-mysqli=shared,mysqlnd \ --without-unixODBC \ --with-sqlite=shared \ --with-sqlite3=shared \ --enable-pdo=shared \ --without-pdo-odbc \ --with-pdo-mysql=shared,mysqlnd \ --with-pdo-sqlite=shared,/usr \ --enable-dbase=shared \ --enable-dom=shared \ --with-xmlrpc=shared \ --enable-xmlreader=shared \ --enable-xmlwriter=shared \ --with-xsl=shared,/usr \ --enable-wddx=shared \ --enable-soap=shared \ --enable-json=shared \ --enable-zip=shared \ --enable-phar=shared \ --enable-posix=shared \ --enable-fileinfo=shared \ --enable-intl=shared \ --enable-sockets=shared \ --enable-sysvsem=shared \ --enable-sysvshm=shared \ --enable-sysvmsg=shared \ --without-tidy \ --without-ldap \ --without-ldap-sasl \ --without-enchant \ --without-pspell --disable-zip" # ToDo: # --with-mcrypt=shared \ # --with-mhash=shared \ # --with-imap=shared \ # --with-imap-ssl \ # --enable-maintainer-zts <- threaded apache2 support # required for fpm php_disable_shared_extensions="--without-gd \ --disable-dom \ --disable-dba \ --without-unixODBC \ --disable-xmlreader \ --disable-xmlwriter \ --without-sqlite3 \ --disable-phar \ --disable-fileinfo \ --disable-json \ --without-pspell \ --disable-wddx \ --without-curl \ --disable-zip \ --disable-posix \ --disable-sysvmsg \ --disable-sysvshm \ --disable-sysvsem" # set default extension_dir for all builds export EXTENSION_DIR=${PHP_EXTENSIONS_DIR} # set default pear dir for all builds export PEAR_INSTALLDIR=${PHP_PEAR_DIR} # # build php: # # prepare build outside of the SRCDIR install -d ${BUILDDIR}/build-php cd ${BUILDDIR}/build-php ln -snf ${SRCDIR}/configure # bison-3.0 workaround install -d ${BUILDDIR}/build-php/Zend || die cp ${SRCDIR}/Zend/zend_{language,ini}_{parser,scanner}.[ch] ${BUILDDIR}/build-php/Zend || die mconfigure \ --srcdir=${SRCDIR} \ ${php_base_config} \ --disable-cgi \ --without-readline \ ${php_extensions} \ || die mmake || die # # build cgi/fastcgi # # prepare build with the previous run, to save a lot of time current_run=cgi echo "preparing build for '${current_run}'" cp -arv ${BUILDDIR}/build-php ${BUILDDIR}/build-${current_run} || die cd ${BUILDDIR}/build-${current_run} mconfigure \ --srcdir=${SRCDIR} \ ${php_base_config} \ --enable-cgi \ --enable-force-cgi-redirect \ --enable-fastcgi \ --disable-cli \ ${php_extensions} \ || die mmake || die # # build apache mod # # prepare build with the previous run, to save a lot of time current_run=apache echo "preparing build for '${current_run}'" cp -arv ${BUILDDIR}/build-php ${BUILDDIR}/build-${current_run} || die cd ${BUILDDIR}/build-${current_run} mconfigure \ --srcdir=${SRCDIR} \ ${php_base_config} \ --with-apxs2 \ --disable-cli \ ${php_extensions} \ || die mmake || die # # build embedded # # prepare build with the previous run, to save a lot of time current_run=embedded echo "preparing build for '${current_run}'" cp -arv ${BUILDDIR}/build-php ${BUILDDIR}/build-${current_run} || die cd ${BUILDDIR}/build-${current_run} mconfigure \ --srcdir=${SRCDIR} \ ${php_base_config} \ --enable-embed=shared \ --disable-cli \ ${php_extensions} \ || die mmake || die # # build pear # # prepare build with the previous run, to save a lot of time current_run=pear echo "preparing build for '${current_run}'" cp -arv ${BUILDDIR}/build-php ${BUILDDIR}/build-${current_run} || die cd ${BUILDDIR}/build-${current_run} mconfigure \ --srcdir=${SRCDIR} \ ${php_base_config} \ --disable-cgi \ --without-readline \ --enable-pcntl \ --with-pear \ ${php_extensions} \ || die mmake || die # # # # build fpm # # # # # prepare build with the previous run, to save a lot of time # current_run=fpm # echo "preparing build for '${current_run}'" # cp -arv ${BUILDDIR}/build-php ${BUILDDIR}/build-${current_run} || die # cd ${BUILDDIR}/build-${current_run} # # mconfigure \ # --srcdir=${SRCDIR} \ # ${php_base_config} \ # --enable-fpm \ # --without-mysql \ # --disable-pdo \ # ${php_disable_shared_extensions} \ # || die # # mmake || die # # # # build phpdbg # # # # # prepare build with the previous run, to save a lot of time # current_run=phpdbg # echo "preparing build for '${current_run}'" # cp -arv ${BUILDDIR}/build-php ${BUILDDIR}/build-${current_run} || die # cd ${BUILDDIR}/build-${current_run} # # mconfigure \ # --srcdir=${SRCDIR} \ # ${php_base_config} \ # --enable-phpdbg \ # ${php_extensions} \ # || die # # mmake || die echo "DEBUG: end" } src_install_php() { cd ${BUILDDIR}/build-php mmake -j1 INSTALL_ROOT=${BINDIR} EXTENSION_DIR=${PHP_EXTENSIONS_DIR} PEAR_INSTALLDIR=${PHP_PEAR_DIR} install || die # fix a broken symlink mlink phar.phar /usr/bin/phar || die local php_ini=${SRCDIR}/php.ini-production # php config minstalldir /etc/php/conf.d || die # remove windows remark sed -i -e '/^;extension_dir = "ext"/d' -e '/^; On windows:$/d' ${php_ini} || die # fix extensions dir location sed -i "s:^;\(extension_dir =\).*:\1 ${PHP_EXTENSIONS_DIR}:" ${php_ini} || die # allow short php open-tags sed -i "s:^\(short_open_tag =\).*:\1 On:" ${php_ini} || die minstallfile ${php_ini} /etc/php/php.ini || die # fix extension_dir also in php-config sed -i "s:^\(extension_dir=\).*:\1${PHP_EXTENSIONS_DIR}:" ${BINDIR}/usr/bin/php-config || die # remove all extensions provided by other split-packages local ext for ext in curl bcmath dba gd gmp intl mbstring mysqli mysqlnd \ opcache pdo_mysql pdo sqlite3 pdo_sqlite \ soap sysvmsg sysvsem sysvshm posix xsl wddx dom xmlreader \ xmlwriter xmlrpc json do rm ${BINDIR}/${PHP_EXTENSIONS_DIR}/${ext}.so || die ${ext} done # remove all static extensions too rm ${BINDIR}/${PHP_EXTENSIONS_DIR}/*.a || die # enable all default extensions local MCONFIG local i local phpmod for i in $(ls ${BINDIR}/${PHP_EXTENSIONS_DIR}/*.so | sort ) do phpmod="$(basename ${i} .so)" MCONFIG="/etc/php/conf.d/${phpmod}.ini" mclearconfig || die maddconfig "extension=${phpmod}" || die done # disable config-protect for modules conf dir minstalldir /etc/env.d || die MCONFIG="/etc/env.d/30php" mclearconfig || die maddconfig 'CONFIG_PROTECT_MASK="/etc/php/conf.d"' || die minstalldocs CREDITS CODING_STANDARDS EXTENSIONS LICENSE NEWS README* TODO* || die } src_install_php-cgi() { cd ${BUILDDIR}/build-cgi minstallexec sapi/cgi/php-cgi || die } src_install_php-apache() { cd ${BUILDDIR}/build-apache # install apache sapi local APACHE_MOD_DIR="$(apxs -q LIBEXECDIR)" minstalldir ${APACHE_MOD_DIR} || die minstallexec libs/libphp${PVER%%.*}.so ${APACHE_MOD_DIR} || die # install apache module config local APACHE_SYSCONFDIR="$(apxs -q SYSCONFDIR)" minstalldir ${APACHE_SYSCONFDIR}/modules.d || die minstallfile -s php${PVER%%.*}_module.conf ${APACHE_SYSCONFDIR}/modules.d/php${PVER%%.*}.conf || die } src_install_php-embedded() { cd ${BUILDDIR}/build-embedded # install sapi library minstalldir /usr/$(mlibdir) || die minstallexec libs/libphp${PVER%%.*}.so /usr/$(mlibdir)/libphp${PVER%%.*}.so || die # install include minstalldir /usr/include/${PNAME}/sapi/embed || die minstallfile ${SRCDIR}/sapi/embed/php_embed.h /usr/include/${PNAME}/sapi/embed || die } src_install_php-pear() { cd ${BUILDDIR}/build-pear mmake INSTALL_ROOT=${BINDIR} EXTENSION_DIR=${PHP_EXTENSIONS_DIR} PEAR_INSTALLDIR=${PHP_PEAR_DIR} install-pear || die local i for i in $(find ${BINDIR}/ -name '.*') do if [[ -e ${i} ]] then rm -rf ${i} || die ${i} fi done } #src_install_php-fpm() #{ # cd ${BUILDDIR}/build-fpm # mmake INSTALL_ROOT=${BINDIR} install-fpm || die # # mkeepdir /var/log/php-fpm || die # mkeepdir /run/php-fpm || die # # # config # minstalldir /etc/php || die # minstalldir /etc/php/fpm.conf.d || die # minstallfile -s php-fpm.conf /etc/php/ || die # minstallfile -s php-fpm-www.conf /etc/php/fpm.conf.d/www.conf || die # # # systemd # minstalltmp php-fpm.tmpfilesd php-fpm.conf || die # minstallunit php-fpm.service || die # minstalllog php-fpm.logrotate php-fpm || die # minstallconf php-fpm.confd php-fpm || die #} #src_install_php-phpdbg() #{ # cd ${BUILDDIR}/build-phpdbg # mmake INSTALL_ROOT=${BINDIR} install-phpdbg || die #} # being a little tricky here: for subpackage in ${SPLIT_PACKAGES} do # exclude all other packages than php-addon-modules case ${subpackage} in php) continue ;; php-cgi) continue ;; php-apache) continue ;; php-embedded) continue ;; php-pear) continue ;; php-fpm) continue ;; php-phpdbg) continue ;; esac eval "src_install_${subpackage}(){ install_php_extensions ${subpackage#*-} || die; }" done # exceptions src_install_php-mysql() { install_php_extensions mysqli mysqlnd pdo_mysql || die } #src_install_php-odbc() #{ # install_php_extensions odbc pdo_odbc || die #} src_install_php-process() { install_php_extensions sysvmsg sysvsem sysvshm posix || die } src_install_php-sqlite() { install_php_extensions sqlite3 pdo_sqlite || die } src_install_php-xml() { install_php_extensions dom wddx xmlreader xmlwriter xsl || die }