my PHP is not working

after compiling PHP on slackware, i can not start APACHE
i get the following error

/usr/local/apache2# bin/apachectl restart
httpd: Syntax error on line 231 of /usr/local/apache2/conf/httpd.conf:
Cannot load /usr/local/apache2/modules/ into server:
/usr/local/apache2/modules/ undefined symbol: ap_signal

what should i do?

i m using php-4.4.2 and httpd-2.1.3-beta

as you can see LoadModule line is uncomment, when i put a comment apache start but php is not working

# Example:
# LoadModule foo_module modules/
LoadModule php4_module        modules/

# ExtendedStatus controls whether Apache will generate "full" status
# information (ExtendedStatus On) or just basic information (ExtendedStatus
# Off) when the "server-status" handler is called. The default is Off.
#ExtendedStatus On
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Brian BushSolutions ArchitectCommented:
Could you post the configure options that you used to build PHP?

247RealMediaAuthor Commented:

Here are the options that i use to build php.

I am using apache2
and php-4.4.2

./configure --prefix=/usr/local --with-apache2=/usr/local
 --enable-cli --enable-cgi --enable-fastcgi --enable-debug
 --enable-libgcc --enable-zlib --enable-odbc --enable-pear
--with-gd=/usr/local --with-freetype-dir=/usr/local
--enable-png --with-snmp=/usr/local --enable-sockets

Thank you
Brian BushSolutions ArchitectCommented:
Unless you have some reason not to build PHP as a module,
you should use the apxs flag instead of apache2:

Try that and let me know if you get the same error.
Cloud Class® Course: Certified Penetration Testing

This CPTE Certified Penetration Testing Engineer course covers everything you need to know about becoming a Certified Penetration Testing Engineer. Career Path: Professional roles include Ethical Hackers, Security Consultants, System Administrators, and Chief Security Officers.

247RealMediaAuthor Commented:
I also tried to compile it with

I am still having the same error.

Please help

Thank you
Brian BushSolutions ArchitectCommented:
Sorry to keep telling you to rebuild, I know
these sorts of things are frustrating.

Persistence is the only way to get through it.
Apache 2.2.0 is out as a release version:

I would suggest that you get it and shy
away from the "beta" versions, if possible.

Be sure to build apache with:
configure --enable-so

Regardless of whether or not you are able
to do that, the next thing to do is build php
with nothing but this:
configure --with-apxs2=/usr/local/apache2/bin/apxs

Then see if it will start up. If not, we have
bigger problems.

Let me know.
247RealMediaAuthor Commented:
I will like to configure PHP to work with Just for Fun Network Management System.

if i configure PHP with just --with-apxs2=/usr/local/apche2/bin/apxs
Just for Fun Network Management System will not work.

Just for Fun Network Management System needs PEAR, GD2,SNMP, CGI,CLI,ODBC

Please help

Thank you
Brian BushSolutions ArchitectCommented:
I understand, but you need to start with this to make sure it will work.
Then you can add options to troubleshoot the problems. It is often
tied to an extension or library.

247RealMediaAuthor Commented:
I'm using httpd-2.2.0

I'm getting the following error now:

usr/local/apache2# bin/apachectl start
httpd: Syntax error on line 414 of /usr/local/apache2/conf/httpd.conf: Cannot load /usr/local/apa                     che2/libexec/ into server: /usr/local/apache2/libexec/ cannot open shared ob                     ject file: No such file or directory

This is what is in line 214:

LoadModule php5_module libexec/

Please help

Thank you
247RealMediaAuthor Commented:
php5 works after some tweaks:

How do i enable: GD, SNMP, CLI,LIB, PNG, CIG, ODBC within PHP
without an other compile

Brian BushSolutions ArchitectCommented:
Pretty sure you have to rebuild on *nix systems.

I am guessing the debug flag was your problem.
Unless you are testing the PHP app itself as part
of the development team, you don't want to enable
that one.

There are also a few other things I would change in the
configure script. CGI and CLI are defaults, so drop them.
I also use --with-png-dir instead of --enable-png. You also
need to add a --with-zlib-dir for the PNG support.

Try this configure script:
./configure \
--enable-fastcgi \
--enable-libgcc \
--enable-odbc \
--enable-sockets \
--with-gd \
--with-zlib \
--with-png-dir \
--with-zlib-dir \
--with-snmp=/usr/local \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-freetype-dir=/usr/local \

That should be all you need to do everything you wanted in PHP5.
Sorry this takes so long. Get me access to your box and I can fix it quick ;)
Just kidding.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.