V
V
Vasily Alibabaevich2013-09-26 06:53:10
linux
Vasily Alibabaevich, 2013-09-26 06:53:10

How to install an rpm package in a specific directory?

Hello!
There was an acute problem - on one server it is necessary to install several versions of PHP. One costs (5.5) and you need to install 5.3 in addition.
There are 5.3 rpms, how can I put them in another directory?
Can anyone provide a good link?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
V
Vasily Alibabaevich, 2013-09-26
@dimitrius86

In short, what I did.
1. Rebuilt rpm with just one line changed: %{!?phpname: %{expand: %%global phpname php53}}
And it was %{!?phpname: %{expand: %%global phpname php}}
2. Installed then compiled packages. Now the new PHP 5.3.8 (or rather the old, but in our case new) will be located in /etc/php53)
3. Since ISPmanager cannot work with 2 versions of PHP, we specify "PHP as CGI" in the properties of the WWW domain
4. The php-bin folder will appear in the home directory. In my case, it is /var/www/php-bin There will be a subfolder with the username, where there will be 2 files:
php
php.ini
In the php file, change the line to the following: #!/usr /bin/php53/php-cgi
In php.iniwe prescribe the necessary parameters (time zone, plug-ins like "ionCube Loader")
That's all.

N
Nikolai Vasilchuk, 2013-09-26
@Anonym

Excuse me, but sometimes it seems to me that Google really bans people.
The first links with working solutions

S
Sild, 2013-09-26
@Sild

So is installing an RPM package critical? Download the sources, unpack, put where you like according to the manual ...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question