FS#37330 - [mdadm] fix reference to /usr/sbin in PKG files

Attached to Project: Arch Linux
Opened by John (graysky) - Monday, 14 October 2013, 13:20 GMT
Last edited by Ionut Biru (wonder) - Wednesday, 16 October 2013, 11:00 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To No-one
Architecture All
Severity Very Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

The PKG ships with references to /usr/sbin in the following which should be cleansed even though a symlink is on the filesystem:

* /etc/mdadm.conf
* /usr/lib/udev/rules.d/64-md-raid-assembly.rules

Interestingly, despite the `make BINDIR=/usr/bin in the PKGBUILD, several binaries are as well hard-coded to /usr/sbin:
% find . -type f -executable -exec grep sbin {} \; -print
Binary file ./usr/bin/mdadm matches
./usr/bin/mdadm
Binary file ./usr/bin/mdmon matches
./usr/bin/mdmon
Binary file ./usr/bin/mdassemble matches
./usr/bin/mdassemble


Additional info:
* package version(s) 3.3-1
This task depends upon

Closed by  Ionut Biru (wonder)
Wednesday, 16 October 2013, 11:00 GMT
Reason for closing:  Upstream
Comment by John (graysky) - Monday, 14 October 2013, 13:27 GMT
Ah, I see the error in my first post: the Makefile does not create the daughter files with the alternative BINDIR variable; these need to be manually patched. Two attachments:

1. My attempt |sbin|usr/bin| in the affected files.
2. An updated PKGBUILD.

Note - Please modify the mdadm.conf included in the PKG per my original post.
Comment by Tobias Powalowski (tpowa) - Tuesday, 15 October 2013, 06:32 GMT
Please take this upstream, i'll not merge those patches.
Comment by John (graysky) - Tuesday, 15 October 2013, 08:42 GMT
I thought the sbin move was something Arch embarced ahead of the curve? Since mdadm is something ubiquitous to linux, I wouldn't expect upstream to make this change for compatibility reasons. Also, some of my larger patch is already included in mdadm-fix-udev-rules.patch which is in the source files just not active.

I will contact upastream to ask if they can make these daughter files honor the BINDIR the user chooses. Thank you for maintaining.
Comment by Ionut Biru (wonder) - Tuesday, 15 October 2013, 08:53 GMT
this patch won't be accepted upstream this way. i think is better to use BINDIR from ./configure instead of hardcoding.
Comment by John (graysky) - Tuesday, 15 October 2013, 20:04 GMT
I agree, wonder. Does anyone know how to go about contacting the mdadm project team? I can't find any info in the tarball itself nor can I on the homepage (http://neil.brown.name/blog/mdadm). Thus far I have emailed neilb AT suse DOT de (several days ago) but have not yet received a reply.
Comment by John (graysky) - Wednesday, 16 October 2013, 10:54 GMT
He just got back to me. Probably safe to close this ticket based on his reply:

"I'm happy to have BINDIR in the Makefile affect everything that gets
installed (though maybe it should be renamed to SBINDIR).

If you can send me a patch that looks good I'll apply it.
Otherwise: I've put it on my to-do list and will probably get to in
eventually.

Thanks,
NeilBrown"

Loading...