SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am still having issues with setting up Apache and PHP.
After many,many,many,many attempts at trying to get libphp5.so created and placed into the right dir I am still not able to load/startup apache after compiling php.
I keep getting the error:
Code:
root@stealth:/usr/local/src/php-5.1.1# /usr/local/apache2/bin/apachectl start
httpd: Syntax error on line 54 of /usr/local/apache2/conf/httpd.conf:
API module structure `php5_module' in file /usr/local/apache2/modules/libphp5.so is garbled -
perhaps this is not an Apache module DSO?
now line 54 reads:
Quote:
LoadModule php5_module modules/libphp5.so
I am running the current release of Apache 2 and PHP 5.1 on Slackware 10. There are NO errors with the compile nor at any other time.
I am that much closer to my goal, and have looked every where that I could to see if there is anything else I can do to no success.
make clean
make clean_dis
./configure --enable-so
make
make install
./configure --prefix=/usr/local/php \
>--with-mysql \
>--with-apxs2=/usr/local/apapche2/bin/apxs
make all
make install
I did the enable-so seperatley because I was having troubles originally with creating the libphp5.so file and AFTER reading the INSTALL help file it directs to do so first and then configure everything else after.
I was able to get Apache running with No error prior to the second configure.
My thought is that it is related to the httpd.conf. (not fully sure - but that is the only link I make)
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
ServerRoot "/usr/local/apache2"
# Dynamic Shared Object (DSO) Support
#
# To be able to use the functionality of a module which was built as a DSO you
# have to place corresponding `LoadModule' lines at this location so the
# directives contained in it are actually available _before_ they are used.
# Statically compiled modules (those listed by `httpd -l') do not need
# to be loaded here.
#
# Example:
# LoadModule foo_module modules/mod_foo.so
#
LoadModule php5_module modules/libphp5.so
<IfModule !mpm_winnt_module>
<IfModule !mpm_netware_module>
#
# If you wish httpd to run as a different user or group, you must run
# httpd as root initially and it will switch.
# ServerName gives the name and port that the server uses to identify itself.
# This can often be determined automatically, but we recommend you specify
# it explicitly to prevent problems during startup.
#
# If your host doesn't have a registered DNS name, enter its IP address here.
#
#ServerName ******:80
#
# DocumentRoot: The directory out of which you will serve your
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
#
DocumentRoot "/usr/local/apache2/htdocs"
#
The only difference I can see in our compiling methods is --enable-so seperately, and you've done "make all", whereas I "make". Have you successfully compiled PHP in the past, meaning an earlier version? I've not messed with 5.1.1, maybe there is something wrong with the source?
I cleaned out the dir and tried to compile a later version. It is interesting I went to 4.4.1 and had no issues with the same error. Now however I am getting a symbol error when starting apache:
Code:
root@stealth:/usr/local/src/php-4.4.1/libs# /usr/local/apache2/bin/apachectl start
httpd: Syntax error on line 54 of /usr/local/apache2/conf/httpd.conf: Cannot load /usr/local/apache2/modules/libphp4.so into server: /usr/local/apache2/modules/libphp4.so: undefined symbol: _emalloc
now I am confident that it is my httpd.conf. However I have no idea what is wrong with line 54. I mean, you have seen the line and the only update made is changing from libphp5 to libphp4, nothing other than that.
Maybe now I might stand a better chance of starting right from scratch, removing Apache, MYSQL and PHP making sure everything is clean and try fresh compiles?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.