On Wed 27 Sep 2006 at 12:21PM, Danek Duvall wrote:
> On Wed, Sep 27, 2006 at 11:55:20AM -0700, Dan Price wrote:
> 
> > --- usr/src/cmd/zlogin/Makefile Mon Sep 11 23:06:16 2006
> > +++ /dev/null   Wed Sep 27 11:24:43 2006
> > @@ -1,47 +1,0 @@
> > -#
> > -#
> > -# CDDL HEADER START
> > -#
> > -# The contents of this file are subject to the terms of the
> > -# Common Development and Distribution License (the "License").
> > -# You may not use this file except in compliance with the License.
> > -#
> > <..... snip: rest of file is here........>
> > -lint:  lint_PROG
> > -
> > -include ../Makefile.targ
> > --- /dev/null   Wed Sep 27 11:24:43 2006
> > +++ usr/src/cmd/zlogin/fakefile Mon Sep 25 21:15:35 2006
> > @@ -1,0 +1,47 @@
> > +#
> > +# CDDL HEADER START
> > +#
> > +# The contents of this file are subject to the terms of the
> > +# Common Development and Distribution License (the "License").
> > +# You may not use this file except in compliance with the License.
> > +#
> > <..... snip: rest of file is here........>
> > 
> > 
> > However, patch(1) rejects this outright, and gpatch(1) prompts me for
> > filenames and doesn't seem to want to create usr/src/cmd/zlogin/fakefile
> > for me.  Is there any way to make this work right?
> 
> Solaris and GNU diff produce patches that are completely unusable with the
> other's patch program when diffing against an empty file.  The problem,
> ultimately, is that Solaris diff spits out "-1,0", while GNU diff uses
> "0,0".  The format isn't standardized -- yet.  Apparently, the appropriate
> POSIX subcommittee is looking at this, and their drafts appear to prefer
> the "0,0" format.  That doesn't help us now.
> 
> I have a handful of fixes for patch in queue, including ones to accept the
> GNU diff variant and to handle patches that create files, and to handle
> patches that patch files that aren't in the current directory (as well as a
> few others -- it's amazing that our patch works at all).  But it's all
> buried behind other stuff.  You're welcome to take it over if you like.  :)

No, I don't like.  :)

So do you have an overall recommendation about format?  We can take this
off-alias if you like.

I could also post-process the output of diff as needed in the -1,0 case,
that seems very detectable.  Even with that hint, I'm having no luck
with gpatch in my manual testing.

Does anyone know why we have gpatch but not gdiff in /usr/bin?  Maybe
that's a project someone in the tools community could help us out with.

        -dp

-- 
Daniel Price - Solaris Kernel Engineering - [EMAIL PROTECTED] - blogs.sun.com/dp
_______________________________________________
tools-discuss mailing list
[email protected]

Reply via email to