[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: GNU make 4.3.90 release candidate available
From: |
Eli Zaretskii |
Subject: |
Re: GNU make 4.3.90 release candidate available |
Date: |
Sat, 24 Sep 2022 14:09:30 +0300 |
I've built this with mingw.org's MinGW for native MS-Windows. I found
several issues during the build, some of them specific to Windows,
others more general. (I didn't yet run the test suite, I intend to do
that next.)
Here are the build-time issues that aren't specific to MS-Windows:
src/getopt.c: In function '_getopt_internal':
src/getopt.c:679:8: warning: suggest explicit braces to avoid ambiguous
'else' [-Wdangling-else]
679 | if (opterr)
| ^
(This is not new to this release, I saw the same in Make 4.3.) I
ignored this one.
src/implicit.c: In function 'pattern_search':
src/implicit.c:237:9: warning: unused variable 'dend' [-Wunused-variable]
237 | char *dend = depname + deplen;
| ^~~~
This variable is only used in assertions; the proposed patch is below.
src/main.c: In function 'main':
src/main.c:2561:26: warning: variable 'len' set but not used
[-Wunused-but-set-variable]
2561 | size_t len;
| ^~~
Same here: the variable is only used in an assertion; the proposed
patch is below.
Here are the proposed patches for the above 2 warnings. Paul, if you
agree with them, I will install them in the repository.
--- src/implicit.c~0 2022-09-24 13:36:21.490875000 +0300
+++ src/implicit.c 2022-09-24 13:37:14.162750000 +0300
@@ -234,7 +234,9 @@ pattern_search (struct file *file, int a
We may replace % by $(*F) for second expansion, increasing the length. */
size_t deplen = namelen + max_pattern_dep_length + 4;
char *depname = alloca (deplen);
+#ifndef NDEBUG
char *dend = depname + deplen;
+#endif
/* The start and length of the stem of FILENAME for the current rule. */
const char *stem = 0;
--- src/main.c~0 2022-09-20 10:55:39.000000000 +0300
+++ src/main.c 2022-09-24 13:40:33.584625000 +0300
@@ -2558,13 +2558,11 @@ main (int argc, char **argv, char **envp
for (; *av; ++av, ++nv)
{
- size_t len;
char *f;
char *a = *av;
const char *mf = makefiles->list[mfidx];
- len = strlen (a);
- assert (len > 0);
+ assert (strlen (a) > 0);
*nv = a;
- GNU make 4.3.90 release candidate available, Paul Smith, 2022/09/20
- Re: GNU make 4.3.90 release candidate available, Sam James, 2022/09/21
- Re: GNU make 4.3.90 release candidate available,
Eli Zaretskii <=
- Re: GNU make 4.3.90 release candidate available, Eli Zaretskii, 2022/09/24
- Re: GNU make 4.3.90 release candidate available, Paul Smith, 2022/09/24
- Re: GNU make 4.3.90 release candidate available, Eli Zaretskii, 2022/09/24
- Re: GNU make 4.3.90 release candidate available, Paul Smith, 2022/09/24
- Re: GNU make 4.3.90 release candidate available, Paul Smith, 2022/09/24
- Re: GNU make 4.3.90 release candidate available, Eli Zaretskii, 2022/09/25
- Re: GNU make 4.3.90 release candidate available, Paul Smith, 2022/09/25
- Re: GNU make 4.3.90 release candidate available, Eli Zaretskii, 2022/09/25