Bug 228798 - [exp-run] bsdgrep as /usr/bin/grep
Summary: [exp-run] bsdgrep as /usr/bin/grep
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Ports Framework (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Kyle Evans
URL:
Keywords:
: 218385 (view as bug list)
Depends on: 228673
Blocks: 230332
  Show dependency treegraph
 
Reported: 2018-06-06 23:59 UTC by Kyle Evans
Modified: 2020-12-08 14:08 UTC (History)
2 users (show)

See Also:
antoine: exp-run+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kyle Evans freebsd_committer freebsd_triage 2018-06-06 23:59:36 UTC
Hello!

Can you please do an exp-run on head w/ WITH_BSD_GREP="yes" set? I think I had fixed most of the breakage in an exp-run many moons ago, but have no idea what might have crept in since then- the fallout shouldn't be the most terrifying, though. There is some interest in flipping over to bsdgrep in -HEAD, even in its current state WITHOUT_GNU_GREP_COMPAT, while I finish up some details.
Comment 2 Kyle Evans freebsd_committer freebsd_triage 2018-07-21 14:49:22 UTC
Hi Antoine,

Thanks! It seems my work has progressed a little bit differently than I thought, and I might be able to fix these just by re-enabling GNU extensions in our bsdgrep with the GNU-compat bits I'm about to add to libregex.

I have one other patch that should get an exp-run because it inevitably will break things, maybe even in the ports framework, but then I'd like to revisit this with a patch to flip BSD_GREP and GNU_GREP_COMPAT instead.
Comment 3 Kyle Evans freebsd_committer freebsd_triage 2020-12-05 03:20:53 UTC
Hi,

Please re-run this now -- as of base r368358, bsdgrep will now use libregex by default and should implement all of the extensions that ports needs. WITH_BSD_GREP="yes" is still sufficient.
Comment 4 Antoine Brodin freebsd_committer freebsd_triage 2020-12-08 09:13:44 UTC
Exp-run looks fine
Comment 5 Kyle Evans freebsd_committer freebsd_triage 2020-12-08 14:02:32 UTC
*** Bug 218385 has been marked as a duplicate of this bug. ***
Comment 6 commit-hook freebsd_committer freebsd_triage 2020-12-08 14:05:46 UTC
A commit references this bug:

Author: kevans
Date: Tue Dec  8 14:05:26 UTC 2020
New revision: 368439
URL: https://svnweb.freebsd.org/changeset/base/368439

Log:
  src.opts.mk: switch to bsdgrep as /usr/bin/grep

  This has been years in the making, and we all knew it was bound to happen
  some day. Switch to the BSDL grep implementation now that it's been a
  little more thoroughly tested and theoretically supports all of the
  extensions that gnugrep in base had with our libregex(3).

  Folks shouldn't really notice much from this update; bsdgrep is slower than
  gnugrep, but this is currently the price to pay for fewer bugs. Those
  dissatisfied with the speed of grep and in need of a faster implementation
  should check out what textproc/ripgrep and textproc/the_silver_searcher
  can do for them.

  I have some WIP to make bsdgrep faster, but do not consider it a blocker
  when compared to the pros of switching now (aforementioned bugs, licensing).

  PR:		228798 (exp-run)
  PR:		128645, 156704, 166842, 166862, 180937, 193835, 201650
  PR:		232565, 242308, 246000, 251081, 191086, 194397
  Relnotes:	yes, please

Changes:
  head/share/mk/src.opts.mk
Comment 7 Kyle Evans freebsd_committer freebsd_triage 2020-12-08 14:08:34 UTC
(In reply to Antoine Brodin from comment #4)

Thanks, Antoine!