Re: [PATCH] Makefile: avoid undefined variables

2024-10-26 Thread Mike Jonkmans
On Thu, Oct 24, 2024 at 03:07:46PM -0400, Grisha Levit wrote: > These are reported by make --warn-undefined-variables. > > Most were being set previously (sometimes 20 years ago) and got left > behind in recepies after their definitions have been removed. Others > only get set in some configuratio

Re: [PATCH] Makefile: avoid undefined variables

2024-10-26 Thread Chet Ramey
On 10/25/24 8:44 AM, Martin D Kealey wrote: I've been looking at the Makefiles as well, and I find I have a lot of questions, like: 1. What is the point of ‘$(BUILD_DIR)’? Just what it seems: an absolute pathname to the current build directory, which can include spaces. 2. Do any o

Re: [PATCH] Makefile: avoid undefined variables

2024-10-26 Thread Chet Ramey
On 10/26/24 10:32 AM, Martin D Kealey wrote: On Sat, 26 Oct 2024, 00:05 Dmitry Goncharov, wrote: - cd $(@D) && $(MAKE) BUILD_DIR=$(UP)$(BUILD_DIR) top_srcdir=$(UPSRC)$(top_srcdir) $(MAKEFLAGS) $(@F) It is really not a good idea to pass makeflags on the command line as a positional pa

Re: [PATCH] Makefile: avoid undefined variables

2024-10-26 Thread Martin D Kealey
On Sat, 26 Oct 2024, 00:05 Dmitry Goncharov, wrote: > >- cd $(@D) && $(MAKE) BUILD_DIR=$(UP)$(BUILD_DIR) > >top_srcdir=$(UPSRC)$(top_srcdir) $(MAKEFLAGS) $(@F) > > It is really not a good idea to pass makeflags on the command line as a > positional parameter. Agreed, but I was just copy

Re: [PATCH] Makefile: avoid undefined variables

2024-10-26 Thread Chet Ramey
On 10/24/24 3:07 PM, Grisha Levit wrote: These are reported by make --warn-undefined-variables. Most were being set previously (sometimes 20 years ago) and got left behind in recepies after their definitions have been removed. Others only get set in some configurations so it makes sense to preve

Re: posix vs default mode nonsense

2024-10-26 Thread Chet Ramey
On 10/25/24 7:41 PM, Zachary Santer wrote: On Tue, Oct 22, 2024 at 11:30 AM Chet Ramey wrote: but that won't help with the portability problems. You can't even use arrays or [[ ... ]] and be portable, right? Well, it's tough to be portable to shells that don't implement those. It might