rbinstall.rb: no batch installation

* tool/rbinstall.rb (bin-comm): drop batch file installation.
  Windows 95 support has not been supported already.
  [Feature #10806]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49465 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2015-02-01 04:46:55 +00:00
Родитель 23aad65d1f
Коммит 38a37ed8f2
2 изменённых файлов: 8 добавлений и 12 удалений

Просмотреть файл

@ -1,3 +1,9 @@
Sun Feb 1 13:46:52 2015 Nobuyoshi Nakada <nobu@ruby-lang.org>
* tool/rbinstall.rb (bin-comm): drop batch file installation.
Windows 95 support has not been supported already.
[Feature #10806]
Sat Jan 31 12:06:23 2015 Scott Francis <scott.francis@shopify.com> Sat Jan 31 12:06:23 2015 Scott Francis <scott.francis@shopify.com>
* thread_pthread.c (reserve_stack): fix intermittent SIGBUS on * thread_pthread.c (reserve_stack): fix intermittent SIGBUS on

Просмотреть файл

@ -44,7 +44,7 @@ def parse_args(argv = ARGV)
$script_mode = nil $script_mode = nil
$strip = false $strip = false
$cmdtype = (if File::ALT_SEPARATOR == '\\' $cmdtype = (if File::ALT_SEPARATOR == '\\'
File.exist?("rubystub.exe") ? 'exe' : 'bat' File.exist?("rubystub.exe") ? 'exe' : 'cmd'
end) end)
mflags = [] mflags = []
opt = OptionParser.new opt = OptionParser.new
@ -76,7 +76,7 @@ def parse_args(argv = ARGV)
end end
opt.on('--installed-list [FILENAME]') {|name| $installed_list = name} opt.on('--installed-list [FILENAME]') {|name| $installed_list = name}
opt.on('--rdoc-output [DIR]') {|dir| $rdocdir = dir} opt.on('--rdoc-output [DIR]') {|dir| $rdocdir = dir}
opt.on('--cmd-type=TYPE', %w[bat cmd plain]) {|cmd| $cmdtype = (cmd unless cmd == 'plain')} opt.on('--cmd-type=TYPE', %w[cmd plain]) {|cmd| $cmdtype = (cmd unless cmd == 'plain')}
opt.on('--[no-]strip') {|strip| $strip = strip} opt.on('--[no-]strip') {|strip| $strip = strip}
opt.order!(argv) do |v| opt.order!(argv) do |v|
@ -491,16 +491,6 @@ install?(:local, :comm, :bin, :'bin-comm') do
case $cmdtype case $cmdtype
when "exe" when "exe"
stub + shebang + body stub + shebang + body
when "bat"
(prebatch + <<-"EOH".gsub(/^\s+/, '') << postbatch << shebang << body << "__END__\n:endofruby\n").gsub(/(?=\n)/, "\r")
@echo off
@if not "%~d0" == "~d0" goto WinNT
#{ruby_bin} -x "#{cmd}" %1 %2 %3 %4 %5 %6 %7 %8 %9
@goto endofruby
:WinNT
"%~dp0#{ruby_install_name}" -x "%~f0" %*
@goto endofruby
EOH
when "cmd" when "cmd"
prebatch + <<"/EOH" << postbatch << shebang << body prebatch + <<"/EOH" << postbatch << shebang << body
@"%~dp0#{ruby_install_name}" -x "%~f0" %* @"%~dp0#{ruby_install_name}" -x "%~f0" %*