Skip to content
This repository has been archived by the owner on Jul 4, 2023. It is now read-only.

Commit

Permalink
Updated formula: sbcl 1.0.43
Browse files Browse the repository at this point in the history
Built from source while automatically download and use the official
1.0.29 binary to bootstrap.
  • Loading branch information
tianyicui committed Nov 15, 2010
1 parent 9ad4624 commit 3f0e95d
Showing 1 changed file with 39 additions and 11 deletions.
50 changes: 39 additions & 11 deletions Library/Formula/sbcl.rb
Original file line number Diff line number Diff line change
@@ -1,22 +1,50 @@
require 'formula'
require 'hardware'

class Sbcl <Formula
if snow_leopard_64?
url 'http://downloads.sourceforge.net/project/sbcl/sbcl/1.0.29/sbcl-1.0.29-x86_64-darwin-binary-r2.tar.bz2'
md5 '47c99c60ec44e57070807c0890ba1c90'
else
url 'http://downloads.sourceforge.net/project/sbcl/sbcl/1.0.29/sbcl-1.0.29-x86-darwin-binary-r2.tar.bz2'
md5 '6e6b027a5fd05ef0c8faee30d89ffe54'
end
# The official binary for 1.0.29 is used to bootstrap the latest version.
class SbclBinary < Formula
url 'http://downloads.sourceforge.net/project/sbcl/sbcl/1.0.29/sbcl-1.0.29-x86-darwin-binary-r2.tar.bz2'
md5 '6e6b027a5fd05ef0c8faee30d89ffe54'
version '1.0.29'
end

class Sbcl < Formula
url 'http://downloads.sourceforge.net/project/sbcl/sbcl/1.0.43/sbcl-1.0.43-source.tar.bz2'
homepage 'http://www.sbcl.org/'
md5 '2b125844371881a99cfdf63c286e74cd'

skip_clean 'bin'
skip_clean 'lib'

def install
ENV['INSTALL_ROOT'] = prefix
system "sh install.sh"
original_path = pwd
puts "original_path=#{original_path}"
mktemp do
# install 1.0.29 to a temporary location
binary_path = pwd
SbclBinary.new('sbcl-binary').brew do
install_sbcl binary_path
end
# build and install 1.0.43
cd original_path do
system "env",
"PATH=#{binary_path}/bin:#{ENV['PATH']}",
"SBCL_HOME=#{binary_path}/lib/sbcl",
"sh",
"make.sh",
"--prefix=#{prefix}"
cd 'tests' do
system "sh run-tests.sh"
end
install_sbcl prefix
end
end
end

def install_sbcl path
system "env",
"INSTALL_ROOT=#{path}",
"sh",
"install.sh"
end

end

0 comments on commit 3f0e95d

Please sign in to comment.