Jakub Wilk wrote:
>/«BUILDDIR»/ksh-93u+20120801/src/lib/libast/comp/tmpnam.c:48:14: error: 
>storage size of 'buf' isn't known
> static char buf[L_tmpnam];
>             ^

Strange error, this is a name-collision error. L_tmpnam was already 
used for something else, something that obviously was not a number. 
Please find attached patch that avoids the name-collision simply by
replacing the name L_tmpnam in this file with something else. 

In sid-chroot as-it-is-today and gcc version 5.2.1 20150730 (Debian
5.2.1-14) I now get /bin/ksh93 that starts and .. looks like a shell
to me but I'm no Korn shell user so someone who knows how it should
behave might want to run a test-suite if there is any to verify that
this program really works as expected. 

This package is scary, instead of using io-functions from libc, this 
seems to partly implement its own io-functions that are normally found
from libc. For linux libc the L_tmpnam is #defined in
/usr/include/i386-linux-gnu/bits/stdio_lim.h but this package does not
use the same implementation of tmpnam() - anyway here the size of this
static buffer is set to be longer than the one in stdio_lim.h so we
should be safe for the time being.

--
Antti Järvinen

Attachment: gcc5_compiler_fix.patch
Description: gcc5 compiler patch for ksh

Reply via email to