PHP 5.3.x and Ubuntu 11.04

Discussion in 'PHP' started by tininho, May 27, 2011.

  1. tininho

    tininho New Member

    I was trying to build PHP 5.3.4 through the admin panel while I got the following error:
    Code:
    checking for the location of libjpeg... no
    checking for the location of libpng... no
    checking for the location of libXpm... no
    checking for FreeType 2... no
    checking for T1lib support... no
    checking whether to enable truetype string function in GD... no
    checking whether to enable JIS-mapped Japanese font support in GD... no
    checking for fabsf... yes
    checking for floorf... yes
    If configure fails try --with-jpeg-dir=<DIR>
    configure: error: libpng.(a|so) not found.
    **ERROR** Could not configure PHP build
    (ADDED: So obviously I had the libraries and they just didn't work)

    My solution to the problem was to create symlinks for both libjpeg.so and libpng.so to the /usr/lib directory.

    In summary, here are the 2 simlinks that were required when building PHP on Ubuntu 11.04 64bit:

    ln -s /usr/lib/x86_64-linux-gnu/libjpeg.so /usr/lib/libjpeg.so
    ln -s /usr/lib/x86_64-linux-gnu/libpng.so /usr/lib/libpng.so
    Last edited: May 27, 2011
  2. webizen

    webizen New Member

  3. tininho

    tininho New Member

    Yeah, well that was already done. The problem lies in new locations of the libraries and a bug in earlier version of ROOT (http://goo.gl/jaEx2) so it is not possible for the system to find automatically the libraries even if they were installed (like in my case, at least so I understood).

    The problem is known (http://goo.gl/FJDmF)

    Another problem is the fact that the new version of ROOT is not easily accessible for 64-bit users ATM of Ubuntu 11.04. (http://goo.gl/iYDkt)

    Hence this work around. Thanks for those links, though.

Share This Page