[parted-devel] parted port to FreeBSD

Viktor Vasilev viktor.vasilev at stud.tu-darmstadt.de
Wed Apr 26 10:41:07 UTC 2006


On Wednesday 26 April 2006 10:37 leslie.polzer at gmx.net wrote:
> Hello Viktor, hello Robert,
>
> On Wed, Apr 26, 2006 at 02:13:11AM +0200, Viktor Vasilev wrote:
> > Robert Millan and I are working on a port of GNU parted to FreeBSD and
> > Debian GNU/kFreeBSD. A patch against trunk is attached, also available
> > from
> >
> > Here is some commentary to the changes:
> >
> > - disable sigaction, since parts of ui.c contain linux-specific code.
>
> Can you explain this is more detail? Do I get that right in that
> sigaction() is available on FreeBSD, but with missing features?

Yes, sigaction is there, only the meaning of info->si_code isn't compatible 
with linux. Part of the defines are in machine/trap.h, and the others in 
signal.h:

 http://fxr.watson.org/fxr/source/i386/include/trap.h?v=RELENG60
 http://fxr.watson.org/fxr/source/sys/signal.h?v=RELENG60

> > - a weird screen corruption bug in table.c:table_render_row():
>
> I suppose this only occurs with FreeBSD?
>   Everytime?

For the time I tested, it appeared evey time (in gdb too).

> >   Old value = 0x80565a0 "Number Start End Size Type File system
> >   Flags \n" New value = 0x805fe80 "Number Start End Size
> >   Tyf1À°\1779E\004\177\003\213E\004)E\004f\001\005Ç\004\020"
> >
> > The ptr arg to realloc has obviously changed.
>
> This is expected behaviour -- see realloc(3).

I'll try to catch up on the realloc semantics :)

> > I don't know what the propper fix is.
>
> Tracking "newsize" would probably show the problem.

Although I don't understand how newsize could be the problem, i'll trace it 
and get back to you.

> > - Some of the code in freebsd.c comes from various FreeBSD utils.
> > Maybe it should be rewritten so it can be GPL'ed?
>
> If I'm right we cannot accept BSD code, so, for official inclusion, we
> would have to rewrite these parts.

It shouldn't be that hard to rewrite the few parts. I'll work on it ASAP.


Cheers,
Vik
-- 
PGP Key: 0xE09DC8D8/6799 4011 EBDE 6412 05A1 090C DBDF 5887 E09D C8D8
Signed/encrypted mail welcome!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.alioth.debian.org/pipermail/parted-devel/attachments/20060426/f45335bc/attachment.pgp


More information about the parted-devel mailing list