deinstall ports

Dominic Marks dom at helenmarks.co.uk
Mon Jun 18 14:15:49 UTC 2007


Vladislav Storojenco wrote:
> Hello all,
> I'm new user in FreeBSD and have a question about
> ports..
> If a port is depend on others ports, during the
> deinstall it will deinstall and all dependencies?

It depends on what command you issue.  If you try and remove an installed
package which had other packages dependent upon it, then it will fail.

# pkg_delete /var/db/pkg/apache-2.2.4_2/
pkg_delete: package 'apache-2.2.4_2' is required by these other packages
and may not be deinstalled:
php5-5.2.1_3
php5-mysql-5.2.1_3
php5-pcre-5.2.1_5
php5-posix-5.2.1_3
php5-session-5.2.1_3
php5-simplexml-5.2.1_3
...

But you could force it by using `pkg_delete -f` if you wanted.  This on
its own will not remove the dependancies, you need to use `pkg_delete -rf`
for that.

If you run `make deinstall` from the port directory you get the same
result as having used `pkg_delete -f` (but not -rf).

Dominic



More information about the freebsd-stable mailing list