Bug #20185
closedSwitch back to using binary ruby when rvm is fixed
Description
In order to fix the issue described below, our Debian 11 package build and package test Docker images use --disable-binary
(see 907983bcaaf9cf2f058d150b2e91dcbfba465074). This increases build time substantially, so we should switch back to using pre-built packages from rvm if/when they are updated.
Original issue¶
Ruby gems that involve C extensions are failing to build with this error
make: /usr/bin/mkdir: No such file or directory
Example:
build-packages-debian11: #676 /consoleFull
This is affecting multiple different gems. I've seen it with 'racc' and
'ffi'.
Other projects have been bitten by this:
https://github.com/sparklemotion/nokogiri/issues/2046
https://github.com/brianmario/mysql2/issues/724
https://github.com/fullstaq-ruby/server-edition/issues/101
Tentatively, the problem seems to be that Ruby records the location of mkdir
when it is built/installed. Our package build uses rvm to install Ruby. It seems that all the packages were rebuilt Feb 22:
https://rvm_io.global.ssl.fastly.net/binaries/debian/11/x86_64/
I'm wondering if these packages were prepared on a system that had /usr/bin/mkdir
even though the standard debian image is /bin/mkdir
.
On further research, this looks like exactly the issue listed here:
https://github.com/rvm/rvm/issues/4975
I filed a new bug:
Updated by Peter Amstutz almost 2 years ago
- Status changed from New to In Progress
Updated by Peter Amstutz almost 2 years ago
- Description updated (diff)
- Subject changed from Package building issues with ruby ffi to Package building issues with ruby gems
Updated by Brett Smith almost 2 years ago
Peter Amstutz wrote:
I'm wondering if these packages were prepared on a system that had
/usr/bin/mkdir
even though the standard debian image is/bin/mkdir
.
This depends on the version of Debian. On Debian 12 bookworm the standard path will be /usr/bin/mkdir
, and you can get that on Debian 11 bullseye today by installing the usrmerge
package, which gets installed by default on new standard installs. For more info see the Debian UsrMerge wiki page. For really deep why, see Booting Without /usr is Broken.
Updated by Peter Amstutz almost 2 years ago
Brett Smith wrote in #note-7:
Peter Amstutz wrote:
I'm wondering if these packages were prepared on a system that had
/usr/bin/mkdir
even though the standard debian image is/bin/mkdir
.This depends on the version of Debian. On Debian 12 bookworm the standard path will be
/usr/bin/mkdir
, and you can get that on Debian 11 bullseye today by installing theusrmerge
package, which gets installed by default on new standard installs. For more info see the Debian UsrMerge wiki page. For really deep why, see Booting Without /usr is Broken.
The Debian Docker image doesn't have /usr/bin/mkdir
out of the box, but maybe we could add a dependency on usrmerge
as a workaround?
Updated by Brett Smith almost 2 years ago
Peter Amstutz wrote in #note-8:
The Debian Docker image doesn't have
/usr/bin/mkdir
out of the box, but maybe we could add a dependency onusrmerge
as a workaround?
I think that's worth a shot at least.
Digging into the GitHub issues a little more, it sounds like RVM builds on Ubuntu, and Ubuntu recently did a dot release that merged /usr
, probably because Debian bookworm is close enough that it made sense for them. But then builds fail on systems that don't have merged /usr
.
Updated by Peter Amstutz almost 2 years ago
- Target version changed from 2023-03-01 sprint to Development 2023-03-15 sprint
Updated by Peter Amstutz almost 2 years ago
- Target version changed from Development 2023-03-15 sprint to Development 2023-03-29 Sprint
Updated by Peter Amstutz almost 2 years ago
- Status changed from In Progress to Feedback
- Description updated (diff)
- Subject changed from Package building issues with ruby gems to Switch back to using binary ruby when rvm is fixed
Updated by Peter Amstutz almost 2 years ago
- Target version changed from Development 2023-03-29 Sprint to To be scheduled
Updated by Peter Amstutz 11 months ago
- Target version changed from To be scheduled to Future
Updated by Lucas Di Pentima 7 months ago
I guess this ticket is irrelevant now due to #21522 ?
Updated by Peter Amstutz 7 months ago
- Target version deleted (
Future) - Status changed from Feedback to Closed