Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to install py25-py2app-devel on a Mac 10.5.8 Darwin 9.8.0 because it's required to py25-matplotlib. Using porticus I receive this error:

Error: Target org.macports.destroot returned: xinstall: Cannot stat: NEWS.txt, No such file or directory Error: Status 1 encountered during processing.

Any idea to fix it ?


share|improve this question


This error indicates that MacPorts successfully fetched the py25-py2app-devel source but was unable to install it (unable to execute its “destroot” stage, technically) because it was unable to find and move a file called NEWS.txt. A quick look at the py2app source tree reveals that NEWS.txt is indeed gone, although the port still tries to install it—see line 38 in the latest Portfile. (Portfiles are the instructions for building and installing MacPorts software.)

Short-term fix

  1. Make sure you have the latest version of the MacPorts core software and ports tree. This is almost always a good idea. Do this by opening Terminal and running the following command:

    sudo port selfupdate
  2. Clean out all temporary work/build files left over from your unsuccessful install by running

    sudo port clean --all py25-py2app-devel

    This ensures that MacPorts starts from a clean slate the next time you try to install the port.

  3. Remove the reference to NEWS.txt in the py25-py2app-devel Portfile so that it doesn’t try to install NEWS.txt anymore; the file is located at $(port dir py25-py2app-devel)/Portfile. A quick way to do this is by running

    sudo sed -i '' '38s/NEWS.txt//' $(port dir py25-py2app-devel)/Portfile

    This command removes the text “NEWS.txt” from line 38 of the Portfile for py25-py2app-devel. This is the only reference to NEWS.txt in the Portfile.

  4. Try installing again:

    sudo port install py25-py2app-devel

    The port should install correctly this time, unless some other unforeseen problem crops up. At the very least, you shouldn’t have the NEWS.txt problem again.

Long-term fix

While this should work for you, updating your tree again with port selfupdate will overwrite your local changes with the incorrect Portfile from MacPorts. (This won't break your installation, but it means reinstalling later will fail, unless someone else patches it on MacPorts’s end.) If the fix above does work, let me know and I can submit a patch. Or you can do it yourself, if you’re feeling adventurous. :)

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .