git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sam Ravnborg <sam@ravnborg.org>
To: Ryan Anderson <ryan@michonline.com>
Cc: Junio C Hamano <junkio@cox.net>, git@vger.kernel.org
Subject: Re: [PATCH/RFC] "Recursive Make considered harmful"
Date: Fri, 29 Jul 2005 09:31:34 +0200	[thread overview]
Message-ID: <20050729073134.GA6507@mars.ravnborg.org> (raw)
In-Reply-To: <20050729065335.GA32263@mythryan2.michonline.com>

> > While I do not have strong objections to make the build process
> > go faster, it is somewhat disturbing that the Makefile pieces
> > maintained in subdirectories need to name things they touch
> > using paths that include the subdirectory names.  I do not have
> > a better alternative to suggest, though...

If the goal is to speed up the build process the only sane way is to fix
the dependencies. In kbuild fixdep is used to parse the .c file and it
locates all references to .h files (recursive) and also detects any
usage of CONFIG_ symbols.
This part should be relative straightforward to include in git.

> I think I'm going to rethink this, a bit more.  I'm unhappy with how I
> had to edit the sub-dir Makefiles to include directory names.  Sam, if
> you happen to be reading this, feel free to help out!
> 
> I'm almost thinking that something like:
> 
> 	PROGS := 
> 	SCRIPTS :=
> 	include x/Makefile.inc
> 	PROGRAMS += $(addprefix x/,$PROGS)
> 	ALL_SCRIPTS += $(addprefix x/,$SCRIPTS)

That is doable for sure. But it hits you hard when you have to create
some special rules in a subdirectory - then you need to know in what
directory you are placed. You could assing sub := x before including
x/Makefile.inc.

On the other hand. The recursive make considered harmful is IMHO a bit
overaggregated. See the kernel where it is used extensively. And it
works with no hassle. For a small project like git it should be possible
to keep the dependencies in proper shape so there is no cross directory
boundaries to worry about - or at least only a few.

	Sam

  reply	other threads:[~2005-07-29  7:31 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-27  8:39 [PATCH/RFC] "Recursive Make considered harmful" Ryan Anderson
2005-07-27 14:25 ` A Large Angry SCM
2005-07-27 14:37   ` Kirby C. Bohling
2005-07-27 15:32     ` A Large Angry SCM
2005-07-27 21:50 ` Junio C Hamano
2005-07-27 22:07   ` A Large Angry SCM
2005-07-28  7:51     ` Petr Baudis
2005-07-28  9:40       ` Matthias Urlichs
2005-07-28  7:04   ` Junio C Hamano
2005-07-28  7:45     ` Matthias Urlichs
2005-07-28 16:38       ` Junio C Hamano
2005-07-28 17:09         ` A Large Angry SCM
2005-07-29  6:53   ` Ryan Anderson
2005-07-29  7:31     ` Sam Ravnborg [this message]
2005-07-29  7:46       ` Petr Baudis
2005-07-29  9:12         ` Timo Hirvonen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050729073134.GA6507@mars.ravnborg.org \
    --to=sam@ravnborg.org \
    --cc=git@vger.kernel.org \
    --cc=junkio@cox.net \
    --cc=ryan@michonline.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).