🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: alt.uu.comp.os.linux.questions
10 messages
10 total messages Started by Linux User Sat, 27 Mar 1999 00:00
OK, how do I UNinstall programs?
#194
Author: Linux User
Date: Sat, 27 Mar 1999 00:00
13 lines
1547 bytes
I've managed to get RedHat running and I've been downloading programs
from the Net like crazy, and testing all of them.

However, my harddisk is getting a bit full now and I wonder...

How do I UNINSTALL those programs!!! There are INSTALL-instructions,
but no uninstall. (I mainly use those tar.gz files instead of those
RPMs)

This is also a bit annoying when trying to install a newer version of
something and it says that the old one was already installed.

Your help please.
Re: OK, how do I UNinstall programs?
#195
Author: Mike DuFresne
Date: Sat, 27 Mar 1999 00:00
18 lines
1546 bytes
Linux User wrote:
> 
> However, my harddisk is getting a bit full now and I wonder...
> 
> How do I UNINSTALL those programs!!! There are INSTALL-instructions,
> but no uninstall. (I mainly use those tar.gz files instead of those
> RPMs)

Usually, 'make uninstall' does the trick. Of course, this depends on how
nice the packager was when making the Makefile and on whether or not you
kept the install directory around from which the install was created.
YMMV.

mike

-- 
In the immortal words of Socrates, who said: 'I drank what?'
						C. Knight
Re: OK, how do I UNinstall programs?
#196
Author: Thomas Griffing
Date: Sun, 28 Mar 1999 00:00
37 lines
2019 bytes
Linux User wrote:

> I've managed to get RedHat running and I've been downloading programs
> from the Net like crazy, and testing all of them.
>
> However, my harddisk is getting a bit full now and I wonder...
>
> How do I UNINSTALL those programs!!! There are INSTALL-instructions,
> but no uninstall. (I mainly use those tar.gz files instead of those
> RPMs)
>
> This is also a bit annoying when trying to install a newer version of
> something and it says that the old one was already installed.

Here's a quick run-down on how I use Red Hat's rpm to maintain software:

List all packages:

     $ rpm -qa | more
      . . .

List specific packages (lsof in this case):

     $ rpm -qa | grep lsof
     lsof-4.37-1

Remove a package:

     # rpm -e lsof

Upgrade a package to a new version:

     $ rpm -U lsof-4.38-1-i386.rpm

------------------------------------------------------------------------------
 Thomas L. Griffing   mailto:tom@vistyx.com
 Vistyx Corp          http://www.vistyx.com
Re: OK, how do I UNinstall programs?
#193
Author: Gareth Owen
Date: Mon, 29 Mar 1999 00:00
16 lines
1495 bytes
Linuxuser@windows98.com (Linux User) writes:
 
> How do I UNINSTALL those programs!!! There are INSTALL-instructions,
> but no uninstall. (I mainly use those tar.gz files instead of those
> RPMs)

Well, sadly, you usually have to find the programs/libraries/directores
that have been installed and manually delete them.  This can be
problematic in the case of libraries, since other stuff may be dependent
on them.  It's not difficult to write a shell script which uses ldd to
check for dependent apps in your PATH.  Mail me if you want mine...

-- 
Gareth Owen
http://www.ma.man.ac.uk/~gowen/lisp/
"Ed is the standard text editor."
Re: OK, how do I UNinstall programs?
#190
Author: Peter Polman
Date: Tue, 30 Mar 1999 00:00
18 lines
1571 bytes
You should be able to do a "make uninstall" from the same directory where
you did the "make install"

Linux User wrote:

> I've managed to get RedHat running and I've been downloading programs
> from the Net like crazy, and testing all of them.
>
> However, my harddisk is getting a bit full now and I wonder...
>
> How do I UNINSTALL those programs!!! There are INSTALL-instructions,
> but no uninstall. (I mainly use those tar.gz files instead of those
> RPMs)
>
> This is also a bit annoying when trying to install a newer version of
> something and it says that the old one was already installed.
>
> Your help please.
Re: OK, how do I UNinstall programs?
#191
Author: Nix
Date: Tue, 30 Mar 1999 00:00
14 lines
1632 bytes
Gareth Owen <gowen+usenet@ma.man.ac.uk> writes:

