Vadim Zhukov [persg...@gmail.com] wrote:
> ????, 20 ??????. 2018 ??. ?? 21:17, Vadim Zhukov <persg...@gmail.com>:
> >
> > Hi,
> >
> > The Ansible "patch" module fails to work on OpenBSD because it tries
> > to use "--dry-run" command-line option on patch(1), while ours
> > supports -C/--check instead. For now, I have an obvious, hm, patch :)
> > for patch.py that replaces --dry-run with --check. But what way do
> > people prefer: to move OpenBSD's patch(1) closer to GNU one, or to add
> > some logic to patch.py that'll detect correct command-line option to
> > use?
> >
> > There's also an issue with --binary: we don't support this option on
> > OpenBSD, and  GNU patch manual page says it's a no-op on POSIX anyway.
> > Would it be okay to add --binary as a no-op option to our patch?
> 
> BTW, the FreeBSD patch got --dry-run 4 years ago:
> https://svnweb.freebsd.org/base/head/usr.bin/patch/patch.c?r1=267490&r2=267512
> 
> NetBSD got it in 2005:
> http://cvsweb.netbsd.org/bsdweb.cgi/src/usr.bin/patch/patch.c.diff?r1=1.22&r2=1.23&only_with_tag=MAIN
> 
> Neither has --binary.
> 

Marc Espie did -C in 1998. See:

http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/patch/patch.c.diff?r1=1.10&r2=1.11

I think OpenBSD generally shies away from --gnu-style-options because they're
rather ugly compared to the originals. Unfortunately GNU is apparently setting
the standard for FreeBSD and NetBSD now.

Chris

Reply via email to