bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] lib/readline/doc makefiles clean targets


From: Martin D Kealey
Subject: Re: [PATCH] lib/readline/doc makefiles clean targets
Date: Thu, 14 Nov 2024 20:09:40 +1300 (NZDT)
User-agent: Alpine 2.21 (DEB 202 2017-01-01)


On Thu, 7 Nov 2024, Chet Ramey wrote:
> y.tab.h isn't part of the devel branch, you need bison to build it, and
> it is included in the bash distributions. I see the problem here, though.
> I'll figure out a way to fix it that's compatible with it being included
> and not without too many release-specific changes.
>
> The fundamental difference is that the devel branch and the master
> (distribution) branch contain different files, and serve different
> purposes from a common source base, and the existing Makefiles are
> built for the master branch.

Ahah. That explains a few oddities I've noticed when editing **/Makefile.in.

May I suggest that there be a new variable that denotes either the build
subdirectory (on the master branch) or the source subdirectory (on the devel
branch)?

That way we could have, for example, $(prebuilt)y.tab.h and maybe
$(prebuilt_top)builtins/new_math/y.tab.c

Or is the plan to rely entirely on VPATH, and on $@ and $< to provide the
actual paths? I'm not really a fan of this approach as it only applies to
dependencies, not targets, and "make Makefile" gets even more tangled. I've
been repeatedly bitten where I wind up with a (broken) re-built version
shadowing a pre-built version, and had to waste a lot of time figuring out
why the larger build fails. This is particularly problematic when building
within a git repo, switching between branches where the pre-built version is
or isn't present.

It would also be nice to have "make distclean" and "make develclean" as
separate targets.

-Martin



reply via email to

[Prev in Thread] Current Thread [Next in Thread]