aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorMax Howell2009-11-11 17:25:48 +0000
committerMax Howell2009-11-11 17:29:35 +0000
commit0d673c6684dcf7c459e535a20f6a425983841324 (patch)
treebb703a86704bcb709e283d6a4cab68f16e80f635 /Library
parent2dc3423c195d766f4fff426def88e585c15884b3 (diff)
downloadhomebrew-0d673c6684dcf7c459e535a20f6a425983841324.tar.bz2
Fixes #126; configure breaks with 64 bit kernel
Diffstat (limited to 'Library')
-rw-r--r--Library/Formula/erlang.rb42
1 files changed, 39 insertions, 3 deletions
diff --git a/Library/Formula/erlang.rb b/Library/Formula/erlang.rb
index ac9a2c4d5..9976ddcb3 100644
--- a/Library/Formula/erlang.rb
+++ b/Library/Formula/erlang.rb
@@ -20,7 +20,8 @@ class Erlang <Formula
skip_clean 'lib'
def patches
- { :p0 => ["patch-toolbar.erl",
+ { :p1 => DATA,
+ :p0 => ["patch-toolbar.erl",
"patch-erts_emulator_Makefile.in",
"patch-erts_emulator_hipe_hipe_amd64_asm.m4.diff",
"patch-erts_emulator_hipe_hipe_amd64_bifs.m4.diff",
@@ -53,13 +54,13 @@ class Erlang <Formula
config_flags << '--enable-hipe'
end
- if Hardware.is_64_bit? and MACOS_VERSION == 10.6
+ if Hardware.is_64_bit? and MACOS_VERSION >= 10.6
config_flags << "--enable-darwin-64bit"
config_flags << "--enable-m64-build"
end
system "./configure", *config_flags
- system "touch lib/wx/SKIP"
+ system "touch lib/wx/SKIP" if MACOS_VERSION >= 10.6
system "make"
system "make install"
@@ -67,3 +68,38 @@ class Erlang <Formula
#ErlangHtmlDocs.new.brew { doc.install Dir['*'] }
end
end
+
+
+__END__
+--- otp_src_R13B02-1/configure 2009-09-21 11:29:51.000000000 +0200
++++ otp_src_R13B02-1-hvt/configure 2009-11-11 19:02:24.000000000 +0200
+@@ -2702,7 +2702,7 @@
+ export LDFLAGS
+ fi
+ if test X${enable_darwin_64bit} = Xyes; then
+- if test X"$TMPSYS" '!=' X"Darwin-i386"; then
++ if test X"$TMPSYS" '!=' X"Darwin-i386" '-a' X"$TMPSYS" '!=' X"Darwin-x86_64"; then
+ { { echo "$as_me:$LINENO: error: --enable-darwin-64bit only supported on x86 host" >&5
+ echo "$as_me: error: --enable-darwin-64bit only supported on x86 host" >&2;}
+ { (exit 1); exit 1; }; }
+@@ -2712,7 +2712,7 @@
+ export CFLAGS
+ LDFLAGS="-m64 $LDFLAGS"
+ export LDFLAGS
+-elif test X"$TMPSYS" '=' X"Darwin-i386"; then
++elif test X"$TMPSYS" '=' X"Darwin-i386" '-o' X"$TMPSYS" '!=' X"Darwin-x86_64"; then
+ CFLAGS="-m32 $CFLAGS"
+ export CFLAGS
+ LDFLAGS="-m32 $LDFLAGS"
+diff -r -u otp_src_R13B02-1/erts/configure otp_src_R13B02-1-hvt/erts/configure
+--- otp_src_R13B02-1/erts/configure 2009-09-21 11:29:49.000000000 +0200
++++ otp_src_R13B02-1-hvt/erts/configure 2009-11-11 19:05:49.000000000 +0200
+@@ -2803,7 +2803,7 @@
+ esac
+ fi
+ if test X${enable_darwin_64bit} = Xyes; then
+- if test X"$TMPSYS" '!=' X"Darwin-i386"; then
++ if test X"$TMPSYS" '!=' X"Darwin-i386" '-a' X"$TMPSYS" '!=' X"Darwin-x86_64"; then
+ { { echo "$as_me:$LINENO: error: --enable-darwin-64bit only supported on x86 host" >&5
+ echo "$as_me: error: --enable-darwin-64bit only supported on x86 host" >&2;}
+ { (exit 1); exit 1; }; }