Skip to content

Instantly share code, notes, and snippets.

@wingrunr21
wingrunr21 / new_module.rb
Created May 11, 2011 14:32
Module Method Decoration Example
module Foobar
class << self
alias_method :orig_foo, :foo
def Foobar.foo(options)
options = "Output: " + options.reverse
Foobar.orig_foo(options)
end
end
end
wingrunr21@wings ~/Desktop/rubinius > which ruby
/Users/wingrunr21/.rvm/rubies/ruby-1.8.7-p302/bin/ruby
wingrunr21@wings ~/Desktop/rubinius > rvm system
wingrunr21@wings ~/Desktop/rubinius > which ruby
/usr/bin/ruby
wingrunr21@wings ~/Desktop/rubinius > which rake
/usr/bin/rake
wingrunr21@wings ~/Desktop/rubinius > /usr/bin/rake
(in /Users/wingrunr21/Desktop/rubinius)
wingrunr21@wings ~/Desktop/rubinius > ./configure
Configuring LLVM...
Checking for existing LLVM tree: found!
Checking sizeof(long): 8 bytes
Checking platform endianness: little endian
Checking tr1/hash definition: found
Checking for function 'backtrace': found!
Checking for function 'readline': found!
Checking curses library: curses
@wingrunr21
wingrunr21 / configure output from RVM
Created December 25, 2010 21:58
./configure --prefix=/Users/wingrunr21/.rvm/rubies/rbx-head --skip-system
~/.rvm/src/rbx-head > ./configure --prefix=/Users/wingrunr21/.rvm/rubies/rbx-head --skip-system
Configuring LLVM...
Checking for existing LLVM tree: ./configure:302: command not found: /Users/wingrunr21/.rvm/src/rbx-head/vm/external_libs/llvm/Release/bin/llvm-config --version
outdated (version )
Removing outdated tree...
Checking for prebuilt LLVM package...
Unpacking prebuilt LLVM: llvm-2.8-x86_64-apple-darwin10.5.0.tar.bz2: done!
Checking sizeof(long): 8 bytes
Checking platform endianness: little endian
@wingrunr21
wingrunr21 / configure.log output
Created December 25, 2010 21:44
Output for rvm install rbx configure.log
[2010-12-25 16:43:48] Configuring Rubinius...
[2010-12-25 16:43:48] Configuring LLVM...
[2010-12-25 16:43:48] Checking for existing LLVM tree:
[2010-12-25 16:43:48] not found.
[2010-12-25 16:43:48] Checking for prebuilt LLVM package...
[2010-12-25 16:43:48] Downloading llvm-2.8-x86_64-apple-darwin10.5.0.tar.bz2...
[2010-12-25 16:43:59] : done!
[2010-12-25 16:43:59] Downloading llvm-2.8-x86_64-apple-darwin10.5.0.tar.bz2.md5...
[2010-12-25 16:43:59] : done!
[2010-12-25 16:43:59] MD5 checksum for prebuilt LLVM verified.