Summary: | Ruby eclass may not handle installation correctly when using setup.rb | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Hans de Graaff <graaff> |
Component: | Eclasses | Assignee: | Gentoo Ruby Team <ruby> |
Status: | RESOLVED WONTFIX | ||
Severity: | normal | ||
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | setup.rb collection |
Description
Hans de Graaff
![]() ![]() Hi, I contacted the Rmagick main dev and he said that the setup.rb is generic : http://i.loveruby.net/en/projects/setup/ Hmm, I didn't write the ruby eclass so I can't answer whether --prefix would cause an issue or not. But, perhaps we can try it and see what happens! My main concern is that we'd break existing packages using setup.rb. However, given that RMagick uses a standard setup.rb and that we install most packages as a gem that chance may not be very large. Created attachment 103639 [details]
setup.rb collection
I did a quick grep over dev-ruby to find non-gem packages, fetched them all and extract setup.rb. There are only 12 packages that have setup.rb. There are some very different setup.rb implementations. I think racc's setup.rb is more standard than RMagick's according to diff.
Anyway 12 is not a big deal, just test them all :)
I'm not really sure whether this is a good move. fusefs-0.6.0 fails to install if I append either --prefix=${D} or --prefix=${D}/usr BTW Hans, may I know why you use --prefix=${D} instead of --prefix=${D}/usr in rmagick ebuild? I used --prefix=${D} because it worked. :-) I initially tried to use --prefix=${D}/usr but the package ended up in /usr/usr/bin etc. After investigating a bit more I've found the following: 'setup.rb install --prefix' determines the directory where the actual files are written, but respecting the --prefix given in the config step. So for Gentoo the install --prefix must be ${D}. Normally this would be / which is the default. The 'setup.rb config --prefix' step seem to be redundant then, because it defaults to /usr. Leaving out would work fine, because all files would assume to be under /usr due to the default --prefix, and then written to ${D} due to the install --prefix. But... ...the post-install.rb script doesn't care at all about the install --prefix and only checks the config --prefix. So we need to do both to get everything to end up in the right place. I think we can mark this as WONTFIX, ruby-ng.eclass does no longer have template functions for setup.rb. |