Project

General

Profile

Actions

Bug #21092

closed

error building ruby 3.4.1 on cygwin/msys2

Added by jeremyd2019 (Jeremy Drake) about 1 month ago. Updated 12 days ago.


Description

While building from the release tarball ruby-3.4.1.tar.xz on cygwin (also confirmed in snapshot-master.tar.gz from Jan 27, 2025), I get the following error:

../ruby-3.4.1/ext/extmk.rb:279:in 'Array#-': no implicit conversion of nil into Array (TypeError)
from ../ruby-3.4.1/ext/extmk.rb:279:in 'Object#extmake'
from ../ruby-3.4.1/ext/extmk.rb:659:in 'block in '
from ../ruby-3.4.1/ext/extmk.rb:653:in 'Array#each'
from ../ruby-3.4.1/ext/extmk.rb:653:in ''

I have tracked this down to happening when an ext writes a dummy makefile. In this case, that ext is .bundle/gems/syslog-0.2.0.
See https://github.com/ruby/syslog/pull/16 for fixing why it is writing a dummy makefile to begin with, but still, it seems like extmk.rb should handle this case gracefully rather than breaking the build.

Actions #1

Updated by jeremyd2019 (Jeremy Drake) about 1 month ago

  • Description updated (diff)

Updated by hsbt (Hiroshi SHIBATA) about 1 month ago

  • Status changed from Open to Assigned
  • Assignee set to hsbt (Hiroshi SHIBATA)
Actions #3

Updated by hsbt (Hiroshi SHIBATA) about 1 month ago

  • Subject changed from error building ruby 3.4.1 on cygwin to error building ruby 3.4.1 on cygwin/msys2

Updated by nobu (Nobuyoshi Nakada) about 1 month ago

I cannot reproduce that error at all, with ruby-3.4.1.

Updated by nobu (Nobuyoshi Nakada) about 1 month ago

  • Backport changed from 3.1: UNKNOWN, 3.2: UNKNOWN, 3.3: UNKNOWN, 3.4: UNKNOWN to 3.1: REQUIRED, 3.2: REQUIRED, 3.3: REQUIRED, 3.4: REQUIRED

nobu (Nobuyoshi Nakada) wrote in #note-4:

I cannot reproduce that error at all, with ruby-3.4.1.

This was because I failed to get msys to pretend to be cygwin, and it reproduced by simply trying on cygwin.
MSys is mysterious.

Actions #6

Updated by nobu (Nobuyoshi Nakada) about 1 month ago

  • Status changed from Assigned to Closed

Applied in changeset git|2b6fc9ea7212543a1be26768403f59c7a759b5ea.


[Bug #21092] Fallback variables after execonf has done

When reading from a dummy makefile, the global variables initialized
in init_mkmf may not be overridden.

Updated by k0kubun (Takashi Kokubun) 26 days ago

  • Backport changed from 3.1: REQUIRED, 3.2: REQUIRED, 3.3: REQUIRED, 3.4: REQUIRED to 3.1: REQUIRED, 3.2: REQUIRED, 3.3: REQUIRED, 3.4: DONE
Actions #8

Updated by hsbt (Hiroshi SHIBATA) 12 days ago

  • Backport changed from 3.1: REQUIRED, 3.2: REQUIRED, 3.3: REQUIRED, 3.4: DONE to 3.1: REQUIRED, 3.2: DONE, 3.3: REQUIRED, 3.4: DONE
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0