$NetBSD: patch-aa,v 1.2 2014/03/17 14:08:41 taca Exp $ * Add shbang path and use vendordir. * Don't use obsolete Config. --- setup.rb.orig 2005-11-20 11:54:27.000000000 +0000 +++ setup.rb @@ -1,3 +1,4 @@ +#!env ruby # # setup.rb # @@ -168,6 +169,9 @@ class ConfigTable siteruby = c['sitedir'] siterubyver = c['sitelibdir'] siterubyverarch = c['sitearchdir'] + vendorruby = c['vendordir'] + vendorrubyver = c['vendorlibdir'] + vendorrubyverarch = c['vendorarchdir'] elsif newpath_p # 1.4.4 <= V <= 1.6.3 libruby = "#{c['prefix']}/lib/ruby" @@ -204,8 +208,8 @@ class ConfigTable table['rbdir'] = '$librubyver' table['sodir'] = '$librubyverarch' when 'site' - table['rbdir'] = '$siterubyver' - table['sodir'] = '$siterubyverarch' + table['rbdir'] = '$vendorrubyver' + table['sodir'] = '$vendorrubyverarch' when 'home' setup_rb_error '$HOME was not set' unless ENV['HOME'] table['prefix'] = ENV['HOME'] @@ -239,9 +243,15 @@ class ConfigTable 'the directory for aux ruby libraries'), PathItem.new('siterubyverarch', 'path', siterubyverarch, 'the directory for aux ruby binaries'), - PathItem.new('rbdir', 'path', '$siterubyver', + PathItem.new('vendorruby', 'path', vendorruby, + 'the directory for version-independent aux ruby libraries'), + PathItem.new('vendorrubyver', 'path', vendorrubyver, + 'the directory for aux ruby libraries'), + PathItem.new('vendorrubyverarch', 'path', vendorrubyverarch, + 'the directory for aux ruby binaries'), + PathItem.new('rbdir', 'path', '$vendorrubyver', 'the directory for ruby scripts'), - PathItem.new('sodir', 'path', '$siterubyverarch', + PathItem.new('sodir', 'path', '$vendorrubyverarch', 'the directory for ruby extentions'), PathItem.new('rubypath', 'path', rubypath, 'the path to set to #! line'), @@ -785,7 +795,7 @@ class ToplevelInstaller else require 'rbconfig' end - ::Config::CONFIG + ::RbConfig::CONFIG end def initialize(ardir_root, config)