Build failure with stricter C compilers (e.g. GCC 14)
Modern C compilers are becoming stricter with a variety of changes over the last year or so.
GCC 14 in particular (to be released in ~April 2024) fails to build imake-1.0.9 like:
imake.c: In function ‘doit’:
imake.c:803:29: error: passing argument 2 of ‘execvp’ from incompatible pointer type [-Wincompatible-pointer-types]
803 | execvp(cmd, argv);
| ^~~~
| |
| const char **
In file included from imake.c:172:
/usr/include/unistd.h:599:52: note: expected ‘char * const*’ but argument is of type ‘const char **’
599 | extern int execvp (const char *__file, char *const __argv[])
| ~~~~~~~~~~~~^~~~~~~~
This can be emulated with -Werror=incompatible-pointer-types -Werror=implicit -Werror=int-conversion
on an older GCC or Clang.