Recompiling PHP - Fedora 4
Posted 08 July 2006 - 01:47 PM
I have a new server with a fresh install of Fedora Core 4. I need the use of mysql extensions but the original php build has been compiled with these extensions off.
I understand that I need to recompile php on the server but am having problems finding information on this on the web.
I do of course have the instalation instructions for php but am unsure of what I need to do in preparation.
Can anyone give me a quick step by step, I'm not sure if I have the binaries either. I have some knowledge of Linux environments but am by no means an expert.
Posted 08 July 2006 - 02:07 PM
That way you can do it via a GUI...although you would learn more if you did it by hand in which case you would find this thread very useful:
Call To Undefinded Function mysql_connect
Posted 08 July 2006 - 02:22 PM
Unfortunately at present I only have ssh access to the server so CLI only pls.
Posted 08 July 2006 - 07:37 PM
You should have tried google
PHP4 on Fedora Core 4
Fedora Core 4 Linux Installation Notes: Yum
some of those steps require super user permissions...but if you have the ability to edit ~/.bashrc you should be able to install all these programs in your home directory where you should have absolute access.
Section 1.2 should help you on my wiki
but really, you would save yourself some time if you attempted the suggestions in the link i posted previously. or maybe you already attempted them, but you haven't told me if you have and my jedi powers haven't developed to a level where i can read minds...yet
Posted 10 July 2006 - 06:48 PM
Yes thanks yum is indeed cli and a wonderful little bit if kit, however it doesn't allow me to configure the instalation (as far as I know) and as php5 is installed by default with mysql off, it hasn't helped me directly.
I did soldier on and do a full compile of php5 with the options i need. Everything seemed to go ok in the build but when I restarted apache, I have no php support.
Removing php and replacing it via yum works fine but of course I still can't use mysql, is it possible to configure yum install to do a non standard instalation?
Am still fiddling with it, any advice greatly appreciated.
Posted 10 July 2006 - 07:18 PM
No worries have resolve the issue.
very very simple:
$yum remove php
$yum install php-mysql
Is amazing I spent 3-4 hours on that yesterday! Just goes to show a little knowledge goes a long way. Thanks for the replies anyway!
Posted 11 July 2006 - 05:31 PM
And completely without sarcastic replies, amazing
haha apart from that post, i suspect
package managers are wonderful things.
i'm guessing you have no say in what OS to choose. i generally avoid RPM based distros like RedHat, Fedora, SuSE, etc.
i love anything based on apt (debian, ubuntu, etc), or ports (gentoo, FreeBSD, etc) because they are very easy to manage.
Posted 11 July 2006 - 05:49 PM
When you say easier to manage do you mean more hands on, or more hands off.
I love the control of being able to compile to order however this is not fun when you come home drunk or something. A good balance and choice is what I would go for, any recommendations?
Posted 11 July 2006 - 06:10 PM
basically, apt and emerge check for dependencies. for example, if you install something like vim editor, you will need some ncurses libraries and emerge and apt will tell you that you need those libraries when you attempt to install vim and if you allow it to, it will even satisfy those dependenceis for you which is awesome if you're pressed for time.
i prefer compiling from source to using RPM's.
most...or at least a good make file (in a source installation) will let you do this:
make check(which is the step after you 'make' and before you 'make install') which will inform you of dependencies.
generally, compiling from source consists of the following commands:
$ cd /path/to/source $ ./configure --with-myOption --with-otherOptions --with-moreOptions $ make $ make check #optional but recommended $ make install
you would need super user status (su or sudo, depending on the distro) for 'make install' if you're installing the program on the entire system.
Posted 11 July 2006 - 08:12 PM
I am still trying to decide on a home linux distro tho and that's been helpfull.
I am quite familiar with makefiles though as I am used to working at a much lower level.
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users