[`how do I uninstall?']
> Well, sadly, you usually have to find the programs/libraries/directores
> that have been installed and manually delete them.  This can be
> problematic in the case of libraries, since other stuff may be dependent
> on them.  It's not difficult to write a shell script which uses ldd to
> check for dependent apps in your PATH.  Mail me if you want mine...

This is *exactly* what GNU stow is for.

-- 
`The purpose of a windowing system is to put some amusing
 fluff around your one almighty emacs window.' -- Mark on gnu.emacs.help
Re: OK, how do I UNinstall programs?
#192
Author: Cameron Hutchison
Date: Tue, 30 Mar 1999 00:00
123 lines
4026 bytes
Nix <$}xin{$@esperi.demon.co.uk> writes:

>Gareth Owen <gowen+usenet@ma.man.ac.uk> writes:

>[`how do I uninstall?']
>> Well, sadly, you usually have to find the programs/libraries/directores
>> that have been installed and manually delete them.  This can be
>> problematic in the case of libraries, since other stuff may be dependent
>> on them.  It's not difficult to write a shell script which uses ldd to
>> check for dependent apps in your PATH.  Mail me if you want mine...

>This is *exactly* what GNU stow is for.

Maybe I did something wrong, but when I used stow to remove a package, it
was *really slow*. I have a few shell functions that I wrote to make
removing packages easier.

It is similar to stow in that all packages are installed in
/usr/local/pkg/<pkgname> and then symlinked into the /usr/local hierarchy.
It also supports multiple package repositories for multiple hierarchies.

The functions are quite basic but do the job quite well. I've had no
problems with them yet on my single user machine. There are 4 functions
below - you only use the instpkg and rmpkg, the other two are internal.

-------------cut here------------

function instpkg()
{
  if [ $# != 1 ] ; then
    echo "Usage: instpkg package_name" >&2
    return 1
  fi
 
  for dstdir in $(echo $PKGDIRS | tr : " ") ; do
    local pkgdir=${dstdir}/pkg/$1
  
    if [ -d ${pkgdir} ] ; then
      pkg_installdir $pkgdir $dstdir
      return 0
    fi
  done
 
  echo -n "instpkg: $1 is not a package name in \"" >&2
  echo -n $PKGDIRS | tr : " " >&2
  echo "\""
  return 1
}

function rmpkg()
{
  if [ $# != 1 ] ; then
    echo "Usage: rmpkg package_name" >&2
    return 1
  fi
 
  for dstdir in $(echo $PKGDIRS | tr : " ") ; do
    local pkgdir=${dstdir}/pkg/$1
  
    if [ -d ${pkgdir} ] ; then
      pkg_removedir $pkgdir $dstdir
      return 0
    fi
  done
 
  echo -n "rmpkg: $1 is not a package name in \"" >&2
  echo -n $PKGDIRS | tr : " " >&2
  echo "\""
  return 1
}

function pkg_installdir()
{
  if [ $# != 2 ] ; then
    echo "Usage: pkg_installdir srcdir dstdir" >&2
    return 1
  fi
 
  for i in $1/* ; do
    local dir=`basename $i`
    if [ -d $i ] ; then
      if [ ! -e $2/$dir ] ; then
        mkdir $2/$dir
      fi
 
      if [ -d $2/$dir ] ; then
        pkg_installdir $i $2/$dir
      else
        echo "Cannot install to $2/$dir: Not a directory" >&2
      fi
    else
      ln -s $i $2/$dir
    fi
  done
}

function pkg_removedir()
{
  if [ $# != 2 ] ; then
    echo "Usage: pgk_removedir srcdir dstdir" >&2
    return 1
  fi
 
  for i in $1/* ; do
    local base=`basename $i`
    if [ -d $2/$base ] ; then
      pkg_removedir $i $2/$base
      rmdir $2/$base 2>/dev/null
    else
      if [ -L $2/$base ] ; then
        rm -f $2/$base
      else
        echo "Will not remove non-link file $2/$base" >&2
      fi
    fi
  done
}

-------------cut here------------

-- 
Cameron Hutchison (camh@zip.net.au) | Onward To Mars
GCS d--@ -p+ c++(++++) l++ u+ e+ m+(-) s n- h++ f? !g w+ t r+
Re: OK, how do I UNinstall programs?
#187
Author: Gareth Owen
Date: Wed, 31 Mar 1999 00:00
12 lines
1297 bytes
Nix <$}xin{$@esperi.demon.co.uk> writes:
> [Checking library dependencies]
> 
> This is *exactly* what GNU stow is for.
 
The only problem in this case is that stow doesn't work on stuff that
already been smeared all over /usr/local/ in a non-stow-aware way.

-- 
Gareth Owen
http://www.ma.man.ac.uk/~gowen/lisp/
Generally Not Used, Exception: Middle Aged Computer Scientists
Re: OK, how do I UNinstall programs?
#188
Author: Nix
Date: Wed, 31 Mar 1999 00:00
60 lines
3323 bytes
Cameron Hutchison <camh@zip.net.au> writes:

> Maybe I did something wrong, but when I used stow to remove a package, it
> was *really slow*.

It has to be. The semantics it promises are not obtainable without a
full disk scan for symlinks to things under the package name you
specified.

Besides - you can run a package uninstallation in the background,
without difficulty.

Note that removal time is O(n) where n is the number of blocks occupied
by all directories on the disk; it is *not* related to the number of
packages you are removing. So remove lots at once :)

> It is similar to stow in that all packages are installed in
> /usr/local/pkg/<pkgname> and then symlinked into the /usr/local hierarchy.

Bear in mind that stow does not mandate this. I for instance stow from
/usr/packages.bin/core/<name> to /usr/<name> and have
/usr/packages.bin/core/<name> be a symlink to
/usr/packages.bin/name/version/.

Flexibility is good.

> It also supports multiple package repositories for multiple hierarchies.

Er, so does stow...

>   echo -n "instpkg: $1 is not a package name in \"" >&2

This means you cannot clean up dead packages after you delete the
package binaries. With that requirement I can see how you manage
blazingly fast deletion, but you also run the risk of leaving crap lying
around. It's easy to do this;

you have a package {foo} installed which has a file foo/bar in it;

you install a new foo which removes foo/bar;

later on, you remove foo.

The stowed link to foo/bar remains although the rest of foo is gone :(

> function pkg_installdir()
> {
[snip installdir and removedir]

Pardon me for being thick, but I can't see the split-and-recombine
semantics of stow in here. What happens, eg, with /usr/share/locale/,
which has stuff shared by multiple packages in it? Stow keeps things
symlinked to the package directory as much as possible and turns them
into real directories only when it must. (Some things, eg the ORBit from
out of the GNOME, effectively require this behaviour for them to work
correctly when installed.)

-- 
`The purpose of a windowing system is to put some amusing
 fluff around your one almighty emacs window.' -- Mark on gnu.emacs.help
Re: OK, how do I UNinstall programs?
#189
Author: Nix
Date: Wed, 31 Mar 1999 00:00
21 lines
1785 bytes
Gareth Owen <gowen+usenet@ma.man.ac.uk> writes:

> Nix <$}xin{$@esperi.demon.co.uk> writes:
> > [Checking library dependencies]
> > 
> > This is *exactly* what GNU stow is for.
>  
> The only problem in this case is that stow doesn't work on stuff that
> already been smeared all over /usr/local/ in a non-stow-aware way.

Put whatever in a stowable directory and do

stow -t /usr/local -v -c package | 2>&1 grep '^CONFLICT: ' | cut -d\  -f4 | xargs rm

or words to that effect.

(Of course this only cleans up conflicting stuff; but stow can do no more!)

-- 
`The purpose of a windowing system is to put some amusing
 fluff around your one almighty emacs window.' -- Mark on gnu.emacs.help
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads