[patch] fix cpp warnings from recent commits

Rob Landley rob at landley.net
Fri Jun 16 04:27:29 UTC 2006


On Thursday 15 June 2006 10:15 pm, Erik Hovland wrote:
> On Thu, Jun 15, 2006 at 08:53:31PM -0400, Rob Landley wrote:
> > On Thursday 15 June 2006 6:49 pm, Erik Hovland wrote:
> > > Recent commits of freeramdisk.c, fsck_minix.c, mkfs_minix.c and
> > > mkswap.c introduced some cpp warnings associated to macros which are
> > > typically provided on linux systems with semi-modern kernels and libcs.
> > >
> > > This patch wraps the #define in question with corresponding #ifndef.
> >
> > 2) Which of the four defines you wrap is "the define"?
>
> There are four files. Each attempts to define a different thing that is
> already defined by either a linux header or a libc header.
>
> > 3) If they're alrady defined by the headers, then just yank 'em.
>
> Will rework the patch to do just that.

I got it.  Thanks for the catch, I should have mentioned you in the checkin 
comment.  (It's late, I've done about as much as I'm going to today and will 
have to pick this up again saturday...)

> > 4) I'm not seeing these warnings.  Where are you seeing these warnings?
>
> I typically use a allyesconfig - selinux. When I compile with that, I
> see a warning for each of the files in question about trying to redefine
> each of the macros that have been wrapped.

Nah, apparently the dependencies are just wonky (already on my todo list to 
redo that someday) and they didn't get rebuild when the headers they 
#included changed...

> E

Rob
-- 
Never bet against the cheap plastic solution.



More information about the busybox mailing list