Help with How to compile php

Discussion in 'Installation/Configuration' started by mike_phi, Jan 4, 2009.

  1. mike_phi

    mike_phi New Member

    This thread is related to

    http://www.howtoforge.com/forums/showthread.php?t=29865

    and

    http://www.howtoforge.com/forums/showthread.php?t=29973

    I thought I would post a seperate thread as this is specific to recompiling ISPConfig php.

    this applies to a addon for ispconfig which runs on port 81 that require Zlib support, I need some tips on handeling the ISPConfig php.



    Please correct me where I am wrong but do I follow the following procedures

    have a look at install_ispconfig/compile_apps/compile script, noting the following

    cd ../${PHP}
    ./configure --with-apxs=${INSTALL_ROOT}/httpd/bin/apxs --enable-track-vars --enable-sockets --enable-mbstring=all --with-config-file-path=${INSTALL_ROOT}/php --enable-ftp --prefix=${INSTALL_ROOT}/php ${WITH_OPENSSL} ${WITH_MYSQL} --disable-libxml --disable-dom --disable-xml ${WITH_ZLIB_DIR} --disable-xmlreader --disable-xmlwriter --disable-simplexml --without-pear || error "Could not configure PHP"

    with the above configure option in mind and considering that I already have ispconfig previously installed all I want to do is update the existing ISPConfig php with zlib support.

    I then unzip the ISPConfig-2.2.21.tar.gz file

    then unzip the php-5.2.5.tar.gz
    then cd into the php-5.2.5 directory
    then run the configure script here with the above listed options just incliding
    --with-zlib. if I do this then the only changes that occur are local to the php-5.2.5 directory i.e. will not impact either the origional ISpconfig PHP orthe php installed on the Os.

    i.e.
    note I have replaced ${INSTALL_ROOT} with the absolute path "/root/ispconfig"

    $ cd php-5.2.5
    $/php-5.2.5/configure --with-apxs=/root/ispconfig/httpd/bin/apxs --with-zlib --enable-track-vars --enable-sockets --enable-mbstring=all --with-config-file-path=/root/ispconfig/php --enable-ftp --prefix=/root/ispconfig/php ${WITH_OPENSSL} ${WITH_MYSQL} --disable-libxml --disable-dom --disable-xml ${WITH_ZLIB_DIR} --disable-xmlreader --disable-xmlwriter --disable-simplexml --without-pear || error "Could not configure PHP"

    Quetion about the configure script can I just run it at the command line within the phpdirectory or should I edit the install_ispconfig/compile_apps/compile script and run that

    if I run install_ispconfig/compile_apps/compile will it affect my origional ISPConfig installation or wil it just compile everything.

    is there a way to just compile php

    then what do

    Do I copy $/php-5.2.5/php/lib/php/build to /root/ispconfig/php/lib/php/build
    or do I copy the entire $/php-5.2.5/php to /root/ispconfig/php just backup and copy my origional php.ini file (hence maintaining all my origional php configuration)


    Note I would like my origional ISPConfig setup to remain uniterupted other than updating the PHP.

    with regard to th php.ini the only settings are

    zlib.output_compression = On

    do I need to do anything with else with

    ;output_handler =
    or
    ;zlib.outputhandler =


    Looking forward to your reply

    cheers Mic
     
    Last edited: Jan 4, 2009
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Just add "--with-zlib" to the configure string and then run the "setup§ script.
     

Share This Page