Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
PKG_DEINSTALL(1)	    General Commands Manual	      PKG_DEINSTALL(1)

NAME
       pkg_deinstall  --  a  package deinstaller with wildcards	and dependency
       recursion support

SYNOPSIS
       pkg_deinstall   [-hacdDfinOPqrRv]   [-p	 prefix]   [-x	 pkgname_glob]
		     [pkgname_glob ...]

DESCRIPTION
       The  pkg_deinstall  command is a	wrapper	of pkg_delete(1) used to dein-
       stall packages, which understands wildcards and is capable of recursing
       through dependencies.

       Before  reading	these  instructions,  you  must	 understand   that   a
       port/package  can  have	the following two types	of related ports/pack-
       ages:
       required	  Ports/packages that a	port/package needs for it to be	 built
		  and/or   run.	   Port	  Makefiles  refer  to	this  type  of
		  ports/packages  using	 the  BUILD_DEPENDS  and   RUN_DEPENDS
		  macros, respectively.
       dependent  Ports/packages that need this	port/package.

OPTIONS
       The following command line arguments are	supported.  The	options	marked
       as `[*]'	are transparently passed to pkg_delete(1).

       pkgname_glob	   Specify  one	 of  these:  a full pkgname, a pkgname
			   without version, a shell glob pattern in which  you
			   can use wildcards `*', `?', and `[..]', an extended
			   regular  expression	preceded  by a colon `:', or a
			   date	range specification preceded by	either `<'  or
			   `>'.	  See pkg_glob(1) for details and concrete ex-
			   amples.

       -h
       --help		   Show	help and exit.

       -a
       --all		   Deinstall all the installed	packages.   Equivalent
			   to specify '*' as pkgname_glob.

       -c
       --collate	   For	each  package,	check  if any of the files in-
			   stalled by the package has been overwritten by oth-
			   ers.	 If any, list them and abort  the  deinstalla-
			   tion	 of  the  package.  This option	is disabled by
			   the -f option.

       -d
       --rmdir		   Remove empty	directories created by	file  cleanup.
			   By	default,   only	 files/directories  explicitly
			   listed in a package's contents  (either  as	normal
			   files/directories  or  with	the  @dirrm directive)
			   will	be removed at deinstallation time.   This  op-
			   tion	 tells pkg_deinstall to	also remove any	direc-
			   tories that were emptied as a  result  of  removing
			   the package.	[*]

       -D
       --noscripts	   If a	deinstallation script exists for a given pack-
			   age,	do not execute it. [*]

       -f
       --force		   Force  removal of the package, even if a dependency
			   is recorded or  the	deinstall  or  require	script
			   fails. [*]

       -i
       --interactive	   Request  confirmation  before  attempting to	delete
			   each	package, regardless whether or not  the	 stan-
			   dard	input device is	a terminal.

       -n
       --noexecute	   Do  not  actually  deinstall	a package, just	report
			   the steps that would	be taken if it were. [*]

       -O
       --omit-check	   Omit	sanity checks for dependencies.	  By  default,
			   pkg_deinstall  checks  if all the packages to dein-
			   stall have consistent dependencies, though it takes
			   extra time to calculate dependencies.  If  you  are
			   sure	 you  have  run	"pkgdb -F" in advance, you can
			   specify this	option to omit the sanity checks.

       -p prefix
       --prefix	prefix	   Set prefix as the  directory	 in  which  to	delete
			   files  from any installed packages which do not ex-
			   plicitly set	theirs.	 For most packages, the	prefix
			   will	be set automatically to	the installed location
			   by pkg_add(1).  [*]

       -P
       --preserve	   Preserve    FreeBSD	  shared    library	files.
			   pkg_deinstall invokes file(1) to check if each file
			   with	 the ".so.X", or ".so.X.Y" suffix is a FreeBSD
			   shared library, copies all  the  found  shared  li-
			   braries   to	 $LOCALBASE/lib/compat/pkg,  and  runs
			   ldconfig(8) to update the ldconfig cache.

			   This	option is useful when  you  suspect  that  you
			   still  have some binaries that depend on the	shared
			   library being deleted.

       -q
       --noconfig	   Do  not  read  the	configuration	file.	($PRE-
			   FIX/etc/pkgtools.conf)

       -r
       --recursive	   Deinstall all those packages	depending on the given
			   packages as well.

       -R
       --upward-recursive  Deinstall  all those	packages required by the given
			   packages as well.

       -v
       --verbose	   Turn	on verbose output. [*]

       -x pkgname_glob
       --exclude pkgname_glob
			   Exclude packages matching the specified  glob  pat-
			   tern.   Exclusion  is performed after recursing de-
			   pendency in response	to -r and/or -R, which	means,
			   for	example,  the following	command	will deinstall
			   all the packages depending  on  XFree86  but	 leave
			   XFree86 as it is:

			   pkg_deinstall -rx XFree86 XFree86

ENVIRONMENT
       PKG_DBDIR      Alternative location for the installed package database.
		      Default is "/var/db/pkg"

       PKGTOOLS_CONF  Configuration  file  for the pkgtools suite.  Default is
		      "$PREFIX/etc/pkgtools.conf".

FILES
       /var/db/pkg		  Default location of  the  installed  package
				  database.

       $LOCALBASE/lib/compat/pkg  Location where shared	library	files are pre-
				  served.

       $PREFIX/etc/pkgtools.conf  Default  location of the pkgtools configura-
				  tion file.

SEE ALSO
       pkg_add(1),  pkg_delete(1),  pkg_glob(1),   pkg_info(1),	  pkg_sort(1),
       pkgdb(1),      portinstall(1),	   portsclean(1),      portupgrade(1),
       pkgtools.conf(5), ports(7)

AUTHORS
       Akinori MUSHA <knu@iDaemons.org>

FreeBSD				 June 13, 2006		      PKG_DEINSTALL(1)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=pkg_deinstall&sektion=1&manpath=FreeBSD+Ports+14.3.quarterly>

home | help