Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm trying to compile a lower version of php (5.2) as gentoo is selecting 5.3 and i'm having some coding issues with the new version

nano /etc/portage/package.use

=dev-lang/php-5.2.14 ~amd64

still when I emerge emerge -av php

is stil selecting version 5.3 which is by default

how else can I force emerge to select the version I want

ls /usr/portage/dev-lang/php/ ChangeLog php-5.2.14.ebuild php-5.3.4.ebuild Manifest php-5.2.16.ebuild php-5.3.5.ebuild files/ php-5.2.17.ebuild metadata.xml php-5.3.3-r1.ebuild

share|improve this question
add comment

4 Answers 4

You should find the old ebuild package, it should be in portage directory.

Then, if I remember correctly, the comand to run was "ebuild old-package.ebuild" and it will compile it.

share|improve this answer
add comment

didn't emerge spit an error notification immediately? keyword specifications are supposed to go into /etc/portage/package.keywords.

@comment:

emerge -av =php-5.2.17

if any of them are keyworded, then:

echo "=dev-lang/php-5.2.17 ~amd64" >> /etc/portage/package.keywords
share|improve this answer
    
yes sorry about that, they are in keywords.. –  PartySoft Jan 27 '11 at 15:27
    
emerge doesn't display any error, no –  PartySoft Jan 27 '11 at 15:27
add comment

First, php 5.2.17 already has amd64 in its keywords so ~amd64 would do nothing.

Second, it is almost never a good idea to attempt to mix ~amd64 and amd64 That is why you set ACCEPT_KEYWORDS=~amd64 (or amd64) in /etc/make.conf. It is a per-host variable.

Third, you should use /etc/portage/package.mask like so:

>dev-lang/php-5.2.17

This will prevent all ebuilds with version greater than 5.2.17 to be masked.

Then run emerge -upv --deep --newuse php.

share|improve this answer
add comment

PHP versions are now slotted in Gentoo, so you can have easily either version, or even both at the same time on system and switch between them with eselect. There is a complete guide on the Gentoo home page on how to correctly migrate to slotted PHP versions.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.