Find the answer to your Linux question:
Results 1 to 3 of 3

Thread: Recompile PHP

Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Recompile PHP


    I recently installed Apache, PHP and MySQL from Suse Linux 9.3 Professional CD but I found PHP was compiled with '--disable-session'

    When I try to login to a page I get this error:
    Fatal error: Call to undefined function: session_start() in /srv/www/htdocs/login.php on line 35

    Now I think I have to recompile PHP with '--enable-session' but I have no idea how to do that. Can anyone help me with this please?

  2. #2
    Once I had to compile PHP with oci8 and freetds support, which is not available as an extension on SuSE cd's and I had to compile it from sources. So I gave up an idea of installing php and apache from SuSE CD's. I would recommend download sources from and and configure them the way you want.
    ./configure --with-prefix=/www
    make install
    ./configure --with-apxs2=/www/bin/apxs --enable-session
    make install
    in httpd.conf add 2 lines to load php module and add php mime type
    LoadModule php5_module        modules/
    AddType application/x-httpd-php .php .phtml

  3. #3
    Actually I tried that before installing from CD but installing MySQL is extra pain for me. But now I'll give it another try. Thanks for your reply.

  4. $spacer_open

Posting Permissions

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