aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax Howell2009-05-21 04:35:36 +0100
committerMax Howell2009-05-21 04:35:36 +0100
commitacc2f7969640c59dd27832f796c2a7373ed4d0b3 (patch)
tree5d6fa0baf3ae00c541edf50a72a6be2431de0ccc
parent41a7984bb122b63fd11794160822e7a242133cdf (diff)
downloadbrew-acc2f7969640c59dd27832f796c2a7373ed4d0b3.tar.bz2
Setup build environment to include our prefix
-rw-r--r--Cellar/homebrew/brewkit.rb8
1 files changed, 7 insertions, 1 deletions
diff --git a/Cellar/homebrew/brewkit.rb b/Cellar/homebrew/brewkit.rb
index 4bb102f98..900754125 100644
--- a/Cellar/homebrew/brewkit.rb
+++ b/Cellar/homebrew/brewkit.rb
@@ -5,8 +5,12 @@ require 'pathname'
$agent = "Homebrew 0.1 (Ruby; Mac OS X 10.5 Leopard)"
$cellar = Pathname.new(__FILE__).dirname.parent.realpath
+#TODO don't add the prefixes if we're in /usr or /usr/local
ENV['MACOSX_DEPLOYMENT_TARGET']='10.5'
ENV['CFLAGS']=ENV['CXXFLAGS']='-O3 -w'
+ENV['CPPFLAGS']="-I#{$cellar.parent}/include"
+ENV['LDFLAGS']="-L#{$cellar.parent}/lib"
+
def h1 title
puts "\033[0;34m==>\033[0;0;1m #{title} \033[0;0m"
@@ -40,7 +44,9 @@ class Formula
def brew
raise "@name.nil?" if @name.nil?
raise "@version.nil?" if @version.nil?
- raise "@name does not validate to our regexp" unless /^\w+$/ =~ @name
+
+ # disabled until the regexp makes sense :P
+ #raise "@name does not validate to our regexp" unless /^\w+$/ =~ @name
beginning = Time.now