Re: Compiling PHP Source guides

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





Greg Donald wrote:

On Wed, 22 Dec 2004 13:56:39 -0800, Donald Tyler <dtyler@xxxxxxxxxxxxxx> wrote:


I do have a rudimentary knowledge of *nix stuff



I don't mean to offend, but it doesn't really seem so. Basic *nix skills usually include knowing how to configure, compile, and install software from source. The PHP docs explain in very explicit detail how to do it, and I have to say you won't find any more hand holding than you get with PHP documentation. The 'F' in RTFM really means 'Fine' when used in a PHP context.



and am very computer
literate, but most of the programming I have done is with scripting
languages such as Actionscript, Javascript, PHP etc. I realy have no
idea about compiling source code.



If your download is still compressed you need to uncompress it. Depending on the download's file extension you will need to use one of
these commands:


tar zxvf php-4.3.10.tar.gz
tar jxvf php-4.3.10.tar.bz2


Then you change to the source directory:

cd php-4.3.10/

Then you configure the source:

./configure

You will need to add your desired compile options in the ./configure
command.  I have no idea what support you want to build into your PHP.
If you don't either you might look at:

./configure --help

Then after you're done with the configure, you compile the software:

make

Then you probably want to install the software permanently to a
system-wide location (or you might not, I don't know).  On *nix the
usual install locations are somewhere like /usr or /usr/local, which
can be defined in the configure with --prefix if you don't want the
default location.  So then to do the actual install you would do:

make install

Then your php binary will be /usr/bin/php or /usr/local/bin/php.

There's also the configure option to build your PHP as a module for
use with a web server such as Apache.  For that you might use a
configure command something like:

./configure --enable-module=so --with-apxs=/usr/sbin/apxs



I was just hoping for something in laymans terms I guess...



I would guess it's hard to talk about heart surgery without talking about heart surgery. Same goes for compiling software. The commands are pretty explicit and you have to know what your doing to get the desired results. It's no disgrace to not know, once upon a time I didn't know.. but I read lots of docs, and I asked many questions and I learned. I got a few flames along the way but that's part of knowing *nix I guess. :)

Several companies I've worked for in the past have brought in outside
consultants when something would come up that we didn't have skills
for in-house.  On that note, you might consider talking with a
consultant or even getting them to do your PHP install for you if in
the end you give up and cannot figure it out.  Make them document the
process as part of the deal.



Thanks for your responses.

Wish me luck.



Good luck.





Thanks for the info.

I do understand that *nix usage generaly relies on a lot of compiling software, but I have been relying on pre-compiled RPMs so far. I am by no means an expert, or even intermediate *nix user, which is why I used the term "rudimentary".

I have been running 6 Linux servers for a small company for about a year now learning as I go. I knew nothing about *nix when I started and considering most of my other responsibilities leave very little time to learn and experiment on the Linux systems I dont think I've done too badly.

P.S. You didnt offend me, I just wanted to explain my situation.

Thanks again for the help.

Donald Tyler

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux