In my opinion, app-arch/pbzip2 ebuilds should include 'symlink' USEflag which would cause them to create symlinks /usr/b{,un}zip2 pointing to pbzip2 binary. This would allow users to easily replace original bzip2 implementation with SMP-capable one when /usr is available. pbzip2 seems to be fully syntax-compatible with original bzip2 implementation. Although their output differs, I don't think that could cause problems with any scripts using bzip2 binaries. After creating symlinks, everything seems to work fine. 'bunzip2' and 'bzcat' work correctly too. The symlinks would be placed in /usr/bin (because pbzip2 requires libstdc++) and thus won't collide with real bzip2 binaries in /bin.
Created attachment 197672 [details, diff] Patch to add USE=symlink to ebuild
Does upstream support this?
(In reply to comment #2) > Does upstream support this? I didn't contact upstream about that. I think that's more ebuild-related issue.
Not really. If upstream doesn't "support" that configuration, there's no reason for the ebuild to. We like to ship stuff as close to upstream as possible.
Ok, I'll email upstream then and see what do they think of it.
Quoting: > The latest pbzip2 should be syntax-compatible with bzip2 so I don't > see why that shouldn't work. I'm not sure what they mean by if > upstream "supports" that configuration or not. The pbzip2 binary will > look at how it is being called and if it is named something "unzip" > like bunzip2 or "zcat" like bzcat then it will act in the appropriate > way so as far as I can tell it "supports" this configuration already. > > I have never tested your proposal on Gentoo so you might want to test > to make sure everything works, but you can reply to the bug and say > the upstream (pbzip2 upstream at least) says that the proposed use of > symlinks should be supported by the latest version of the code. > > Jeff.
Well, Jeff has given his (somewhat) approval, so I see no reason *not* to do this. I have bumped the ebuild in my overlay (layman -ka wolf31o2) with these changes. If someone wants to test them, then push them to the main tree for me, I would be appreciative.
This is in the tree.