1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* lib/mkmf.rb (INSTALL_DIRS, install_dirs): added BINDIR.

* lib/mkmf.rb (install_files): rejects files matching to
  $NONINSTALLFILES.

* lib/mkmf.rb (init_mkmf): defaults $NONINSTALLFILES to backup and
  temporary filse.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15377 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2008-02-05 02:14:17 +00:00
parent 23757bce57
commit f0cc22e990
3 changed files with 26 additions and 5 deletions

View file

@ -1,3 +1,13 @@
Tue Feb 5 11:14:11 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
* lib/mkmf.rb (INSTALL_DIRS, install_dirs): added BINDIR.
* lib/mkmf.rb (install_files): rejects files matching to
$NONINSTALLFILES.
* lib/mkmf.rb (init_mkmf): defaults $NONINSTALLFILES to backup and
temporary filse.
Mon Feb 4 21:52:06 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
* lib/delegate.rb (DelegateClass): use define_method instead of

View file

@ -96,11 +96,13 @@ INSTALL_DIRS = [
[dir_re('rubyhdrdir'), "$(RUBYHDRDIR)"],
[dir_re('sitehdrdir'), "$(SITEHDRDIR)"],
[dir_re('vendorhdrdir'), "$(VENDORHDRDIR)"],
[dir_re('bindir'), "$(BINDIR)"],
]
def install_dirs(target_prefix = nil)
if $extout
dirs = [
['BINDIR', '$(extout)/bin'],
['RUBYCOMMONDIR', '$(extout)/common'],
['RUBYLIBDIR', '$(RUBYCOMMONDIR)$(target_prefix)'],
['RUBYARCHDIR', '$(extout)/$(arch)$(target_prefix)'],
@ -111,6 +113,7 @@ def install_dirs(target_prefix = nil)
]
elsif $extmk
dirs = [
['BINDIR', '$(bindir)'],
['RUBYCOMMONDIR', '$(rubylibdir)'],
['RUBYLIBDIR', '$(rubylibdir)$(target_prefix)'],
['RUBYARCHDIR', '$(archdir)$(target_prefix)'],
@ -119,6 +122,7 @@ def install_dirs(target_prefix = nil)
]
elsif $configure_args.has_key?('--vendor')
dirs = [
['BINDIR', '$(bindir)'],
['RUBYCOMMONDIR', '$(vendordir)$(target_prefix)'],
['RUBYLIBDIR', '$(vendorlibdir)$(target_prefix)'],
['RUBYARCHDIR', '$(vendorarchdir)$(target_prefix)'],
@ -127,6 +131,7 @@ def install_dirs(target_prefix = nil)
]
else
dirs = [
['BINDIR', '$(bindir)'],
['RUBYCOMMONDIR', '$(sitedir)$(target_prefix)'],
['RUBYLIBDIR', '$(sitelibdir)$(target_prefix)'],
['RUBYARCHDIR', '$(sitearchdir)$(target_prefix)'],
@ -550,13 +555,14 @@ end
def install_files(mfile, ifiles, map = nil, srcprefix = nil)
ifiles or return
ifiles.empty? and return
srcprefix ||= '$(srcdir)'
RbConfig::expand(srcdir = srcprefix.dup)
dirs = []
path = Hash.new {|h, i| h[i] = dirs.push([i])[-1]}
ifiles.each do |files, dir, prefix|
dir = map_dir(dir, map)
prefix = %r|\A#{Regexp.quote(prefix)}/?| if prefix
prefix &&= %r|\A#{Regexp.quote(prefix)}/?|
if /\A\.\// =~ files
# install files which are in current working directory.
files = files[2..-1]
@ -570,6 +576,10 @@ def install_files(mfile, ifiles, map = nil, srcprefix = nil)
Dir.glob(files) do |fx|
f = fx
f[0..len] = "" if len
case File.basename(f)
when *$NONINSTALLFILES
next
end
d = File.dirname(f)
d.sub!(prefix, "") if prefix
d = (d.empty? || d == ".") ? dir : File.join(dir, d)
@ -1634,7 +1644,8 @@ def init_mkmf(config = CONFIG)
$DEFLIBPATH = $extmk ? ["$(topdir)"] : CROSS_COMPILING ? [] : ["$(libdir)"]
$DEFLIBPATH.unshift(".")
$LIBPATH = []
$INSTALLFILES = nil
$INSTALLFILES = []
$NONINSTALLFILES = [/~\z/, /\A#.*#\z/, /\A\.#/, /\.bak\z/i, /\.orig\z/, /\.rej\z/, /\.l[ao]\z/, /\.o\z/]
$VPATH = %w[$(srcdir) $(arch_hdrdir)/ruby $(hdrdir)/ruby]
$objs = nil

View file

@ -1,7 +1,7 @@
#define RUBY_VERSION "1.9.0"
#define RUBY_RELEASE_DATE "2008-02-04"
#define RUBY_RELEASE_DATE "2008-02-05"
#define RUBY_VERSION_CODE 190
#define RUBY_RELEASE_CODE 20080204
#define RUBY_RELEASE_CODE 20080205
#define RUBY_PATCHLEVEL 0
#define RUBY_VERSION_MAJOR 1
@ -9,7 +9,7 @@
#define RUBY_VERSION_TEENY 0
#define RUBY_RELEASE_YEAR 2008
#define RUBY_RELEASE_MONTH 2
#define RUBY_RELEASE_DAY 4
#define RUBY_RELEASE_DAY 5
#ifdef RUBY_EXTERN
RUBY_EXTERN const char ruby_version[];