Listing leaves on the installed ports dependency graph

Sam Kuper sam.kuper at uclmail.net
Wed Feb 17 12:57:47 PST 2010


Dear all,

I want to obtain a list of all the installed ports which have no dependents,
so that I can keep the ones I need and uninstall the rest. I'm trying to do
this via the following command:

port installed | sed 's/ (active)//g' | xargs -0 port dependents

However, this isn't working quite as expected. Instead of getting results
like, "aalib has no dependents!", I instead get the following:

Error: Registry error: The following ports are currently installed:
  aalib  1.4rc5_4
  apache-ant @1.7.1_0
  apr @1.3.3_1
  apr @1.3.12_0
  apr @1.3.12_1
  apr-util @1.3.4_1
  apr-util @1.3.9_2
  atk @1.26.0_1
  audiofile @0.2.6_2
  autoconf @2.63_0
  autoconf @2.65_1
  automake @1.10.2_0
  automake @1.11_0
  automake @1.11.1_0
  babl @0.0.22_0
  babl @0.1.0_1
  bash-completion @1.0_1
  bash-completion @1.1_4
  bison @2.4.1_0
  boehmgc @7.1_0+darwin_9 not registered as installed.


I realise my xargs knowledge isn't great and I've probably messed up
somewhere in my command syntax, but I'd be grateful for help, either
correcting my syntax or - if possible - letting me know a native MacPorts
command which does the same job.

Many thanks in advance,

Sam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-users/attachments/20100217/bac019d3/attachment.html>


More information about the macports-users mailing list