Re: [Yaffs] PATCH: Make YAFFS compile on NetBSD

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Charles Manning
Date:  
To: yaffs
Subject: Re: [Yaffs] PATCH: Make YAFFS compile on NetBSD
On Wednesday 31 October 2007 11:02:25 Ian McDonnell wrote:
> On Tuesday 30 October 2007 17:01, Martin Fouts wrote:
> > The attached patch is long but the bulk of it consists of
> > adding yaffs_ in front of all the list_ bits so as to avoid
> > name collision.
> >
> > The remainder of it does the following:
> >
> > 1) Add initializers to variable declarations to get gcc to
> > shut up about them. 2) Removes unused declarations to get gcc
> > to shut up about them. 3) Changes some variable names in inner
> > blocks to get gcc to shut up about aliasing 4) Changes a
> > format to match types (%d -> %lu) to get gcc to shut up about
> > wrong format strings. 5) Reference yaffs_qsort.h in
> > yaffs_qsort.c to get gcc to shut up about no prototype. 6)
> > Ifdef out a pair of functions in yaffs_guts.c that aren't used
> > in NetBSD, using the new CONFIG_NETBSD flag 7) Add
> > CONFIG_NETBSD flag and reference it in yportenv.h to cause
> > ynetbsdenv.h to be included in a NetBSD build.
> >
> > I have not included ynetbsdenv.h in the patch, as I am
> > releasing the patch to Aleph1, but I don't yet have the
> > authority to release parts of the actual netbsd port.
> >
> > All of the changes made *should* be cosmetic on a yaffs Linux
> > or yaffs direct port, but I don't have either to test against.
>
> Unfortunately not, there are a whole bunch of problems with
> missing types for the list macros. I tried something quick to
> fix it and it didn't work. I'll tidy up the whole yportenv.h vs.
> devextras.h thing for the linux builds and see how that sits,
> then lets make a new patch for your changes.



The whole yportenv business is a bit messy and is something I want to work
through in the next few days too. There are other things that get broken in
the direct port too, like conflicting values for O_CREAT etc in certain build
contitions.

When I first wrote this stuff I was not expecting such a lot of porting and
what was done was basically hackery to enable a few simple ports. I guess
this is a good problem to have :-).

-- Charles