Subject: Re: mail/metamail/patches/patch-as breaks this package on Solaris
To: None <,>
From: None <>
List: tech-pkg
Date: 02/06/2006 02:11:15
On Sun, 5 Feb 2006 16:45:31 +0100 wrote:

> On Thu, Feb 02, 2006 at 10:49:42AM +0000, wrote:
> > I get this with the new patch
> [more messing with system headers]
> Once again, updated patch attached.
> Joerg

I get the same error when building with gcc (sunpro compiles OK)

putenv.c: In function `putenv':
putenv.c:40: error: argument `string' doesn't match prototype
/usr/include/stdlib.h:138: error: prototype declaration
*** Error code 1

Why are you so keen to apply any kind of patch to putenv.c file? What does your
patch suppose to fix? Does it break on other systems without your patch?

/usr/include/stdlib.h defines the following function:

int putenv(char *string);

but putenv.c file includes <stdlib.h> AND later declares a function with the
same name:

putenv (string)
     const char *string;

That's where the error is coming from. Your patch removes some #ifdef tests,
which results in <stdlib.h> being included, which breaks things.