Bug #5879

$ignore_error use before set

Added by Kazuhiro NISHIYAMA about 3 years ago. Updated about 3 years ago.

[ruby-dev:45124]
Status:Closed
Priority:Normal
Assignee:Nobuyoshi Nakada
ruby -v:ruby 2.0.0dev (2012-01-12 trunk 34271) [x86_64-linux] Backport:

Description

lib/mkmf.rb で make_makefile の中で
$ignore_error = $nmake ? '' : ' 2> /dev/null || true'

と $ignore_error が設定されていますが、 make_makefile の呼び出しよりも前の
CLEANINGS への代入で $ignore_error が使われていて、
DISTCLEANDIRS の RMDIRS に ' 2> /dev/null || true' が付きません。

この影響で make realclean などで Linux だと「rmdir: オペランドがありません」、
Mac OS X だと「usage: rmdir [-p] directory ...」というメッセージが出ます。

Associated revisions

Revision 34279
Added by Nobuyoshi Nakada about 3 years ago

  • lib/mkmf.rb: fix r33904 and revert r33905. initialize global variables with init_mkmf before initializing constants. [Bug #5879]

Revision 34279
Added by Nobuyoshi Nakada about 3 years ago

  • lib/mkmf.rb: fix r33904 and revert r33905. initialize global variables with init_mkmf before initializing constants. [Bug #5879]

History

#1 Updated by Nobuyoshi Nakada about 3 years ago

  • Status changed from Open to Closed
  • % Done changed from 0 to 100

This issue was solved with changeset r34279.
Kazuhiro, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.


  • lib/mkmf.rb: fix r33904 and revert r33905. initialize global variables with init_mkmf before initializing constants. [Bug #5879]

Also available in: Atom PDF