clarity20 / bash2py

Bash-to-python transpiler https://www.swag.uwaterloo.ca/bash2py/index.html
GNU General Public License v3.0
30 stars 15 forks source link

Can't build on ARM64 Mac #49

Open verhovsky opened 10 months ago

verhovsky commented 10 months ago

On my M1 Macbook Air (M1 is Apple silicon, it's the ARM64 (also called AArch64) architecture) running macOS 14.2.1 with clang 15 I get this error:

/tmp$ cd /tmp/
/tmp$ git clone git@github.com:clarity20/bash2py.git
[...]
/tmp$ cd bash2py
/tmp/bash2py$ git checkout aac86d9
[...]
/tmp/bash2py$ ./install 
checking build system type... arm-apple-darwin23.2.0
checking host system type... arm-apple-darwin23.2.0

Beginning configuration for bash-4.3-release for arm-apple-darwin23.2.0

checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for strerror in -lcposix... no
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /opt/homebrew/bin/ggrep
checking for egrep... /opt/homebrew/bin/ggrep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define __EXTENSIONS__... yes
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... no
checking whether gcc needs -traditional... no
checking for a BSD-compatible install... /opt/homebrew/bin/ginstall -c
checking for ar... ar
checking for ranlib... ranlib
checking for bison... bison -y
checking whether make sets $(MAKE)... yes
checking for an ANSI C-conforming const... yes
checking for inline... inline
checking whether byte ordering is bigendian... no
checking for preprocessor stringizing operator... yes
checking for long double with more range or precision than double... no
checking for function prototypes... yes
checking whether char is unsigned... no
checking for working volatile... yes
checking for C/C++ restrict keyword... __restrict
checking whether NLS is requested... yes
checking for msgfmt... /opt/homebrew/bin/msgfmt
checking for gmsgfmt... /opt/homebrew/bin/msgfmt
checking for xgettext... /opt/homebrew/bin/xgettext
checking for msgmerge... /opt/homebrew/bin/msgmerge
checking for off_t... yes
checking for size_t... yes
checking for working alloca.h... yes
checking for alloca... yes
checking for stdlib.h... (cached) yes
checking for unistd.h... (cached) yes
checking for sys/param.h... yes
checking for sys/time.h... yes
checking for getpagesize... yes
checking for working mmap... yes
checking whether we are using the GNU C Library 2.1 or newer... no
checking whether integer division by zero raises SIGFPE... no
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unsigned long long... yes
checking for inttypes.h... yes
checking whether the inttypes.h PRIxNN macros are broken... no
checking for ld used by GCC... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no
checking for shared library run path origin... done
checking argz.h usability... no
checking argz.h presence... no
checking for argz.h... no
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking nl_types.h usability... yes
checking nl_types.h presence... yes
checking for nl_types.h... yes
checking malloc.h usability... no
checking malloc.h presence... no
checking for malloc.h... no
checking stddef.h usability... yes
checking stddef.h presence... yes
checking for stddef.h... yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for unistd.h... (cached) yes
checking for sys/param.h... (cached) yes
checking for feof_unlocked... yes
checking for fgets_unlocked... no
checking for getc_unlocked... yes
checking for getcwd... yes
checking for getegid... yes
checking for geteuid... yes
checking for getgid... yes
checking for getuid... yes
checking for mempcpy... no
checking for munmap... yes
checking for putenv... yes
checking for setenv... yes
checking for setlocale... yes
checking for localeconv... yes
checking for stpcpy... yes
checking for strcasecmp... yes
checking for strdup... yes
checking for strtoul... yes
checking for tsearch... yes
checking for __argz_count... no
checking for __argz_stringify... no
checking for __argz_next... no
checking for __fsetlocking... no
checking for iconv... yes
checking how to link with libiconv... -liconv
checking for iconv declaration... 
         extern size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
checking for nl_langinfo and CODESET... yes
checking for LC_MESSAGES... yes
checking for bison... bison
checking version of bison... 2.3, ok
checking whether NLS is requested... yes
checking whether included gettext is requested... no
checking for GNU gettext in libc... no
checking for GNU gettext in libintl... no
checking whether to use NLS... yes
checking where the gettext function comes from... included intl directory
checking for dirent.h that defines DIR... yes
checking for library containing opendir... none required
checking whether time.h and sys/time.h may both be included... yes
checking for inttypes.h... (cached) yes
checking for unistd.h... (cached) yes
checking for stdlib.h... (cached) yes
checking stdarg.h usability... yes
checking stdarg.h presence... yes
checking for stdarg.h... yes
checking varargs.h usability... no
checking varargs.h presence... no
checking for varargs.h... no
checking for limits.h... (cached) yes
checking for string.h... (cached) yes
checking for memory.h... (cached) yes
checking for locale.h... (cached) yes
checking termcap.h usability... yes
checking termcap.h presence... yes
checking for termcap.h... yes
checking termio.h usability... no
checking termio.h presence... no
checking for termio.h... no
checking termios.h usability... yes
checking termios.h presence... yes
checking for termios.h... yes
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking stdbool.h usability... yes
checking stdbool.h presence... yes
checking for stdbool.h... yes
checking for stddef.h... (cached) yes
checking for stdint.h... (cached) yes
checking netdb.h usability... yes
checking netdb.h presence... yes
checking for netdb.h... yes
checking pwd.h usability... yes
checking pwd.h presence... yes
checking for pwd.h... yes
checking grp.h usability... yes
checking grp.h presence... yes
checking for grp.h... yes
checking for strings.h... (cached) yes
checking regex.h usability... yes
checking regex.h presence... yes
checking for regex.h... yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking ulimit.h usability... yes
checking ulimit.h presence... yes
checking for ulimit.h... yes
checking sys/pte.h usability... no
checking sys/pte.h presence... no
checking for sys/pte.h... no
checking sys/stream.h usability... no
checking sys/stream.h presence... no
checking for sys/stream.h... no
checking sys/select.h usability... yes
checking sys/select.h presence... yes
checking for sys/select.h... yes
checking sys/file.h usability... yes
checking sys/file.h presence... yes
checking for sys/file.h... yes
checking sys/resource.h usability... yes
checking sys/resource.h presence... yes
checking for sys/resource.h... yes
checking for sys/param.h... (cached) yes
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking for sys/stat.h... (cached) yes
checking for sys/time.h... (cached) yes
checking sys/times.h usability... yes
checking sys/times.h presence... yes
checking for sys/times.h... yes
checking for sys/types.h... (cached) yes
checking sys/wait.h usability... yes
checking sys/wait.h presence... yes
checking for sys/wait.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking arpa/inet.h usability... yes
checking arpa/inet.h presence... yes
checking for arpa/inet.h... yes
checking for sys/ptem.h... no
checking for working alloca.h... (cached) yes
checking for alloca... (cached) yes
checking whether getpgrp requires zero arguments... yes
checking for vprintf... yes
checking for _doprnt... no
checking for working strcoll... yes
checking return type of signal handlers... void
checking for __setostype... no
checking for wait3... yes
checking for mkfifo... yes
checking for dup2... yes
checking for eaccess... no
checking for fcntl... yes
checking for getdtablesize... yes
checking for getgroups... yes
checking for gethostname... yes
checking for getpagesize... (cached) yes
checking for getpeername... yes
checking for getrlimit... yes
checking for getrusage... yes
checking for gettimeofday... yes
checking for kill... yes
checking for killpg... yes
checking for lstat... yes
checking for readlink... yes
checking for sbrk... yes
checking for select... yes
checking for setdtablesize... no
checking for setitimer... yes
checking for tcgetpgrp... yes
checking for uname... yes
checking for ulimit... yes
checking for waitpid... yes
checking for rename... yes
checking for bcopy... yes
checking for bzero... yes
checking for confstr... yes
checking for faccessat... yes
checking for fnmatch... yes
checking for getaddrinfo... yes
checking for gethostbyname... yes
checking for getservbyname... yes
checking for getservent... yes
checking for inet_aton... yes
checking for imaxdiv... yes
checking for memmove... yes
checking for pathconf... yes
checking for putenv... (cached) yes
checking for raise... yes
checking for regcomp... yes
checking for regexec... yes
checking for setenv... (cached) yes
checking for setlinebuf... yes
checking for setlocale... (cached) yes
checking for setvbuf... yes
checking for siginterrupt... yes
checking for strchr... yes
checking for sysconf... yes
checking for syslog... yes
checking for tcgetattr... yes
checking for times... yes
checking for ttyname... yes
checking for tzset... yes
checking for unsetenv... yes
checking for vasprintf... yes
checking for asprintf... yes
checking for isascii... yes
checking for isblank... yes
checking for isgraph... yes
checking for isprint... yes
checking for isspace... yes
checking for isxdigit... yes
checking for getpwent... yes
checking for getpwnam... yes
checking for getpwuid... yes
checking for getcwd... (cached) yes
checking for memset... yes
checking for strcasecmp... (cached) yes
checking for strcasestr... yes
checking for strerror... yes
checking for strftime... yes
checking for strnlen... yes
checking for strpbrk... yes
checking for strstr... yes
checking for strtod... yes
checking for strtol... yes
checking for strtoul... (cached) yes
checking for strtoll... yes
checking for strtoull... yes
checking for strtoimax... yes
checking for strtoumax... yes
checking for dprintf... yes
checking for strchrnul... no
checking for strdup... (cached) yes
checking whether AUDIT_USER_TTY is declared... no
checking whether confstr is declared... yes
checking whether printf is declared... yes
checking whether sbrk is declared... yes
checking whether setregid is declared... yes
checking whether strcpy is declared... yes
checking whether strsignal is declared... yes
checking whether strtold is declared... yes
checking for broken strtold... yes
checking for declaration of strtoimax... yes
checking for declaration of strtol... yes
checking for declaration of strtoll... yes
checking for declaration of strtoul... yes
checking for declaration of strtoull... yes
checking for declaration of strtoumax... yes
checking for alarm... yes
checking for fpurge... yes
checking for __fpurge... no
checking for snprintf... yes
checking for vsnprintf... yes
checking for working mktime... no
checking for argz.h... (cached) no
checking errno.h usability... yes
checking errno.h presence... yes
checking for errno.h... yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking for malloc.h... (cached) no
checking stdio_ext.h usability... no
checking stdio_ext.h presence... no
checking for stdio_ext.h... no
checking for getpagesize... (cached) yes
checking for working mmap... (cached) yes
checking for __argz_count... (cached) no
checking for __argz_next... (cached) no
checking for __argz_stringify... (cached) no
checking for dcgettext... no
checking for mempcpy... (cached) no
checking for munmap... (cached) yes
checking for stpcpy... (cached) yes
checking for strcspn... yes
checking wctype.h usability... yes
checking wctype.h presence... yes
checking for wctype.h... yes
checking wchar.h usability... yes
checking wchar.h presence... yes
checking for wchar.h... yes
checking langinfo.h usability... yes
checking langinfo.h presence... yes
checking for langinfo.h... yes
checking for mbrlen... yes
checking for mbscasecmp... no
checking for mbscmp... no
checking for mbsnrtowcs... yes
checking for mbsrtowcs... yes
checking for mbschr... no
checking for wcrtomb... yes
checking for wcscoll... yes
checking for wcsdup... yes
checking for wcwidth... yes
checking for wctype... yes
checking for wcswidth... yes
checking whether mbrtowc and mbstate_t are properly declared... yes
checking for iswlower... yes
checking for iswupper... yes
checking for towlower... yes
checking for towupper... yes
checking for iswctype... yes
checking for nl_langinfo and CODESET... yes
checking for wchar_t in wchar.h... yes
checking for wctype_t in wctype.h... yes
checking for wint_t in wctype.h... yes
checking for wcwidth broken with unicode combining characters... 
checking for locale_charset... yes
checking for dlopen in -ldl... yes
checking for dlopen... yes
checking for dlclose... yes
checking for dlsym... yes
checking whether sys_siglist is declared... yes
checking for uid_t in sys/types.h... yes
checking type of array argument to getgroups... gid_t
checking for off_t... (cached) yes
checking for mode_t... yes
checking for uid_t in sys/types.h... (cached) yes
checking for pid_t... yes
checking for size_t... (cached) yes
checking for ssize_t... yes
checking for time_t... yes
checking for long long... long long
checking for unsigned long long... unsigned long long
checking return type of signal handlers... (cached) void
checking for sig_atomic_t in signal.h... yes
checking size of char... 1
checking size of short... 2
checking size of int... 4
checking size of long... 8
checking size of char *... 8
checking size of double... 8
checking size of long long... 8
checking for u_int... yes
checking for u_long... yes
checking for bits16_t... no
checking for u_bits16_t... no
checking for bits32_t... no
checking for u_bits32_t... no
checking for bits64_t... no
checking for ptrdiff_t... yes
checking whether stat file-mode macros are broken... no
checking whether #! works in shell scripts... yes
checking whether the ctype macros accept non-ascii characters... no
checking if dup2 fails to clear the close-on-exec flag... no
checking whether pgrps need synchronization... yes
checking for type of signal functions... posix
checking for sys_errlist and sys_nerr... yes
checking for sys_siglist in system C library... no
checking for _sys_siglist in signal.h or unistd.h... no
checking for _sys_siglist in system C library... no
checking whether signal handlers are of type void... yes
checking for clock_t... yes
checking for sigset_t... yes
checking for sig_atomic_t... yes
checking for quad_t... yes
checking for intmax_t... yes
checking for uintmax_t... yes
checking for socklen_t... yes
checking for size and type of struct rlimit fields... rlim_t
checking size of intmax_t... 8
checking for struct termios.c_line... no
checking for struct termio.c_line... no
checking for struct dirent.d_ino... yes
checking for struct dirent.d_fileno... yes
checking for struct dirent.d_namlen... yes
checking for struct winsize in sys/ioctl.h and termios.h... sys/ioctl.h
checking for struct timeval in sys/time.h and time.h... yes
checking for struct stat.st_blocks... yes
checking whether struct tm is in sys/time.h or time.h... time.h
checking for struct tm.tm_zone... yes
checking for struct timezone in sys/time.h and time.h... yes
checking for offset of exit status in return status from wait... 8
checking for struct timespec in <time.h>... yes
checking for struct stat.st_atim.tv_nsec... no
checking for struct stat.st_atimespec.tv_nsec... yes
checking for the existence of strsignal... no
checking if opendir() opens non-directories... no
checking whether ulimit can substitute for getdtablesize... no
checking whether fpurge is declared... yes
checking to see if getenv can be redefined... no
checking if getcwd() will dynamically allocate memory with 0 size... no
checking for presence of POSIX-style sigsetjmp/siglongjmp... missing
checking whether or not strcoll and strcmp differ... no
checking for standard-conformant snprintf... no
checking for standard-conformant vsnprintf... yes
checking for standard-conformant putenv declaration... yes
checking for standard-conformant unsetenv declaration... yes
checking for printf floating point output in hex notation... no
checking if signal handlers must be reinstalled when invoked... yes
checking for presence of necessary job control definitions... missing
checking for presence of named pipes... missing
checking whether termios.h defines TIOCGWINSZ... yes
checking for TIOCSTAT in sys/ioctl.h... yes
checking for FIONREAD in sys/ioctl.h... yes
checking whether WCONTINUED flag to waitpid is unavailable or available but broken... yes
checking for speed_t in sys/types.h... no
checking whether getpw functions are declared in pwd.h... yes
checking for unusable real-time signals due to large values... no
checking for tgetent... no
checking for tgetent in -ltermcap... yes
checking which library has the termcap functions... using libtermcap
checking whether /dev/fd is available... standard
checking whether /dev/stdin stdout stderr are available... present
checking for default mail directory... /var/mail
checking shared object configuration for loadable builtins... supported
configure: creating ./config.status
config.status: creating Makefile
config.status: creating builtins/Makefile
config.status: creating lib/readline/Makefile
config.status: creating lib/glob/Makefile
config.status: creating lib/intl/Makefile
config.status: creating lib/malloc/Makefile
config.status: creating lib/sh/Makefile
config.status: creating lib/termcap/Makefile
config.status: creating lib/tilde/Makefile
config.status: creating doc/Makefile
config.status: creating support/Makefile
config.status: creating po/Makefile.in
config.status: creating examples/loadables/Makefile
config.status: creating examples/loadables/perl/Makefile
config.status: creating config.h
config.status: executing default-1 commands
config.status: creating po/POTFILES
config.status: creating po/Makefile
config.status: executing default commands
bison -y -d ./parse.y
conflicts: 1 shift/reduce
touch parser-built
rm -f mksyntax
gcc  -DPROGRAM='"bash"' -DCONF_HOSTTYPE='"arm"' -DCONF_OSTYPE='"darwin23.2.0"' -DCONF_MACHTYPE='"arm-apple-darwin23.2.0"' -DCONF_VENDOR='"apple"' -DLOCALEDIR='"/usr/local/share/locale"' -DPACKAGE='"bash"' -DSHELL -DHAVE_CONFIG_H -DMACOSX   -I.  -I. -I./include -I./lib -I./lib/intl -I/tmp/bash2py/bash-4.3.30/lib/intl  -I/opt/homebrew/opt/node@20/include -g -O2  -L/opt/homebrew/opt/node@20/lib    -g -O2  -g -O2  -o mksyntax ./mksyntax.c 
./mksyntax.c:108:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
cdesc (i)
^
./mksyntax.c:152:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
getcstr (f)
^
./mksyntax.c:164:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
addcstr (str, flag)
^
./mksyntax.c:186:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
addcchar (c, flag)
^
./mksyntax.c:255:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
dump_lflags (fp, ind)
^
./mksyntax.c:281:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
wcomment (fp, i)
^
./mksyntax.c:293:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
dump_lsyntax (fp)
^
./mksyntax.c:314:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
main(argc, argv)
^
8 warnings generated.
rm -f syntax.c
./mksyntax -o syntax.c
/bin/sh ./support/mkversion.sh -b -S . -s release -d 4.3 -o newversion.h \
        && mv newversion.h version.h
gcc  -DPROGRAM='"bash"' -DCONF_HOSTTYPE='"arm"' -DCONF_OSTYPE='"darwin23.2.0"' -DCONF_MACHTYPE='"arm-apple-darwin23.2.0"' -DCONF_VENDOR='"apple"' -DLOCALEDIR='"/usr/local/share/locale"' -DPACKAGE='"bash"' -DSHELL -DHAVE_CONFIG_H -DMACOSX   -I.  -I. -I./include -I./lib -I./lib/intl -I/tmp/bash2py/bash-4.3.30/lib/intl  -I/opt/homebrew/opt/node@20/include -g -O2  -DBUILDTOOL -c -o buildversion.o ./version.c
./version.c:83:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
show_shell_version (extended)
^
1 warning generated.
gcc  -DPROGRAM='"bash"' -DCONF_HOSTTYPE='"arm"' -DCONF_OSTYPE='"darwin23.2.0"' -DCONF_MACHTYPE='"arm-apple-darwin23.2.0"' -DCONF_VENDOR='"apple"' -DLOCALEDIR='"/usr/local/share/locale"' -DPACKAGE='"bash"' -DSHELL -DHAVE_CONFIG_H -DMACOSX   -I.  -I. -I./include -I./lib -I./lib/intl -I/tmp/bash2py/bash-4.3.30/lib/intl  -I/opt/homebrew/opt/node@20/include -g -O2  -L/opt/homebrew/opt/node@20/lib    -g -O2  -g -O2  -o bashversion ./support/bashversion.c buildversion.o 
./support/bashversion.c:70:16: warning: using the result of an assignment as a condition without parentheses [-Wparentheses]
  if (progname = strrchr (argv[0], '/'))
      ~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
./support/bashversion.c:70:16: note: place parentheses around the assignment to silence this warning
  if (progname = strrchr (argv[0], '/'))
               ^
      (                                )
./support/bashversion.c:70:16: note: use '==' to turn this assignment into an equality comparison
  if (progname = strrchr (argv[0], '/'))
               ^
               ==
./support/bashversion.c:63:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
main (argc, argv)
^
2 warnings generated.

      ***********************************************************
      *                                                         *
      * bash2py version 3.5 Dec 28 2023 19:05:59
Hacked from GNU bash 4.3.30(1)-release (arm-apple-darwin23.2.0)
      *                                                         *
      ***********************************************************

making lib/intl/libintl.a in ./lib/intl
cp ./libgnuintl.h.in libgnuintl.h
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  bindtextdom.c
In file included from bindtextdom.c:34:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
bindtextdom.c:103:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
set_binding_values (domainname, dirnamep, codesetp)
^
bindtextdom.c:353:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
BINDTEXTDOMAIN (domainname, dirname)
^
bindtextdom.c:87:25: note: expanded from macro 'BINDTEXTDOMAIN'
# define BINDTEXTDOMAIN libintl_bindtextdomain
                        ^
bindtextdom.c:364:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
BIND_TEXTDOMAIN_CODESET (domainname, codeset)
^
bindtextdom.c:88:34: note: expanded from macro 'BIND_TEXTDOMAIN_CODESET'
# define BIND_TEXTDOMAIN_CODESET libintl_bind_textdomain_codeset
                                 ^
4 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  dcgettext.c
In file included from dcgettext.c:25:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
dcgettext.c:49:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
DCGETTEXT (domainname, msgid, category)
^
dcgettext.c:42:20: note: expanded from macro 'DCGETTEXT'
# define DCGETTEXT libintl_dcgettext
                   ^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  dgettext.c
In file included from dgettext.c:27:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
dgettext.c:51:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
DGETTEXT (domainname, msgid)
^
dgettext.c:44:19: note: expanded from macro 'DGETTEXT'
# define DGETTEXT libintl_dgettext
                  ^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  gettext.c
In file included from gettext.c:32:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
gettext.c:57:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
GETTEXT (msgid)
^
gettext.c:49:18: note: expanded from macro 'GETTEXT'
# define GETTEXT libintl_gettext
                 ^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  finddomain.c
In file included from finddomain.c:35:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
finddomain.c:52:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_find_domain (dirname, locale, domainname, domainbinding)
^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  loadmsgcat.c
In file included from loadmsgcat.c:90:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
In file included from loadmsgcat.c:91:
./hash-string.h:41:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
hash_string (str_param)
^
loadmsgcat.c:509:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
get_sysdep_segment_value (name)
^
loadmsgcat.c:767:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_init_domain_conv (domain_file, domain, domainbinding)
^
loadmsgcat.c:886:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_free_domain_conv (domain)
^
loadmsgcat.c:907:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_load_domain (domain_file, domainbinding)
^
6 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  localealias.c
In file included from localealias.c:65:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
localealias.c:153:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_expand_alias (name)
^
localealias.c:220:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
read_alias_file (fname, fname_len)
^
localealias.c:395:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
alias_compare (map1, map2)
^
4 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  textdomain.c
In file included from textdomain.c:33:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
textdomain.c:82:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
TEXTDOMAIN (domainname)
^
textdomain.c:72:21: note: expanded from macro 'TEXTDOMAIN'
# define TEXTDOMAIN libintl_textdomain
                    ^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  l10nflist.c
l10nflist.c:93:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
argz_count__ (argz, len)
^
l10nflist.c:121:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
argz_stringify__ (argz, len, sep)
^
l10nflist.c:149:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
argz_next__ (argz, argz_len, entry)
^
l10nflist.c:176:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
pop (x)
^
l10nflist.c:190:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_make_l10nflist (l10nfile_list, dirlist, dirlist_len, mask, language,
^
l10nflist.c:399:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_normalize_codeset (codeset, name_len)
^
6 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  explodename.c
explodename.c:44:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_find_language (name)
^
explodename.c:56:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_explode_name (name, language, modifier, territory, codeset,
^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  dcigettext.c
In file included from dcigettext.c:92:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
In file included from dcigettext.c:99:
./hash-string.h:41:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
hash_string (str_param)
^
dcigettext.c:157:7: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C2x, conflicting with a previous declaration [-Wdeprecated-non-prototype]
char *getcwd ();
      ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/unistd.h:449:7: note: conflicting prototype is here
char    *getcwd(char *, size_t);
         ^
In file included from dcigettext.c:431:
./eval-plural.h:33:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
plural_eval (pexp, n)
^
dcigettext.c:437:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
DCIGETTEXT (domainname, msgid1, msgid2, plural, n, category)
^
dcigettext.c:388:21: note: expanded from macro 'DCIGETTEXT'
# define DCIGETTEXT libintl_dcigettext
                    ^
dcigettext.c:737:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_find_msg (domain_file, domainbinding, msgid, lengthp)
^
dcigettext.c:1048:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
plural_lookup (domain, n, translation, translation_len)
^
dcigettext.c:1089:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
category_to_name (category)
^
dcigettext.c:1150:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
guess_category_value (category, categoryname)
^
dcigettext.c:1205:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
mempcpy (dest, src, n)
^
10 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  dcngettext.c
In file included from dcngettext.c:25:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
dcngettext.c:49:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
DCNGETTEXT (domainname, msgid1, msgid2, n, category)
^
dcngettext.c:42:21: note: expanded from macro 'DCNGETTEXT'
# define DCNGETTEXT libintl_dcngettext
                    ^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  dngettext.c
In file included from dngettext.c:27:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
dngettext.c:51:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
DNGETTEXT (domainname, msgid1, msgid2, n)
^
dngettext.c:44:20: note: expanded from macro 'DNGETTEXT'
# define DNGETTEXT libintl_dngettext
                   ^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  ngettext.c
In file included from ngettext.c:32:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
ngettext.c:59:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
NGETTEXT (msgid1, msgid2, n)
^
ngettext.c:51:19: note: expanded from macro 'NGETTEXT'
# define NGETTEXT libintl_ngettext
                  ^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  plural.c
/usr/src/local/bash/bash-20080814/lib/intl/plural.y:77:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
new_exp (nargs, op, args)
^
/usr/src/local/bash/bash-20080814/lib/intl/plural.y:109:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
new_exp_0 (op)
^
/usr/src/local/bash/bash-20080814/lib/intl/plural.y:116:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
new_exp_1 (op, right)
^
/usr/src/local/bash/bash-20080814/lib/intl/plural.y:127:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
new_exp_2 (op, left, right)
^
/usr/src/local/bash/bash-20080814/lib/intl/plural.y:140:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
new_exp_3 (op, bexp, tbranch, fbranch)
^
/usr/src/local/bash/bash-20080814/lib/intl/plural.y:235:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
FREE_EXPRESSION (exp)
^
./plural-exp.h:103:26: note: expanded from macro 'FREE_EXPRESSION'
# define FREE_EXPRESSION libintl_gettext_free_exp
                         ^
/usr/src/local/bash/bash-20080814/lib/intl/plural.y:262:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
yylex (lval, pexp)
^
plural.c:51:17: note: expanded from macro 'yylex'
#define yylex   __gettextlex
                ^
/usr/src/local/bash/bash-20080814/lib/intl/plural.y:407:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
yyerror (str)
^
plural.c:52:17: note: expanded from macro 'yyerror'
#define yyerror __gettexterror
                ^
8 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  plural-exp.c
plural-exp.c:101:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
EXTRACT_PLURAL_EXPRESSION (nullentry, pluralp, npluralsp)
^
./plural-exp.h:106:36: note: expanded from macro 'EXTRACT_PLURAL_EXPRESSION'
# define EXTRACT_PLURAL_EXPRESSION libintl_gettext_extract_plural
                                   ^
1 warning generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  localcharset.c
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  relocatable.c
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  localename.c
localename.c:386:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_locale_name (category, categoryname)
^
1 warning generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  log.c
log.c:33:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
print_escaped (stream, str)
^
log.c:57:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
_nl_log_untranslated (logfilename, domainname, msgid1, msgid2, plural)
^
2 warnings generated.
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  osdep.c
gcc -c -DLOCALEDIR=\"/usr/local/share/locale\" -DLOCALE_ALIAS_PATH=\"/usr/local/share/locale\" -DLIBDIR=\"/usr/local/libdata\" -DIN_LIBINTL -DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"/usr/local/lib\" -DNO_XMALLOC -Dset_relocation_prefix=libintl_set_relocation_prefix -Drelocate=libintl_relocate -DDEPENDS_ON_LIBICONV=1 -DHAVE_CONFIG_H -DSHELL -I. -I. -I/tmp/bash2py/bash-4.3.30 -I../.. -I/opt/homebrew/opt/node@20/include -g -O2  intl-compat.c
In file included from intl-compat.c:25:
./gettextP.h:73:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
SWAP (i)
^
intl-compat.c:62:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
gettext (msgid)
^
intl-compat.c:71:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
dgettext (domainname, msgid)
^
intl-compat.c:81:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
dcgettext (domainname, msgid, category)
^
intl-compat.c:92:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
ngettext (msgid1, msgid2, n)
^
intl-compat.c:103:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
dngettext (domainname, msgid1, msgid2, n)
^
intl-compat.c:115:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
dcngettext (domainname, msgid1, msgid2, n, category)
^
intl-compat.c:128:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
textdomain (domainname)
^
intl-compat.c:137:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
bindtextdomain (domainname, dirname)
^
intl-compat.c:147:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
bind_textdomain_codeset (domainname, codeset)
^
10 warnings generated.
rm -f libintl.a
ar cr libintl.a bindtextdom.o dcgettext.o dgettext.o gettext.o finddomain.o loadmsgcat.o localealias.o textdomain.o l10nflist.o explodename.o dcigettext.o dcngettext.o dngettext.o ngettext.o plural.o plural-exp.o localcharset.o relocatable.o localename.o log.o osdep.o intl-compat.o
ranlib libintl.a
cmp libgnuintl.h libintl.h || cp libgnuintl.h libintl.h
cmp: libintl.h: No such file or directory
/bin/sh ./config.charset 'arm-apple-darwin23.2.0' > t-charset.alias
mv t-charset.alias charset.alias
sed -e '/^#/d' -e 's/@''PACKAGE''@/@PACKAGE@/g' ./ref-add.sin > t-ref-add.sed
mv t-ref-add.sed ref-add.sed
sed -e '/^#/d' -e 's/@''PACKAGE''@/@PACKAGE@/g' ./ref-del.sin > t-ref-del.sed
mv t-ref-del.sed ref-del.sed
rm -f shell.o
gcc  -DPROGRAM='"bash"' -DCONF_HOSTTYPE='"arm"' -DCONF_OSTYPE='"darwin23.2.0"' -DCONF_MACHTYPE='"arm-apple-darwin23.2.0"' -DCONF_VENDOR='"apple"' -DLOCALEDIR='"/usr/local/share/locale"' -DPACKAGE='"bash"' -DSHELL -DHAVE_CONFIG_H -DMACOSX   -I.  -I. -I./include -I./lib -I./lib/intl -I/tmp/bash2py/bash-4.3.30/lib/intl  -I/opt/homebrew/opt/node@20/include -g -O2  -c shell.c
shell.c:758:7: error: call to undeclared function 'get_tty_state'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
      get_tty_state ();
      ^
shell.c:769:3: error: call to undeclared function 'initialize_translator'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
  initialize_translator(shell_scriptP);
  ^
shell.c:769:3: note: did you mean 'initialize_traps'?
./trap.h:64:13: note: 'initialize_traps' declared here
extern void initialize_traps __P((void));
            ^
shell.c:773:3: error: call to undeclared function 'close_translator'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
  close_translator();
  ^
shell.c:363:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
main (argc, argv, env)
^
shell.c:779:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
parse_long_options (argv, arg_start, arg_end)
^
shell.c:834:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
parse_shell_options (argv, arg_start, arg_end)
^
shell.c:859:28: warning: using the result of an assignment as a condition without parentheses [-Wparentheses]
      while (arg_character = arg_string[i++])
             ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
shell.c:859:28: note: place parentheses around the assignment to silence this warning
      while (arg_character = arg_string[i++])
                           ^
             (                              )
shell.c:859:28: note: use '==' to turn this assignment into an equality comparison
      while (arg_character = arg_string[i++])
                           ^
                           ==
shell.c:925:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
exit_shell (s)
^
shell.c:970:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
sh_exit (s)
^
shell.c:985:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
subshell_exit (s)
^
shell.c:1027:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
execute_env_file (env_file)
^
shell.c:1179:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
shell_is_restricted (name)
^
shell.c:1200:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
maybe_make_restricted (name)
^
shell.c:1332:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
run_one_command (command)
^
shell.c:1363:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
bind_args (argv, arg_start, arg_end, start_index)
^
shell.c:1378:14: warning: passing arguments to 'list_reverse' without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
      args = REVERSE_LIST (args, WORD_LIST *);
             ^
./general.h:129:46: note: expanded from macro 'REVERSE_LIST'
  ((list && list->next) ? (type)list_reverse ((GENERIC_LIST *)list) \
                                             ^
shell.c:1425:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
open_shell_script (script_name)
^
shell.c:1596:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
unset_bash_input (check_zero)
^
shell.c:1622:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
set_shell_name (argv0)
^
shell.c:1768:3: error: call to undeclared function 'initialize_job_control'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
  initialize_job_control (jobs_m_flag);
  ^
shell.c:1842:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
show_shell_usage (fp, extra)
^
shell.c:1881:20: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
      fprintf (fp, _("Use the `bashbug' command to report bugs.\n"));
                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./bashintl.h:36:18: note: expanded from macro '_'
#define _(msgid)        gettext(msgid)
                        ^~~~~~~~~~~~~~
./lib/intl/libintl.h:128:18: note: expanded from macro 'gettext'
# define gettext libintl_gettext
                 ^
shell.c:1881:20: note: treat the string as an argument to avoid this
      fprintf (fp, _("Use the `bashbug' command to report bugs.\n"));
                   ^
                   "%s", 
./bashintl.h:36:18: note: expanded from macro '_'
#define _(msgid)        gettext(msgid)
                        ^
./lib/intl/libintl.h:128:18: note: expanded from macro 'gettext'
# define gettext libintl_gettext
                 ^
shell.c:1886:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
add_shopt_to_alist (opt, on_or_off)
^
19 warnings and 4 errors generated.
make: *** [shell.o] Error 1
ls: cannot access 'bash2pyengine': No such file or directory
/tmp/bash2py$ 
$ gcc --version
Apple clang version 15.0.0 (clang-1500.1.0.2.5)
Target: arm64-apple-darwin23.2.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin

I tried compiling regular Bash 4.3 like this:

cd /tmp
git clone https://git.savannah.gnu.org/git/bash.git
cd bash
git checkout ca6a2ba # Bash-4.3 patch 30
./configure && make

and got similar errors:

gcc  -DPROGRAM='"bash"' -DCONF_HOSTTYPE='"arm"' -DCONF_OSTYPE='"darwin23.2.0"' -DCONF_MACHTYPE='"arm-apple-darwin23.2.0"' -DCONF_VENDOR='"apple"' -DLOCALEDIR='"/usr/local/share/locale"' -DPACKAGE='"bash"' -DSHELL -DHAVE_CONFIG_H -DMACOSX   -I.  -I. -I./include -I./lib -I./lib/intl -I/tmp/bash/lib/intl -I/opt/homebrew/opt/node@20/include -g -O2 -c shell.c
shell.c:745:7: error: call to undeclared function 'get_tty_state'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
      get_tty_state ();
      ^
shell.c:356:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
main (argc, argv, env)
^
shell.c:760:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
parse_long_options (argv, arg_start, arg_end)
^
shell.c:815:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
parse_shell_options (argv, arg_start, arg_end)
^
shell.c:840:28: warning: using the result of an assignment as a condition without parentheses [-Wparentheses]
      while (arg_character = arg_string[i++])
             ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
shell.c:840:28: note: place parentheses around the assignment to silence this warning
      while (arg_character = arg_string[i++])
                           ^
             (                              )
shell.c:840:28: note: use '==' to turn this assignment into an equality comparison
      while (arg_character = arg_string[i++])
                           ^
                           ==
shell.c:906:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
exit_shell (s)
^
shell.c:951:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
sh_exit (s)
^
shell.c:966:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
subshell_exit (s)
^
shell.c:1008:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
execute_env_file (env_file)
^
shell.c:1160:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
shell_is_restricted (name)
^
shell.c:1181:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
maybe_make_restricted (name)
^
shell.c:1313:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
run_one_command (command)
^
shell.c:1344:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
bind_args (argv, arg_start, arg_end, start_index)
^
shell.c:1355:14: warning: passing arguments to 'list_reverse' without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
      args = REVERSE_LIST (args, WORD_LIST *);
             ^
./general.h:129:46: note: expanded from macro 'REVERSE_LIST'
  ((list && list->next) ? (type)list_reverse ((GENERIC_LIST *)list) \
                                             ^
shell.c:1402:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
open_shell_script (script_name)
^
shell.c:1573:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
unset_bash_input (check_zero)
^
shell.c:1599:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
set_shell_name (argv0)
^
shell.c:1745:3: error: call to undeclared function 'initialize_job_control'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
  initialize_job_control (jobs_m_flag);
  ^
shell.c:1819:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
show_shell_usage (fp, extra)
^
shell.c:1858:20: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
      fprintf (fp, _("Use the `bashbug' command to report bugs.\n"));
                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./bashintl.h:36:18: note: expanded from macro '_'
#define _(msgid)        gettext(msgid)
                        ^~~~~~~~~~~~~~
./lib/intl/libintl.h:128:18: note: expanded from macro 'gettext'
# define gettext libintl_gettext
                 ^
shell.c:1858:20: note: treat the string as an argument to avoid this
      fprintf (fp, _("Use the `bashbug' command to report bugs.\n"));
                   ^
                   "%s", 
./bashintl.h:36:18: note: expanded from macro '_'
#define _(msgid)        gettext(msgid)
                        ^
./lib/intl/libintl.h:128:18: note: expanded from macro 'gettext'
# define gettext libintl_gettext
                 ^
shell.c:1863:1: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype]
add_shopt_to_alist (opt, on_or_off)
^
19 warnings and 2 errors generated.
make: *** [shell.o] Error 1

I can compile the latest Bash (commit 4b0f8ba2) though. Bash commit 8868edaf (Bash 5.1) is the first commit I can compile on my machine. Looking at the Homebrew formula for older Bash versions

https://github.com/Homebrew/homebrew-core/blob/9a9d87761e8ae0202440278c5835dd6805fa698c/Formula/bash.rb

it seems like there were some patches that might help here, but they 404 now (and also ARM64-based Macs didn't exist back then). They were probably these patches:

https://ftp.gnu.org/gnu/bash/bash-4.3-patches/bash43-030

The ideal way to fix this would be to rebase bash2py onto the most recent Bash version (Bash 5.2).

verhovsky commented 10 months ago

I disabled implicit definitions breaking the compilation by editing Makefile.in like this:

diff --git a/bash-4.3.30/Makefile.in b/bash-4.3.30/Makefile.in
index f4b59b2..0e3fee3 100644
--- a/bash-4.3.30/Makefile.in
+++ b/bash-4.3.30/Makefile.in
@@ -141,7 +141,7 @@ LIBS_FOR_BUILD =
 STATIC_LD = @STATIC_LD@
 LOCAL_LDFLAGS = @LOCAL_LDFLAGS@

-SYSTEM_FLAGS = -DPROGRAM='"$(Program)"' -DCONF_HOSTTYPE='"$(Machine)"' -DCONF_OSTYPE='"$(OS)"' -DCONF_MACHTYPE='"$(MACHTYPE)"' -DCONF_VENDOR='"$(VENDOR)"' $(LOCALE_DEFS)
+SYSTEM_FLAGS = -DPROGRAM='"$(Program)"' -DCONF_HOSTTYPE='"$(Machine)"' -DCONF_OSTYPE='"$(OS)"' -DCONF_MACHTYPE='"$(MACHTYPE)"' -DCONF_VENDOR='"$(VENDOR)"' $(LOCALE_DEFS) -Wno-implicit-function-declaration

 BASE_CCFLAGS = $(PROFILE_FLAGS) $(SYSTEM_FLAGS) $(LOCAL_DEFS) \
          $(DEFS) $(LOCAL_CFLAGS) $(INCLUDES) $(MAKEBASH2PY)

but then I get these errors:

rm -f siglist.o
gcc  -DPROGRAM='"bash"' -DCONF_HOSTTYPE='"arm"' -DCONF_OSTYPE='"darwin23.2.0"' -DCONF_MACHTYPE='"arm-apple-darwin23.2.0"' -DCONF_VENDOR='"apple"' -DLOCALEDIR='"/usr/local/share/locale"' -DPACKAGE='"bash"' -Wno-implicit-function-declaration -DSHELL -DHAVE_CONFIG_H -DMACOSX   -I.  -I. -I./include -I./lib -I./lib/intl -I/Users/space/code/third-party/bash2py/bash-4.3.30/lib/intl  -I/opt/homebrew/opt/node@20/include -g -O2  -c siglist.c
In file included from siglist.c:36:
In file included from ./xmalloc.h:25:
In file included from ./bashansi.h:28:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/string.h:134:7: error: expected identifier or '('
char    *strsignal(int __sig);
         ^
./siglist.h:37:27: note: expanded from macro 'strsignal'
#  define strsignal(sig) (char *)sys_siglist[sig]
                          ^
In file included from siglist.c:36:
In file included from ./xmalloc.h:25:
In file included from ./bashansi.h:28:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/string.h:134:7: error: expected ')'
./siglist.h:37:27: note: expanded from macro 'strsignal'
#  define strsignal(sig) (char *)sys_siglist[sig]
                          ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/string.h:134:7: note: to match this '('
./siglist.h:37:26: note: expanded from macro 'strsignal'
#  define strsignal(sig) (char *)sys_siglist[sig]
                         ^
siglist.c:38:7: error: redefinition of 'sys_siglist' with a different type: 'char *[32]' vs 'const char *const[32]'
char *sys_siglist[NSIG];
      ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: previous declaration is here
extern __const char *__const sys_siglist[NSIG];
                             ^
siglist.c:46:20: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
    sys_siglist[i] = (char *)0x0;
    ~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:48:18: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[0] = _("Bogus signal");
  ~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:51:23: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGHUP] = _("Hangup");
  ~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:55:23: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGINT] = _("Interrupt");
  ~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:59:24: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGQUIT] = _("Quit");
  ~~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:63:23: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGILL] = _("Illegal instruction");
  ~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:67:24: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGTRAP] = _("BPT trace/trap");
  ~~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:75:24: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGABRT] = _("ABORT instruction");
  ~~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:79:23: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGEMT] = _("EMT instruction");
  ~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:83:23: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGFPE] = _("Floating point exception");
  ~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:87:24: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGKILL] = _("Killed");
  ~~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:91:23: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGBUS] = _("Bus error");
  ~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:95:24: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGSEGV] = _("Segmentation fault");
  ~~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:99:23: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGSYS] = _("Bad system call");
  ~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:103:24: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGPIPE] = _("Broken pipe");
  ~~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
