Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 24 Sep 2001 22:41:01 -0700
From:      "Freddie Cash" <fcash@bigfoot.com>
To:        <freebsd-newbies@freebsd.org>
Cc:        "leegold" <leegold@operamail.com>
Subject:   Re: help me understand: make, also file locks
Message-ID:  <3BAFB67D.30076.6F3624@localhost>
In-Reply-To: <001701c14580$6ab3e730$0201a8c0@shavedham>

next in thread | previous in thread | raw e-mail | index | archive | help
> Coming from the ms world, i always installed programs
> by pressing a button. i suppose the programs were in binary form. With
> freebsd I often see the  make  command associated w/installing. if
> someone could just briefly explain make, make install, and make clean?

In a nutshell, the combination of make and the associated Makefile is like a more powerful, 
glorified batch file.  The Makefile is simply a list of compilation, installation, deinstallation, 
deletion, etc commands.  It also contains targets, which are simply sub-sections that include 
instructions for specific tasks (for example, install and deinstall).

Makefiles and Windows Installation Scripts are very similar, although Makefiles are much more 
powerful.  :)

Have a look through some of the Makefiles included with various programs.  Once you get past 
the seeming gobbledygook, you'll start to notice the general flow of the file and how it works.  :)

In FreeBSD, there are two ways to install a program: using ports, and using packages (okay, you 
can also install from source yourself, but it's not generally suggested).

When you install a package, using the pkg_add command, the install works the same as in 
Windows:  a script is read that copies the binaries to the right places and sets any initial config 
options.

When you install a port, using the make command, you are doing the same steps as above, but 
you have to compile the source code into binary beforehand.  The make command does all this 
for you (including downloading the source, checking any dependencies, compiling, and installing 
everything for you) according to the instructions included in the Makefile.

Hope that clears it up a little for you.  :)

Cheers,
Freddie
fcash@bigfoot.com

Linux is for people who hate Windows.
FreeBSD is for people that like UNIX.
  -- unknown


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-newbies" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3BAFB67D.30076.6F3624>