Bug 1822698 - Add pcre2-tools package to CodeReady Builder repository
Summary: Add pcre2-tools package to CodeReady Builder repository
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: pcre2
Version: 8.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: beta
: 8.3
Assignee: Petr Pisar
QA Contact: RHEL CS Apps Subsystem QE
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-04-09 16:05 UTC by Davide Cavalca
Modified: 2020-12-16 08:37 UTC (History)
8 users (show)

Fixed In Version: pcre2-10.32-2.el8
Doc Type: Enhancement
Doc Text:
Feature: Provide a pcre2grep tool from PCRE2 project. Reason: pcre2grep enables to restrict searching in files based on their file name specified with a regular expressino, and to perform a multi-line match in a content of the files. Result: pcre2-tools package that provides the pcre2grep tool has been added into a CodeReady Builder repository for the developmental purposes.
Clone Of:
Environment:
Last Closed: 2020-11-04 01:59:24 UTC
Type: Bug
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2020:4539 0 None None None 2020-11-04 01:59:34 UTC

Description Davide Cavalca 2020-04-09 16:05:14 UTC
Description of problem:
The pcre-tools package is missing from the mirrors in CentOS Stream and CentOS 8, despite it being defined in the specfile (https://git.centos.org/rpms/pcre/blob/c8/f/SPECS/pcre.spec#_122) and present in previous releases of the distribution.

Version-Release number of selected component (if applicable):
8.42-4.el8

Comment 1 Petr Pisar 2020-04-14 07:12:42 UTC
pcre-tools package is provided because Red Hat Enterprise Linux 8 does not provide it.

Comment 2 Petr Pisar 2020-04-14 07:13:38 UTC
I'm sorry for the typo. It should read:

pcre-tools package is NOT provided because Red Hat Enterprise Linux 8 does not provide it.

Comment 3 Petr Pisar 2020-04-14 11:57:33 UTC
That applies to CentOS Stream as it is a next Red Hat Enterprise Linux version. If you want that package in Red Hat Enterprise Linux, please contact Red Hat support <https://access.redhat.com/support/>.

Regarding CentOS, you need to file a bug into CentOS bug tracking system as documented at <https://fedoraproject.org/wiki/EPEL/FAQ#RHEL_8.2B_has_binaries_in_the_release.2C_but_is_missing_some_corresponding_-devel_package._How_do_I_build_a_package_that_needs_that_missing_-devel_package.3F>.

Comment 4 Brian Stinson 2020-04-14 22:08:43 UTC
I'm hoping that we can treat this bug as a request to add pcre-tools to RHEL. 

Can we discuss here if it's acceptable to include pcre-tools in a future RHEL 8 release?

The missing -devel package policy is geared more toward devel headers that are not for enabling at runtime. pcre-tools seems to ship a tool or two which would be needed in one of the proper channels.

Comment 5 Jim Perrin 2020-04-14 22:20:37 UTC
Going to add Josh Boyer here so he can keep an eye on this as well.

Comment 6 Petr Pisar 2020-04-15 08:12:36 UTC
(In reply to Brian Stinson from comment #4)
> I'm hoping that we can treat this bug as a request to add pcre-tools to
> RHEL. 
> 
Bugzilla is not a support tool. All customer-driven requests for RHEL must go through the Red Hat support.

Comment 9 Josh Boyer 2020-04-15 12:06:02 UTC
Davide, can you elaborate on why you need pcre-tools?  It should also be noted that pcre is dead upstream and obsoleted by pcre2.

Comment 10 Davide Cavalca 2020-04-15 15:29:19 UTC
pcre-tools provides pcregrep, which has two really useful features: the include command, and multiline matches. For example, we do quite a bit of stuff like

pcregrep -r --include='.(php|js|re)$' -l -M 'scripts/schema/gencode((| |\\*)*(FooSchema))'

in various build/test/development scripts that would be difficult to impossible to migrate to plain grep. We could possibly use something like ripgrep, but that's also not packaged in CentOS (nor in EPEL), and the syntax/featureset isn't an exact match.

Comment 11 Petr Pisar 2020-04-15 15:59:42 UTC
I see. A multi-line match is indeed a superior feature of pcregrep.

Have you considered using pcre2grep <https://www.pcre.org/current/doc/html/pcre2grep.html> instead? It's very similar to pcregrep, but it has a future, because it is actively maintained. RHEL 8 also does not distribute it, but if I should choose one of them I would bet on pcre2grep. Another feature of PCRE2 is that it uses fewer recursive algorithms and thus is less prone to stack exhaustion (followed by a program crash).

Provided you use it only as a developmental tool, I believe CodeReady Builder repository in RHEL would be the best place for the package.

Comment 12 Davide Cavalca 2020-04-15 17:54:13 UTC
Thanks Petr! Looks like pcre2grep is a drop in replacement for our usecase, and it seems to work fine from a quick test, so I think that'll work. I agree that CodeReady Builder would be a good fit for this package.

Comment 13 Petr Pisar 2020-04-16 06:24:53 UTC
Davide, if you have a RHEL subscription, please escalate this request via Red Hat support <https://access.redhat.com/support/>. Otherwise this issue will get little attention from the responsible people and a chance that it will be fullfilled will be close to zero.

Comment 17 Joe Orton 2020-04-16 14:04:42 UTC
Since we don't have a customer demand to update the pcre2 package, and adding a subpackage to CRB requires an updated package build currently, we'll keep this in the backlog for RHEL8 but don't plan to address it imminently.

Comment 18 Judd 2020-04-22 13:46:05 UTC
We also use this tool. I've opened a support case to have it added and referenced this bz. It's 02632388 for anyone at RH that finds it useful.

Comment 29 errata-xmlrpc 2020-11-04 01:59:24 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: pcre2 security and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2020:4539


Note You need to log in before you can comment on or make changes to this bug.