Need an easy to follow php install guide for unix

Started by Onsite, December 24, 2004, 12:11:12 AM

Previous topic - Next topic

Onsite

I lease a few Verio servers and I want to upgrade php on them.
They have default install scripts, but I can't compile anything different using them.
For example I need to compile pspell during the install.

I've looked over the php.net documentation, but it's a bit beyond my skill level.
Do any of you know of a newbie level guide to compiling and installing?
My format will need to be:
Unix
FreeBSD
Apache

Thanks

[Unknown]

Well, I don't, but the basic idea is:

# wget http://url/to/file.tar.gz
# tar xvzf file.tar.gz
# cd file

At which point you'll have the file directory extracted.  The next step is configure - if you look at a phpinfo, you'll see your configure line.  An example is:

# './configure' '--with-apxs=/usr/local/apache/bin/apxs' '--with-xml' '--enable-bcmath' '--enable-calendar' '--with-curl' '--enable-ftp' '--with-gd' '--with-jpeg-dir=/usr/local' '--with-png-dir=/usr' '--with-xpm-dir=/usr/X11R6' '--enable-magic-quotes' '--with-mysql=/usr' '--with-openssl' '--enable-discard-path' '--with-pear' '--with-pspell' '--enable-sockets' '--enable-track-vars' '--with-ttf' '--with-freetype-dir=/usr' '--enable-gd-native-ttf' '--enable-versioning' '--with-xmlrpc' '--with-zlib'

Just an example.  You may want to copy yours, and add at the end "--with-pspell" (and/or any other options.)  Then, you want to make it, like so:

# make

After that, it's time to install.  Installation has to be done as root... so:

# su
# make install

You also want to restart Apache.  There are a few ways to do this depending on your server, so I'll list them:

# apachectl graceful
# /etc/init.d/httpd graceful
# httpd graceful
# apache2 graceful
# /etc/init.d/apache2 graceful

Then we exit as root:

# exit

And just for safety, maybe check the error log:

# tail /var/log/messages

-[Unknown]

kdizzle

I know this is an old post but ....[Unknown] you have the knowledge I need.

I have this http://apbio.ohs.oside.k12.ca.us/testspell.php for php info.

Since I have php compiled currently how do I recompile it with --with-pspell ?

Do I download the source from the dvd I installed it from?  (Suse 9.3)
or
Do I get php4.4 from the web and use my same old configure settings.
or
Ignore my questions and explain in small words how I would recompile php over an existing php install?

Thank you.



[Unknown]

I would just download the source from php.net.  I don't think any distros modify PHP.

-[Unknown]

kdizzle

I do not have a compiler in my SUSE distro because it is rpm based. 

I get the following error when I try to compile:

loading cache ./config.cache
checking host system type... x86_64-suse-linux-gnu
checking for gcc... no
checking for cc... no
configure: error: no acceptable cc found in $PATH

If you have time for a quick reply I would really appreciate it.

I have the rpm on the install dvd but not the source.


kdizzle

#6
I used yast and intatlled gcc then I ran the configure with my php.ifo output and now it says that it cannot find the path to apsx?

This is the output from the php.info:
'./configure' '--prefix=/usr' '--datadir=/usr/share/php' '--mandir=/usr/share/man' '--bindir=/usr/bin' '--libdir=/usr/share' '--includedir=/usr/include' '--sysconfdir=/etc' '--with-_lib=lib64' '--with-config-file-path=/etc' '--with-exec-dir=/usr/lib64/php/bin' '--disable-debug' '--enable-inline-optimization' '--enable-memory-limit' '--enable-magic-quotes' '--enable-safe-mode' '--enable-sigchild' '--disable-ctype' '--disable-session' '--without-mysql' '--disable-cli' '--without-pear' '--with-openssl' '--with-apxs2=/usr/sbin/apxs2-prefork' 'x86_64-suse-linux'

What is weird is that there is no apsx2-prefork in /usr/sbin ?

Thank you for your help I think this seems like alot of trouble,  I think I must be doing it wrong.

[Unknown]

So I assume you installed the RPMs for everything, huh?

You may need apache2-devel.  Do you have slocate? (the locate command...)

-[Unknown]

Advertisement: