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 1780126 - MakeMaker installs files with permission 0444
Summary: MakeMaker installs files with permission 0444
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: perl-ExtUtils-Install
Version: 8.2
Hardware: Unspecified
OS: Unspecified
high
unspecified
Target Milestone: rc
: 8.0
Assignee: perl-maint-list
QA Contact: RHEL CS Apps Subsystem QE
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-12-05 13:16 UTC by Andreas Schneider
Modified: 2021-06-05 07:30 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-06-05 07:30:30 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
CPAN 40976 0 None None None 2019-12-05 15:11:02 UTC
CPAN 49579 0 None None None 2019-12-05 15:11:02 UTC

Description Andreas Schneider 2019-12-05 13:16:23 UTC
Description of problem:

The samba package contains a perl tool called pidl. To install it, a Makefile.PL is provided which uses MakeMaker.

When I call 'make install', files are installed with permission 0444 instead of 0644.

I don't see a way that I can influence this.

Comment 1 Andreas Schneider 2019-12-05 13:32:08 UTC
Actually it seems to be already the 'make' command which copies .pm files to blib/ directory.

Comment 2 Andreas Schneider 2019-12-05 13:57:35 UTC
Both, when copying the files to blib dir and on installing, it does a chmod 0444 according to strace.

Comment 3 Andreas Schneider 2019-12-05 14:02:03 UTC
Reproducer:

Get the Samba package and unzip the tarball:

cd pidl
perl Makefile.PL
make
make DESTDIR=/tmp/wurst install_vendor

Comment 4 Petr Pisar 2019-12-05 14:23:19 UTC
ExtUtils::Install (called by ExtUtils::MakeMaker) follows permissions of the source. From the manual:

        Copies each directory tree of %from_to to its corresponding value preserving
        timestamps and permissions.

If you have a source file without a write permission, the installed file will be stripped from that permission either. I guess that's your case. Although upstream has reported some inconsistencies in the behavior.

Could you tell me what exact samba source archive do you use?

Comment 5 Petr Pisar 2019-12-05 15:05:56 UTC
Ok. I can reproduce it:

$ ls -lR
.:
total 0
drwxrwxr-x. 2 test test 60 Dec  5 15:51 script

./script:
total 0
-rwxr-xr-x. 1 test test 0 Dec  5 15:51 pidl
$ perl -MExtUtils::Install -e 'install([ from_to => { q{script} => q{/tmp/b} } ])'
Installing /tmp/b/pidl
$ ls -l /tmp/b/pidl 
-r-xr-xr-x. 1 test test 0 Dec  5 15:51 /tmp/b/pidl

Comment 6 Andreas Schneider 2019-12-05 15:47:58 UTC
Thanks, I've worked around the bug by specifying %attr for each file in the spec file.

Comment 7 Petr Pisar 2019-12-06 09:22:32 UTC
ExtUtils::Install documentation does not match the behavior. The current behavior is asserted by ExtUtils::Install tests. It's quite possible the current behavior is desired. I raised a question to the upstream together with a patch that changes the behavior. Let's wait some time for upstream's opinion.

Comment 8 Andreas Schneider 2019-12-06 09:36:50 UTC
If the current behavior is desired, then there needs to be a option to change that.

Comment 11 RHEL Program Management 2021-06-05 07:30:30 UTC
After evaluating this issue, there are no plans to address it further or fix it in an upcoming release.  Therefore, it is being closed.  If plans change such that this issue will be fixed in an upcoming release, then the bug can be reopened.


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