* Makefile.in (install-cross): target to install cross-compiling

stuff.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29339 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2010-09-24 16:34:56 +00:00
Родитель c5d52c3bb3
Коммит feacd3c2e0
4 изменённых файлов: 35 добавлений и 0 удалений

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

@ -1,3 +1,8 @@
Sat Sep 25 01:34:41 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
* Makefile.in (install-cross): target to install cross-compiling
stuff.
Fri Sep 24 23:44:59 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
* string.c (sym_call), vm.c (invoke_block_from_c),

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

@ -79,6 +79,13 @@ MINIRUBY = @MINIRUBY@\
$(MINIRUBYOPT)
RUNRUBY = @RUNRUBY@ $(RUNRUBYOPT) --
XRUBY = @XRUBY@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
XRUBY_LIBDIR = @XRUBY_LIBDIR@
XRUBY_RUBYLIBDIR = @XRUBY_RUBYLIBDIR@
XRUBY_RUBYHDRDIR = @XRUBY_RUBYHDRDIR@
#### End of system configuration section. ####
@ -170,6 +177,22 @@ $(arch)-fake.rb: config.status $(srcdir)/template/fake.rb.in
@./config.status --file=$@:$(srcdir)/template/fake.rb.in
@chmod +x $@
install-cross: $(arch)-fake.rb $(RBCONFIG) rbconfig.rb $(arch_hdrdir)/ruby/config.h \
$(LIBRUBY_A) $(LIBRUBY_SO) $(ARCHFILE)
$(MAKEDIRS) $(XRUBY_RUBYLIBDIR)/$(arch) $(XRUBY_RUBYHDRDIR)/$(arch)/ruby
sed '/^\$$:\.unshift/q' $(arch)-fake.rb > fake.rb
$(BASERUBY) -p \
-e '~/^\s*CONFIG\["LDFLAGS"\]/ and' \
-e '$$_[/(?=\s*"$$)/] = %q[ #{(CONFIG["LIBPATHFLAG"]%File.dirname(__FILE__)).strip}]' \
rbconfig.rb > fake-rbconfig.rb
$(INSTALL_SCRIPT) fake.rb $(XRUBY_RUBYLIBDIR)/$(arch)/fake.rb
$(INSTALL_SCRIPT) fake-rbconfig.rb $(XRUBY_RUBYLIBDIR)/$(arch)/rbconfig.rb
@$(RM) fake.rb fake-rbconfig.rb
$(INSTALL_DATA) $(arch_hdrdir)/ruby/config.h $(XRUBY_RUBYHDRDIR)/$(arch)/ruby
$(INSTALL_DATA) $(top_srcdir)/include/ruby/win32.h $(XRUBY_RUBYHDRDIR)/ruby
$(INSTALL_DATA) $(LIBRUBY) $(LIBRUBY_A) $(XRUBY_RUBYLIBDIR)/$(arch)
$(INSTALL_PROGRAM) $(LIBRUBY_SO) $(XRUBY_RUBYLIBDIR)/$(arch)
Makefile: $(srcdir)/Makefile.in $(srcdir)/enc/Makefile.in
$(MKFILES): config.status

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

@ -858,6 +858,7 @@ help: PHONY
@echo " benchmark benchmark this ruby and COMPARE_RUBY"
@echo " install: install all ruby distributions"
@echo " install-nodoc: install without rdoc"
@echo " install-cross: install cross compiling staff"
@echo " clean: clean for tarball"
@echo " distclean: clean for repo"
@echo " change: make change log template"

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

@ -2053,6 +2053,12 @@ fi
if test x"$cross_compiling" = xyes; then
test x"$MINIRUBY" = x && MINIRUBY="${RUBY-$BASERUBY} -I`pwd` "-r'$(arch)-fake'
XRUBY_LIBDIR=`${RUBY-$BASERUBY} -rrbconfig -e ['puts RbConfig::CONFIG["libdir"]']`
XRUBY_RUBYLIBDIR=`${RUBY-$BASERUBY} -rrbconfig -e ['puts RbConfig::CONFIG["rubylibdir"]']`
XRUBY_RUBYHDRDIR=`${RUBY-$BASERUBY} -rrbconfig -e ['puts RbConfig::CONFIG["rubyhdrdir"]']`
AC_SUBST(XRUBY_LIBDIR)
AC_SUBST(XRUBY_RUBYLIBDIR)
AC_SUBST(XRUBY_RUBYHDRDIR)
PREP='$(arch)-fake.rb'
RUNRUBY='$(MINIRUBY) -I`cd $(srcdir)/lib; pwd`'
XRUBY='$(MINIRUBY)'