Still around: Compile error in CVS HEAD from 1999-04-10 20:30
CEST
Paul
PELaufer at csupomona.edu
Sun Apr 11 03:31:55 GMT 1999
On Sun, 11 Apr 1999, Florian Laws wrote:
> I posted this compile error a few days ago,
> but it seems to have been ignored.
>
> My setup:
> Debian Linux 2.2, Kernel 2.2.4-ac6, glibc 2.1.1, egcs 2.91.63
>
> --- snip ---
>
> Linking bin/make_smbcodepage
> Compiling utils/debug2html.c
> utils/debug2html.c:42: initializer element is not constant
> utils/debug2html.c:43: initializer element is not constant
> make: *** [utils/debug2html.o] Error 1
>
> --- snip ---
>
> These are the lines
>
> FILE *infile = stdin;
> FILE *outfile = stdout;
>
> which is odd, at least I don't see why the compiler complains about that.
>
> Thanks,
>
> Florian
I know that at least on glibc 2.1 systems stdin, stdout and stderr are not
defined as constants so they cannot be used as an initializer for a global
variable. The solution is to move the initialization into a function
somewhere.
-Paul Laufer
More information about the samba-technical
mailing list