Re: Detect --disable-dependency-tracking in Makefile.am

"Zack Weinberg" <[email protected]>
Newsgroups gmane.comp.sysutils.automake.general
Message-ID <[email protected]>
On Sat, Sep 30, 2023, at 1:07 AM, Jan Engelhardt wrote:
> On Saturday 2023-09-30 05:27, Dave Hart wrote:
>
>>I've added code to the ntp.org Makefile.am files to ensure the static
>>utility library libntp.a is up-to-date for each program that uses it, to
>>ensure the build is correct.  When building the project, this adds a bunch
>>of extra submake invocations which slows down the build.  I'd like to omit
>>those when --disable-dependency-tracking is used, to speed one-off builds
>>that are done by end-users and packagers.
>
> submake is pretty much independent of and from dependency tracking.
>
> The general direction contemporary projects take is to just not do submake
> anymore, because it's a slowdown whether or not deptracking is used.

To elaborate on that: it's been known since *1997* that recursive make is
always a bad idea. See <https://grosskurth.ca/bib/1997/miller.pdf> for gory
details.

It's too bad that Automake still, 26 years later, can only support non-recursive
builds in a fairly clunky way (manually adding subdirectory prefixes to every
single object file).  It shouldn't be *that* hard to make "subdirs = lib bin"
mush all the rules derived from {lib,bin}/Makefile.am into the top-level
generated Makefile.in, at least when there aren't any manually written rules
in the subdirectories.

zw
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.