Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 20 Jun 1996 14:23:31 GMT
From:      James Raynard <fqueries@jraynard.demon.co.uk>
To:        sbakshi@washington.xtn.net
Cc:        questions@freebsd.org
Subject:   Re: how to unzip gzip'd files
Message-ID:  <199606201423.OAA01782@jraynard.demon.co.uk>
In-Reply-To: <31C88833.33AA@washington.xtn.net> (message from DAMAN on Wed, 19 Jun 1996 18:07:31 -0500)

next in thread | previous in thread | raw e-mail | index | archive | help
> all the ports you have are gzip'd what file do i need to uzip 
> them. and where can i get it from

The tools needed to unzip things are gunzip (for .gz files) and tar
(for .tar files), both of which are supplied with the base FreeBSD
system. In fact, tar can do both in one go, given the right arguments.

However, you presumably want to compile and install them rather than
just extract the original, unported source code. Fortunately, the
FreeBSD ports mechanism does all the hard work for you.

A detailed explanation is at http://www.freebsd.org/handbook/ under
'The ports collection', but here's a quick overview.

To do this, you need to set up a ports 'skeleton'. You can do this
very easily, making use of ftp.freebsd.org's on-the-fly tar-and-zip
feature which allows you to grab a directory and its contents in one
go.

Assuming you don't already have one, here's how to do this if you're
interested in, say the foobar program in the audio directory in ports:-

# cd /usr
# mkdir -p ports/audio
# cd ports/audio
# ftp ftp.freebsd.org
[log in as anonymous and give your email address as the password]
> cd /the/ports/base/directory/audio
> get foobar.tar.gz		[grab the foobar skeleton]
> quit
# tar xzf foobar.tar.gz		[extract the foobar skeleton]
# cd foobar
# make install

At this point, a number of things will happen:-

1. The original source code will be extracted from the
   /usr/ports/distfiles directory. If it's not there, it will be pulled
   down by FTP. (You can also set it up to get it from a FreeBSD CDROM
   fairly easily).

2. Any configuration and/or patching needed to get the program to work
   on FreeBSD will be performed.

3. The source will be compiled and installed.

4. The packages database keeps a record of all the files added, so if
   you decide foobar is not the greatest thing since sliced bread
   after all, you can remove it cleanly by something like 'pkg_delete 
   foobar-4.9'.

If you don't want the source lying around and cluttering up your
system, you can now do 'make clean' to remove it.

-- 
James Raynard, Edinburgh, Scotland
james@jraynard.demon.co.uk



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199606201423.OAA01782>