siglist.c:107:24: error: cannot assign to variable 'sys_siglist' with const-qualified type 'const char *const[32]'
  sys_siglist[SIGALRM] = _("Alarm clock");
  ~~~~~~~~~~~~~~~~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/signal.h:70:30: note: variable 'sys_siglist' declared const here
extern __const char *__const sys_siglist[NSIG];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
make: *** [siglist.o] Error 1

Googling "error: expected identifier or '(' char *strsignal(int __sig);" I ended up on this thread

https://www.mail-archive.com/bug-bash@gnu.org/msg25109.html

I tried to apply the change in the first patch suggested in that thread and it changed the error message in the same way

[...]
snprintf.c:1704:1: error: expected parameter declarator
vsnprintf(char *string, size_t length, const char *format, va_list args)
[...]

then I tried the changes in the combined patch

diff --git a/bash-4.3.30/aclocal.m4 b/bash-4.3.30/aclocal.m4
index a947272..5a849ed 100644
--- a/bash-4.3.30/aclocal.m4
+++ b/bash-4.3.30/aclocal.m4
@@ -300,7 +300,8 @@ AC_DEFUN(BASH_FUNC_STRSIGNAL,
 [AC_MSG_CHECKING([for the existence of strsignal])
 AC_CACHE_VAL(bash_cv_have_strsignal,
 [AC_TRY_LINK([#include <sys/types.h>
-#include <signal.h>],
+#include <signal.h>
+#include <string.h>],
 [char *s = (char *)strsignal(2);],
  bash_cv_have_strsignal=yes, bash_cv_have_strsignal=no)])
 AC_MSG_RESULT($bash_cv_have_strsignal)
@@ -4069,6 +4070,7 @@ AC_DEFUN([BASH_FUNC_SNPRINTF],
     AC_CACHE_CHECK([for standard-conformant snprintf], [bash_cv_func_snprintf],
       [AC_TRY_RUN([
 #include <stdio.h>
+#include <stdlib.h>

 main()
 {

and ran autoconf and it seems to work.