Using portmaster with different PYTHON_VERSION

Doug Barton dougb at
Tue Sep 28 20:57:24 UTC 2010

On 9/28/2010 11:30 AM, Dmitry Pryanishnikov wrote:
> Hello!
>    I'm trying to install Python additional ports (e.g. www/py-httplib2)
> for different Python versions (2.6 and 3.1) in the same system using
> the portmaster. Those packages (py26-httplib2 vs py31-httplib2) do not
> conflict (they may be used simultaneously, don't overwrite each
> other's files etc.). But they have single origin, which seems to
> confuse the portmaster:
> PYTHON_VERSION=python2.6 portmaster www/py-httplib2
> ...
> ===>>>  Installation of www/py-httplib2 (py26-httplib2-0.6.0) complete
> Then
> PYTHON_VERSION=python3.1 portmaster www/py-httplib2
> ...
> ===>>>  Upgrade of py26-httplib2-0.6.0 to py31-httplib2-0.6.0 complete
> So portmaster thinks that it's an upgrade, and removes py26-httplib2,
> which is not correct - I want to keep both packages:
> py26-httplib2-0.6.0 A comprehensive HTTP client library
> py31-httplib2-0.6.0 A comprehensive HTTP client library
> Am I missing some portmaster's tunable, or it just doesn't support
> such ports yet?

You're not missing anything. Portmaster's assumption is that $ORIGIN is 
always unique.

I would also argue that there is a fundamental assumption in the ports 
infrastructure that what you're doing here (installing both versions on 
the same system) is not supported. The ability to make the version of 
things like python or perl variable is a great feature of the ports 
infrastructure, but my understanding has always been that this would be 
a system-wide option, and that installing different versions of the same 
language on the same system is not supported.

That said, assuming that the 2 ports create different /var/db/pkg 
directories, and do not install files into the same location, you could 
use portmaster's -g option for the first install, then re-install the 
package after installing the second port. Or you could just not use 
portmaster for the second one.




	... and that's just a little bit of history repeating.
			-- Propellerheads

	Improve the effectiveness of your Internet presence with
	a domain name makeover!

More information about the freebsd-ports mailing list