masterkain / macruby

Ruby 1.9 ported to run directly on top of Mac OS X core technologies. Trunk mirror.

This URL has Read+Write access

name age message
file .cvsignore Mon Feb 25 22:40:53 -0800 2008 added missing .document and .cvsignore files (f... [lsansonetti@apple.com]
file .document Mon Feb 25 22:40:53 -0800 2008 added missing .document and .cvsignore files (f... [lsansonetti@apple.com]
file .gitignore Tue Sep 29 21:07:28 -0700 2009 fixed .gitignore and added all the tags that we... [mattaimonetti@gmail.com]
file COPYING Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
file GPL Mon Feb 25 12:18:21 -0800 2008 initial import git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
file HACKING.rdoc Mon Sep 21 22:14:51 -0700 2009 move the AOT compilation of the stdlib into the... [lsansonetti@apple.com]
file LEGAL Mon Apr 13 13:25:07 -0700 2009 added autozone.h legal information git-svn-id:... [lsansonetti@apple.com]
file LGPL Mon Feb 25 12:18:21 -0800 2008 initial import git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
file MacRuby.m Sun Jul 26 22:48:12 -0700 2009 forgot to initialize the compiler git-svn-id: ... [lsansonetti@apple.com]
file README.rdoc Mon Nov 02 21:20:38 -0800 2009 recommend to pass --enable-bindings=none to LLV... [lsansonetti@apple.com]
file Rakefile Loading commit data...
file TODO
file array.c Thu Oct 29 23:50:54 -0700 2009 rb_ary_delete(): never yield current block git... [lsansonetti@apple.com]
file b.rb Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
file bench.rb Tue Apr 07 18:24:23 -0700 2009 enabled tail-call elimination git-svn-id: http... [lsansonetti@apple.com]
directory benchmark/ Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
file bignum.c Thu Oct 15 18:37:01 -0700 2009 re-implemented #rand and #srand to use random(3... [lsansonetti@apple.com]
directory bin/
file bridgesupport.cpp
file bridgesupport.h Fri Jun 19 17:57:44 -0700 2009 better version of last commit git-svn-id: http... [lsansonetti@apple.com]
file bs.c Wed Sep 30 16:43:09 -0700 2009 http://xkcd.com/292/ git-svn-id: http://svn.ma... [lsansonetti@apple.com]
file bs.h Sat Sep 19 00:37:35 -0700 2009 refreshed copyright for 2009 git-svn-id: http:... [mattaimonetti@gmail.com]
file bs_lex.h Tue Aug 11 04:40:10 -0700 2009 fixed compilation on Leopard git-svn-id: http:... [vincent.isambart@gmail.com]
file bs_struct_readers.c Wed Apr 22 17:55:53 -0700 2009 statically generate the struct reader methods, ... [lsansonetti@apple.com]
file class.c
file compar.c Tue Jul 07 19:52:12 -0700 2009 optimized dummy calls to <=>: git-svn-id: http... [lsansonetti@apple.com]
file compiler.cpp
file compiler.h
file complex.c Thu Aug 27 22:11:13 -0700 2009 added fixnum/float/complex support for the fast... [lsansonetti@apple.com]
file cont.c Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
directory data/ Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
file dir.c Tue Oct 27 19:24:31 -0700 2009 better MRI 1.9 C API compat git-svn-id: http:/... [lsansonetti@apple.com]
file dispatcher.cpp
file distruby.rb Mon Feb 25 12:18:21 -0800 2008 initial import git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
file dln.c Fri Sep 25 17:14:56 -0700 2009 .rbo files are now initialized using a gcc cons... [lsansonetti@apple.com]
file dln.h Fri Sep 25 17:14:56 -0700 2009 .rbo files are now initialized using a gcc cons... [lsansonetti@apple.com]
file dmydln.c Mon Feb 25 12:18:21 -0800 2008 initial import git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
file dmyencoding.c Sun May 18 01:10:19 -0700 2008 sync with ruby trunk r15665 git-svn-id: http:/... [lsansonetti@apple.com]
file dmyext.c Mon Feb 25 12:18:21 -0800 2008 initial import git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
file dmytranscode.c Sun May 18 01:10:19 -0700 2008 sync with ruby trunk r15665 git-svn-id: http:/... [lsansonetti@apple.com]
file dtrace.d Thu Oct 08 18:56:53 -0700 2009 removed the insn__entry and insn__return probes... [lsansonetti@apple.com]
file encoding.c
file enum.c Fri Sep 04 21:49:21 -0700 2009 fixing a bunch of minor IO bugs git-svn-id: ht... [lsansonetti@apple.com]
file enumerator.c Thu Sep 17 16:47:17 -0700 2009 rewrote the file loader (it was really time) + ... [lsansonetti@apple.com]
file error.c Tue Oct 27 19:24:31 -0700 2009 better MRI 1.9 C API compat git-svn-id: http:/... [lsansonetti@apple.com]
file eval.c
file eval_error.c Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
file eval_jump.c Tue Oct 06 17:27:35 -0700 2009 fix for <rdar://problem/7281043> Adding framewo... [lsansonetti@apple.com]
file eval_safe.c Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
directory ext/
file file.c Fri Oct 16 14:36:17 -0700 2009 re-enabled File#flock git-svn-id: http://svn.m... [lsansonetti@apple.com]
directory framework/ Wed Jun 11 20:04:36 -0700 2008 auto-generate the framework Info.plist file gi... [lsansonetti@apple.com]
file gc-stub.m Sat Sep 19 00:37:35 -0700 2009 refreshed copyright for 2009 git-svn-id: http:... [mattaimonetti@gmail.com]
file gc.c
file gcd.c
file gem_prelude.rb Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
file gen_bs_struct_readers.rb Wed Apr 22 17:55:53 -0700 2009 statically generate the struct reader methods, ... [lsansonetti@apple.com]
file golf_prelude.rb Sun May 18 01:10:19 -0700 2008 sync with ruby trunk r15665 git-svn-id: http:/... [lsansonetti@apple.com]
file hash.c Thu Nov 05 18:12:48 -0800 2009 slightly faster hash iterations git-svn-id: ht... [lsansonetti@apple.com]
file id.c
file id.h
directory include/
file inits.c Fri Oct 23 18:53:14 -0700 2009 swaped the Set custom implementation by the lat... [mattaimonetti@gmail.com]
file instruby.rb
file io.c Thu Nov 05 23:02:15 -0800 2009 faster IO#gets git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
file keywords Thu Jun 05 01:11:58 -0700 2008 merge with ruby trunk r16762 + better/faster ob... [lsansonetti@apple.com]
file lex.c.blt Thu Jun 05 01:11:58 -0700 2008 merge with ruby trunk r16762 + better/faster ob... [lsansonetti@apple.com]
file lex.c.src Thu Jun 05 01:11:58 -0700 2008 merge with ruby trunk r16762 + better/faster ob... [lsansonetti@apple.com]
file lgamma_r.c Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
directory lib/
file llvm.h Mon Aug 10 23:19:45 -0700 2009 adding a new optimized Array for default alloca... [lsansonetti@apple.com]
file load.c Tue Oct 13 22:12:15 -0700 2009 implement rb_provided() git-svn-id: http://svn... [lsansonetti@apple.com]
file main.cpp Sat Sep 19 00:37:35 -0700 2009 refreshed copyright for 2009 git-svn-id: http:... [mattaimonetti@gmail.com]
file markgc.c Sat Sep 19 00:37:35 -0700 2009 refreshed copyright for 2009 git-svn-id: http:... [mattaimonetti@gmail.com]
file marshal.c Wed Sep 09 18:10:17 -0700 2009 adding missing write barriers git-svn-id: http... [lsansonetti@apple.com]
file math.c Tue Aug 25 18:35:19 -0700 2009 introduce rb_objc_define_module_function() whic... [lsansonetti@apple.com]
directory misc/
directory mspec/
file numeric.c Thu Oct 15 18:37:01 -0700 2009 re-implemented #rand and #srand to use random(3... [lsansonetti@apple.com]
file objc.h
file objc.m Fri Nov 06 18:40:26 -0800 2009 don't show this annoying warning by default gi... [lsansonetti@apple.com]
file object.c
directory onig/ Tue Oct 20 17:17:32 -0700 2009 do not leak some internal hash tables git-svn-... [lsansonetti@apple.com]
file pack.c Thu Oct 01 00:35:10 -0700 2009 another Array#pack bug fix by Ninh Bui(Phusion)... [mattaimonetti@gmail.com]
file parse.y
file prec.c Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
file prelude.rb Sun May 18 01:10:19 -0700 2008 sync with ruby trunk r15665 git-svn-id: http:/... [lsansonetti@apple.com]
file proc.c
file process.c Tue Aug 25 18:35:19 -0700 2009 introduce rb_objc_define_module_function() whic... [lsansonetti@apple.com]
directory rakelib/
file random.c
file range.c Thu Sep 24 23:31:03 -0700 2009 fixed AOT compilation of literal ranges (object... [lsansonetti@apple.com]
file rational.c Sat Aug 01 19:00:15 -0700 2009 adding some TODOs git-svn-id: http://svn.macos... [lsansonetti@apple.com]
file re.c
file ruby.1 Sun May 18 01:10:19 -0700 2008 sync with ruby trunk r15665 git-svn-id: http:/... [lsansonetti@apple.com]
file ruby.c Fri Sep 25 18:59:38 -0700 2009 AOT objects function names are now provided by ... [lsansonetti@apple.com]
file rubytest.rb Mon Feb 25 12:18:21 -0800 2008 initial import git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
file runruby.rb Mon Feb 25 12:18:21 -0800 2008 initial import git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
directory sample-macruby/
directory sample/ Wed Mar 11 14:14:13 -0700 2009 committing experimental branch content git-svn... [lsansonetti@apple.com]
file signal.c Tue Sep 29 14:12:11 -0700 2009 don't install stupid handlers on some signals ... [lsansonetti@apple.com]
directory spec/
file sprintf.cpp Mon Oct 26 14:01:08 -0700 2009 pass the object as is for %p (note: immediate t... [lsansonetti@apple.com]
file st.c Wed Sep 09 18:10:17 -0700 2009 adding missing write barriers git-svn-id: http... [lsansonetti@apple.com]
file string.c
file struct.c Tue Oct 20 17:18:15 -0700 2009 adding missing write barriers git-svn-id: http... [lsansonetti@apple.com]
directory test-macruby/ Mon Mar 16 14:30:13 -0700 2009 Removed the half implemented RubyCocoa layer fo... [eloy.de.enige@gmail.com]
directory test/ Mon Sep 14 10:15:13 -0700 2009 Added Rake to the list of external libraries to... [eloy.de.enige@gmail.com]
file test_vm.rb Thu Jun 25 11:09:46 -0700 2009 when loading a test file, append ./ this way it... [lsansonetti@apple.com]
directory test_vm/
file thread.c Fri Oct 30 19:34:41 -0700 2009 implemented VM cleanup + make sure Threads do n... [lsansonetti@apple.com]
file thread_pthread.h Mon Feb 25 12:18:21 -0800 2008 initial import git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
file time.c Tue Sep 08 19:25:45 -0700 2009 changed Time#_load again to conform to stupid r... [lsansonetti@apple.com]
directory tool/ Fri May 22 17:38:22 -0700 2009 the great schism, part I git-svn-id: http://sv... [lsansonetti@apple.com]
file transcode.c Mon Mar 30 16:42:49 -0700 2009 fixed the build (sorry guys) git-svn-id: http:... [lsansonetti@apple.com]
file transcode_data.h Mon Feb 25 12:18:21 -0800 2008 initial import git-svn-id: http://svn.macosfor... [lsansonetti@apple.com]
file util.c Thu Jul 30 23:46:57 -0700 2009 various unicode/bytestring fixes git-svn-id: h... [lsansonetti@apple.com]
file variable.c
file version.c Mon Oct 19 16:38:40 -0700 2009 MACRUBY_VERSION is now a string git-svn-id: ht... [lsansonetti@apple.com]
file version.h Mon Oct 19 16:44:00 -0700 2009 better description git-svn-id: http://svn.maco... [lsansonetti@apple.com]
file vm.cpp
file vm.h
file vm_eval.c Wed Nov 04 11:58:58 -0800 2009 rb_yield is now inlined + improved GC_WB to not... [lsansonetti@apple.com]
file vm_method.c
README.rdoc

MacRuby

MacRuby is a Ruby implementation based on Mac OS X technologies, such as the Objective-C runtime and garbage collector, the CoreFoundation framework and the LLVM compiler infrastructure.

It is the goal of MacRuby to enable the creation of full-fledged Mac OS X applications which do not sacrifice performance in order to enjoy the benefits of using Ruby.

MacRuby is copyrighted free software by Apple Inc and covered by the terms of the Ruby license. Please refer to the COPYING file for more information.

The project website contains more documentation, such as tutorials and guides: macruby.org

Requirements

  • An Intel machine. PowerPC machines are not supported anymore, but may still work. An Intel 64-bit machine (Intel Core Duo 2) is recommended.
  • Mac OS X 10.5.6 or later.
  • LLVM ToT, compiled for both i386 and x86_64.

    LLVM is a moving target and breaks periodically. We recommend to install revision 82747.

      $ svn co -r 82747 https://llvm.org/svn/llvm-project/llvm/trunk llvm-trunk
      $ cd llvm-trunk
      $ ./configure --enable-bindings=none
      $ UNIVERSAL=1 UNIVERSAL_ARCH="i386 x86_64" ENABLE_OPTIMIZED=1 make
      $ sudo env UNIVERSAL=1 UNIVERSAL_ARCH="i386 x86_64" ENABLE_OPTIMIZED=1 make install
    

    Note that compiling LLVM can take quite a while. If you have a machine with multiple cores, which is quite likely, you might want to speed up the process by using all/more cores. However, doing this can make your machine unresponsive during compilation. To use multiple cores pass the `-j N’ option, where `N’ stands for the number of cores you’d like to use. So for a Core Duo the command would look like:

      $ UNIVERSAL=1 UNIVERSAL_ARCH="i386 x86_64" ENABLE_OPTIMIZED=1 make -j2
    

Build Instructions

You can build MacRuby by doing the following command:

  $ rake

Once done, you can run the RubySpec-based regression tests as well as the performance suite:

  $ rake spec:ci
  $ rake bench:ci

To install MacRuby on your machine:

  $ sudo rake install

Then you should be all set! Please report us any problem you will find (the macruby.org website has pointers). Thanks!