mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* configure.in (RUBY_PROGRAM_VERSION, RUBY_RELEASE_DATE): extracts
from version.h for cross-compiling. * template/fake.rb.in (RUBY_VERSION, RUBY_DESCRIPTION): use above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24602 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
e22b92dce4
commit
7439c06ab7
2 changed files with 6 additions and 2 deletions
|
@ -84,6 +84,10 @@ done
|
|||
AC_SUBST(MAJOR)
|
||||
AC_SUBST(MINOR)
|
||||
AC_SUBST(TEENY)
|
||||
RUBY_PROGRAM_VERSION=`sed -n 's/^#define RUBY_VERSION "\(.*\)"/\1/p' $srcdir/version.h`
|
||||
AC_SUBST(RUBY_PROGRAM_VERSION)
|
||||
RUBY_RELEASE_DATE=`sed -n 's/^#define RUBY_RELEASE_DATE "\(.*\)"/\1/p' $srcdir/version.h`
|
||||
AC_SUBST(RUBY_RELEASE_DATE)
|
||||
if test "$MAJOR" = "1"; then
|
||||
AC_DEFINE(CANONICALIZATION_FOR_MATHN)
|
||||
fi
|
||||
|
|
|
@ -4,8 +4,8 @@ class Object
|
|||
remove_const :RUBY_VERSION
|
||||
remove_const :RUBY_DESCRIPTION if defined?(RUBY_DESCRIPTION)
|
||||
RUBY_PLATFORM = "@arch@"
|
||||
RUBY_VERSION = "@MAJOR@.@MINOR@.@TEENY@"
|
||||
RUBY_DESCRIPTION = "ruby #{RUBY_VERSION} (#{Time.now.strftime("%Y-%m-%d")}) [#{RUBY_PLATFORM}]"
|
||||
RUBY_VERSION = "@RUBY_PROGRAM_VERSION@"
|
||||
RUBY_DESCRIPTION = "ruby #{RUBY_VERSION} (@RUBY_RELEASE_DATE@) [#{RUBY_PLATFORM}]"
|
||||
end
|
||||
if RUBY_PLATFORM =~ /mswin|bccwin|mingw/
|
||||
class File
|
||||
|
|
Loading…
Reference in a new issue