Find the answer to your Linux question:
Results 1 to 4 of 4
Hey, I'm trying to install php on my openSUSE server, i have mysql and apache installed which seems to to be working ok but when i try to run the ...
  1. #1
    Just Joined!
    Join Date
    Aug 2008
    Posts
    9

    [SOLVED] PHP installation failing due to zlib error

    Hey,

    I'm trying to install php on my openSUSE server, i have mysql and apache installed which seems to to be working ok but when i try to run the

    ./configure --prefix/usr/local/php --with-mysql=/usr/local/mysql --with-apxs2=/usr/local/apache2

    it ends up failing with:
    Configure: error: Try adding --with-zlib-dir=3D<DIR>. Please check config.log for more information.

    I checked yast, and zlib is installed, i also tried running the install with the --without-zlib command but that didn't help any at all. Anyone who can help?

  2. #2
    Linux Engineer wje_lf's Avatar
    Join Date
    Sep 2007
    Location
    Mariposa
    Posts
    1,192
    I'm not familiar with yast. Will it tell you where the zlib library is installed? You can research that question for yourself (I'm sorry that I don't know the answer) by looking at the yast article in wikipedia.

    If yast won't tell you the directory in which the library exists, you'll have to find it somehow. You'll actually be looking for a symbolic link named libz.so. On my system, for example, that symbolic link will point to libz.so.1.2.3, which is a file by that name in the same directory.

    Let's say, for example, that the directory is /usr/lib. Then say something like this:
    Code:
    ./configure --with-zlib-dir=/usr/lib
    I have no idea how that 3D got there. Don't use it.

    Hope this helps.
    --
    Bill

    Old age and treachery will overcome youth and skill.

  3. #3
    Just Joined!
    Join Date
    Aug 2008
    Posts
    9
    Okay i'll have a look, my problem is that i don't have any clue where to find the zlib or i would have tried that command or parameter, but i'll check out the wiki.

    And then i won't use the 3D when i find it ^^
    I'll let you know how it turns out.

    Thanks

  4. #4
    Just Joined!
    Join Date
    Aug 2008
    Posts
    9
    That did the trick.

    I found the zlib.so in /usr/lib, which i think is the standard location but apparently the configure didn't agree, it worked however when i used the
    Code:
    --with-zlib-dir=/usr/lib
    Just after that i ran into another problem though where i was prompted with
    Code:
    configure: error: mysql configure failed
    This can be fixed in somewhat the same way though by adding dir to the code like so:
    Code:
    --with-mysql-dir=/usr/local/mysql
    And then... finally! i got the "thank you for using PHP" woohoo
    Thanks for the help

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...