RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1349465 - [bash-completion] put it under $(pkg-config --variable=completionsdir bash-completion) to allow for dynamic loading
Summary: [bash-completion] put it under $(pkg-config --variable=completionsdir bash-co...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: pcs
Version: 7.1
Hardware: Unspecified
OS: Unspecified
low
unspecified
Target Milestone: rc
: ---
Assignee: Ivan Devat
QA Contact: cluster-qe@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-06-23 13:49 UTC by Jan Pokorný [poki]
Modified: 2016-11-03 20:59 UTC (History)
6 users (show)

Fixed In Version: pcs-0.9.152-5.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-11-03 20:59:09 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
proposed fix (988 bytes, patch)
2016-07-01 10:34 UTC, Ivan Devat
no flags Details | Diff
proposed fix (832 bytes, patch)
2016-07-27 14:44 UTC, Ivan Devat
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1305049 1 None None None 2021-01-20 06:05:38 UTC
Red Hat Product Errata RHSA-2016:2596 0 normal SHIPPED_LIVE Moderate: pcs security, bug fix, and enhancement update 2016-11-03 12:11:34 UTC

Internal Links: 1305049

Description Jan Pokorný [poki] 2016-06-23 13:49:33 UTC
First mentioned in [bug 1305049 comment 11] that also sparkled
https://github.com/scop/bash-completion/issues/51

As Ville pointed out, right directory has to be chosen for the completion
file so as to allow for dynamic treatment.  Unfortunately, pcs hardcodes
the old/backward-compatibility one:

rpm -ql pcs | grep bash
> /etc/bash_completion.d/pcs

(https://pkgs.fedoraproject.org/cgit/rpms/pcs.git/tree/pcs.spec?id=de104aad02076d4814cc5fe0b3f9791ae0f33e3d#n109)

Please use the path per Summary so as to enable any update being
instantly reflected without a need to reload/restart/exec new shell
environment.

Comment 2 Ivan Devat 2016-07-01 10:34:24 UTC
Created attachment 1174875 [details]
proposed fix

Comment 3 Ivan Devat 2016-07-01 10:39:12 UTC
Before fix:
[vm-rhel72-1 ~] $ rpm -q pcs
pcs-0.9.151-1.el7.x86_64

[vm-rhel72-1 ~] $ rpm -ql pcs | grep bash
/etc/bash_completion.d/pcs

After fix:
[vm-rhel72-1 ~] $ rpm -q pcs
pcs-0.9.152-3.el7.x86_64

[vm-rhel72-1 ~] $ rpm -ql pcs | grep bash
/usr/share/bash-completion/completions/pcs

Comment 7 Ivan Devat 2016-07-27 14:44:29 UTC
Created attachment 1184680 [details]
proposed fix

Test:
[vm-rhel72-1 ~pcs] $ make install BASH_COMPLETION_DIR=/usr/share/bash-completion
...
install -D -m644 pcs/bash_completion.sh /usr/share/bash-completion/pcs
...
[vm-rhel72-1 ~pcs] $ ls -l /usr/share/bash-completion |grep pcs
-rw-r--r--. 1 root root  1029 27. čec 16.40 pcs

Comment 8 Ivan Devat 2016-07-28 14:36:49 UTC
Before Fix:
[vm-rhel72-1 ~] $ rpm -q pcs                                          
pcs-0.9.152-4.el7.x86_64
[vm-rhel72-1 ~] $ ll /usr/share/bash-completion/completions/ |grep pcs
-rwxr-xr-x. 1 root root  1029 15. čec 15.22 pcs

After Fix:
[vm-rhel72-1 ~] $ rpm -q pcs                                          
pcs-0.9.152-5.el7.x86_64
[vm-rhel72-1 ~] $ ll /usr/share/bash-completion/completions/ |grep pcs
-rw-r--r--. 1 root root  1029 28. čec  2016 pcs

Comment 12 errata-xmlrpc 2016-11-03 20:59:09 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, 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://rhn.redhat.com/errata/RHSA-2016-2596.html


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