1

I've been trying to compile x11/gnome2 under FreeBSD 10.0-REL, but have been running into all sorts of issues. Eventually I found things indicating that gnome2 is no longer really supported, and that I should use something else (MATE, Xfce, KDE, whatever) instead.

But gnome2 installs a trillion other packages, none of which I actually want if I'm not going to be using Gnome. So "make install" of gnome2 has failed, but not before installing a few billion packages that I don't want. I'd like to get rid of them before starting an install of Xfce or whatever.

How can I easily delete those that aren't needed by anything that doesn't ultimately go back go the gnome2 package? So, in a perfect world I'd like a command that says:

"Figure out all packages that are supposed to be installed via gnome2 (including recursively). For each such package, if it is installed, uninstall it unless there is some installed package that needs it and that is not among those installed via gnome2 (including recursively)."

Is there an easy way to do this?

Thanks in advance.

  • Alternatively, I currently have very few packages that I explicitly want installed (though many that I need because of those very few). Is there a way to say, for example, "deinstall anything that is not needed by apache24, subversion, or viewvc"? – Bob Vesterman Sep 29 '14 at 21:17
0

FreeBSD 10 comes with pkg utility that allows you to do exactly that:

pkg autoremove

See pkg help for the full list of pkg commands.

You probably will need to clean the port after failed build as well.
You can do it this way:

cd /usr/ports/x11/gnome2
make clean

About your second question: yes, there is a way. You should delete packages that require these dependencies and then execute pkg autoremove, it will do the rest.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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