Project

General

Profile

Actions

Feature #13620

open

Simplifying MRI's build system: always make install

Added by Eregon (Benoit Daloze) over 7 years ago. Updated almost 2 years ago.

Status:
Open
Assignee:
-
Target version:
-
[ruby-core:81501]

Description

Hello all,

I've been bitten recently when modifying ruby/spec or in #13570 by the sheer number of different configurations to build and test in MRI.
Currently, I know 4 of them, and I can tell you it is a big headache to make it work on all of them:

  • in-source-dir build, running tool/runruby.rb
  • in-source-dir build, running the installed ruby
  • out-of-source build, running tool/runruby.rb
  • out-of-source build, running the installed ruby

I just compiled latest MRI this morning, and here are the times:

  • time make -j 8:
    make -j 8 373.22s user 30.88s system 404% cpu 1:39.99 total
  • time make -j 8 install-nodoc
    make -j 8 install-nodoc 3.29s user 0.55s system 259% cpu 1.477 total

So I am wondering, should we just test with the installed ruby since installing it takes only marginally more time than building?

The current complexity of runruby.rb, the generated ./rbconfig.rb, etc, all to support testing from the built ruby seems not worth it.
It also means all the tests need to accommodate this different layout and are essentially testing a ruby layout that nobody uses in production.
On the other hand, testing the installed ruby would test something which is much closer to what is released and used in production,
and massively simplify the setup to test by making installed layout assumptions hold (e.g.: RbConfig.ruby points to the current ruby and ruby needs no flags to execute correctly).

Did I miss something?

I also wish we could choose one of in-source/out-of-source and not having to support both, but let's talk about make/make install first.


Related issues 2 (0 open2 closed)

Related to Ruby master - Bug #15812: Run specs from install folder?ClosedEregon (Benoit Daloze)Actions
Related to Ruby master - Bug #19158: Ruby 3.1.3 installs wrong gemspec for debug gemClosedhsbt (Hiroshi SHIBATA)Actions
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0