[55200] trunk/dports/python/py-xlrd/Portfile

Ryan Schmidt ryandesign at macports.org
Fri Aug 7 16:40:02 PDT 2009


On Aug 7, 2009, at 07:42, snc at macports.org wrote:

> Revision: 55200
>           http://trac.macports.org/changeset/55200
> Author:   snc at macports.org
> Date:     2009-08-07 05:42:28 -0700 (Fri, 07 Aug 2009)
> Log Message:
> -----------
> make into stub package, ticket #20564
>
> Modified Paths:
> --------------
>     trunk/dports/python/py-xlrd/Portfile

[snip]

> +depends_build   port:py25-xlrd

The problem with making the old port depend on the new port like this  
is that anybody upgrading from the old port will encounter an error  
message like this:

$ port upgrade py-xlrd
--->  Fetching py25-xlrd
--->  Attempting to fetch xlrd-0.7.1.zip from http://pypi.python.org/ 
packages/source/x/xlrd/
--->  Verifying checksum(s) for py25-xlrd
--->  Extracting py25-xlrd
--->  Configuring py25-xlrd
--->  Building py25-xlrd
--->  Staging py25-xlrd into destroot
--->  Installing py25-xlrd @0.7.1_0
--->  Activating py25-xlrd @0.7.1_0
Error: Target org.macports.activate returned: Image error: /mp/bin/ 
runxlrd.py is being used by the active py-xlrd port.  Please  
deactivate this port first, or use 'port -f activate py25-xlrd' to  
force the activation.
$

So the old port should not declare a dependency on the new port, but  
should instead just print a message advising the user to install the  
new port. Once MacPorts 1.8.0 is released, the old port can instead  
use the new replaced_by keyword to automate this for the user.





More information about the macports-dev mailing list