From owner-freebsd-questions@FreeBSD.ORG Sat Nov 27 19:32:49 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 308C116A4CE for ; Sat, 27 Nov 2004 19:32:49 +0000 (GMT) Received: from lakermmtao12.cox.net (lakermmtao12.cox.net [68.230.240.27]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7A2E643D2F for ; Sat, 27 Nov 2004 19:32:48 +0000 (GMT) (envelope-from conrads@cox.net) Received: from dolphin.local.net ([68.11.30.24]) by lakermmtao12.cox.net (InterMail vM.6.01.04.00 201-2131-117-20041022) with ESMTP id <20041127193247.DFCM7953.lakermmtao12.cox.net@dolphin.local.net>; Sat, 27 Nov 2004 14:32:47 -0500 Received: from dolphin.local.net (localhost.local.net [127.0.0.1]) by dolphin.local.net (8.13.1/8.13.1) with SMTP id iARJWl4m076187; Sat, 27 Nov 2004 13:32:47 -0600 (CST) (envelope-from conrads@cox.net) Date: Sat, 27 Nov 2004 13:32:42 -0600 From: "Conrad J. Sabatier" To: Gert Cuykens Message-ID: <20041127133242.52ca4bd1@dolphin.local.net> In-Reply-To: References: X-Mailer: Sylpheed-Claws 0.9.12b (GTK+ 1.2.10; amd64-portbld-freebsd6.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit cc: freebsd-questions@freebsd.org Subject: Re: Make Depend X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 27 Nov 2004 19:32:49 -0000 On Sat, 27 Nov 2004 09:43:17 +0100, Gert Cuykens wrote: > "A Makefile rule that typically scans all C/C++ source files in a > directory, and generates rules that indicate that an object file > depends on certain header files, and must be recompiled if they are > recompiled." > > i dont understand this. how can a object depend on something that is > not compiled yet? Would the freebsd world not be a happier place if > make did the dependancy thingies what ever they are automatically ? Yes, it certainly would be a happier place. :-) And it would be great, too, if I could interface with my computer purely by voice control and synthesized speech feedback, and have it do what I *mean* and not what I say. :-) But alas, computers are not *that* smart yet. They still need a little help from us humans (actually, a *lot* of help). :-) Re: dependencies, it should be simple to understand if you give it a moment's thought. Let's say you have a file "main.c" that calls functions in "foo.c". In order for main.c to compile and link properly to create a complete, executable program, it's absolutely essential that foo.c be compiled and linked in as well. What Makefile dependencies are about is ensuring that, if a change is made to foo.c, it will be recompiled and relinked with main.c to guarantee that the final executable is up to date in all respects. Does that help? :-) -- Conrad J. Sabatier -- "In Unix veritas"