#26039: php5: add fpm support --------------------------------+------------------------------------------- Reporter: info@… | Owner: ryandesign@… Type: enhancement | Status: new Priority: Normal | Milestone: Component: ports | Version: Keywords: haspatch | Port: php5 --------------------------------+------------------------------------------- Comment(by ryandesign@…): The attached doesn't work for all combinations of variants, for example: {{{ sudo port install +fastcgi +fpm ---> Computing dependencies for php5 ---> Fetching php5 ---> Verifying checksum(s) for php5 ---> Extracting php5 ---> Applying patches to php5 ---> Configuring php5 ---> Building php5 ---> Staging php5 into destroot Error: Target org.macports.destroot returned: xinstall: Cannot stat: /opt/local/var/macports/build/_Users_rschmidt_macports_dports_lang_php5/work/php-5.3.5/sapi/cgi /php-cgi, No such file or directory }}} The way the proposed patch handles the fpm config file is also not correct. The correct handling is how the port already handles the php.ini: it installs a sample configuration file, and advises the user where it is and that they should copy it if they want to use it. I've attached a slightly updated patch which corrects the handling of the config file, and changes some of the comments to mirror those of the FastCGI sections. I had wanted to wait on adding FPM support until I had separated each SAPI into its own port; see #19091. However Andy [http://bugs.php.net/bug.php?id=52419 pointed out] in his patch that PHP 5.4 will be able to properly build all SAPIs simultaneously. So maybe we keep all the SAPIs in one port after all, and just deal with the unpleasantness of multiple sequential builds until 5.4 is out. I fear there may need to be a drastic overhaul of how I do this, though, because I'm not happy with how each SAPI's options are basically specified twice in the portfile, and which version of the instructions is used depends on whether it is the only SAPI or not. I noticed the patch copies php-fpm into ${prefix}/sbin, whereas the FastCGI binary is copied into ${prefix}/bin. I imagine they should both be in the same directory, though not certain which directory it should be. sbin seems like the correct choice, but that would mean users using fastcgi would need to change their setups. :/ -- Ticket URL: <https://trac.macports.org/ticket/26039#comment:10> MacPorts <http://www.macports.org/> Ports system for Mac OS