Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Custom configure flags on PHP

Discussion in 'General Discussion' started by gnif, Jun 21, 2007.

  1. gnif

    gnif Member

    Mar 25, 2007
    Likes Received:
    Trophy Points:
    I have been fighting with cPanel for the past 4 hours trying to get unixODBC support into PHP. What a nightmare, VERY un-impressed that it is not an option in easyapache.

    Anyway, through some deductive work I have managed to find what seems to be an un-documented environment variable that can be used to set custom flags, perfect for what I need.

    export CUSOTM_PHP_FLAGS="--with-unixODBC=/usr/lib/"
    Just thought I would let people know.
  2. Spiral

    Spiral BANNED

    Jun 24, 2005
    Likes Received:
    Trophy Points:
    Why in the world are you using EasyApache to compile PHP? :confused:

    EasyApache completely screws up PHP installations even in the newest EasyApache3
    and I wouldn't recommend using it for any but the most basic of PHP installations
    and even then I would still be a bit leary about using EasyApache for PHP installations.

    To Cpanel's credit, they have improved things quite a bit in terms of Apache compiling with
    the newest EasyApache but it still sucks, for lack of a better word, where PHP is concerned
    and I would recommend people only use EasyApache for Apache compiling alone and
    choose "No PHP" as the option when running EasyApache.

    For your PHP setup, it is actually much easier and far more reliable to just manually
    compile PHP yourself from source downloaded from ...

    cd /usr/local/src
    tar zxvf php-5.2.3.tar.gz
    cd php-5.2.3
    ./configure (whatever options you want go here)
    make test
    make install
    If you are unsure what options to put in the "./configure" command,
    just take a look at your current phpinfo() screen.

    (Same basic steps for any other version of PHP)

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice