At Mon, 28 Nov 2005 19:21:49 +0100,
Michael Sperber wrote:
Yoichi NAKAYAMA <yoichi(a)geiin.org> writes:
> At Sat, 17 Jul 2004 17:46:20 +0200,
> Michael Sperber wrote:
>> 2004-07-11 Mike Sperber <mike(a)xemacs.org>
>> * igrep.el: Synch igrep with author version 2.111.
>> I've committed this patch.
> This commit kills previous change:
>> 2003-09-24 Mike Sperber <mike(a)xemacs.org>
>> * igrep.el (igrep-find-use-xargs): Don't assume xargs behaves
>> GNU-like if find does.
> as igrep-find cause error on FreeBSD where xargs
> doesn't have -e option.
I don't think so. The trunk's at version 1.8. It has:
(cond ((and (equal (call-process igrep-find-program nil nil nil
(equal (call-process "xargs" nil nil nil
"-e" "-0" "cat")
((not (equal system-type 'darwin)))) ; not MacOS
"Whether `\\[igrep-find]' uses the `xargs` program or not.
If `gnu', it executes
`find ... -print0 | xargs -0 -e grep ...`;
if not `gnu' but non-nil, it executes
`find ... -print | xargs -e grep ...`;
if nil, it executes
`find ... -exec grep ...`.")
... which contains the check. (And I use it on FreeBSD every day.)
Is there some confusion over the code you're looking at? (Or the code
I'm looking at :-) ? )
On FreeBSD, it returns t and use "xargs -e" then a error
is produced on igrep-find as described in
I think the second condition
(not (equal system-type 'darwin))
should be replaced with
(equal (call-process "xargs" nil nil nil "-e") 0)
and I hope it works on MacOS too (not tested).
BTW, the change introduced in the XEmacs package and
above fix is not XEmacs specific one, but it is not merged
into the original version. I think it's better to be
included in the original one. so I've sent report&patch
to the original author.