aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/subversion.rb
diff options
context:
space:
mode:
authorAdam Vandenberg2010-10-31 18:09:13 -0700
committerAdam Vandenberg2010-10-31 18:09:28 -0700
commit3e90ab43f0f92ac604283d334619c8d9abbde345 (patch)
tree28d11b8d763c20e0bfc8b8b5b0a3de0fb96047af /Library/Formula/subversion.rb
parent00144d14b37d0d253264f3a7b659ba47b610403a (diff)
downloadhomebrew-3e90ab43f0f92ac604283d334619c8d9abbde345.tar.bz2
Subversion - patch Java detection
Patch taken from MacPorts. Fixes #2976
Diffstat (limited to 'Library/Formula/subversion.rb')
-rw-r--r--Library/Formula/subversion.rb28
1 files changed, 20 insertions, 8 deletions
diff --git a/Library/Formula/subversion.rb b/Library/Formula/subversion.rb
index 9a0427228..9bacf17a4 100644
--- a/Library/Formula/subversion.rb
+++ b/Library/Formula/subversion.rb
@@ -20,6 +20,7 @@ class Subversion <Formula
homepage 'http://subversion.apache.org/'
depends_on 'pkg-config' => :build
+
# On Snow Leopard, build a new neon. For Leopard, the deps above include this.
depends_on 'neon' if MACOS_VERSION >= 10.6
@@ -34,6 +35,20 @@ class Subversion <Formula
]
end
+ def patches
+ # Patch to find Java headers
+ p = { :p0 =>
+ "http://trac.macports.org/export/73004/trunk/dports/devel/subversion-javahlbindings/files/patch-configure.diff"
+ }
+
+ # Patch for subversion handling of OS X Unicode paths (see caveats)
+ if with_unicode_path?
+ p[:p1] = "http://gist.github.com/raw/434424/subversion-unicode-path.patch"
+ end
+
+ return p
+ end
+
def setup_leopard
# Slot dependencies into place
d=Pathname.getwd
@@ -84,6 +99,9 @@ class Subversion <Formula
args << "--with-ruby-sitedir=#{lib}/ruby" if build_ruby?
args << "--with-unicode-path" if with_unicode_path?
+ # Undo a bit of the MacPorts patch
+ inreplace "configure", "@@DESTROOT@@/", ""
+
system "./configure", *args
system "make"
system "make install"
@@ -112,7 +130,8 @@ class Subversion <Formula
end
inreplace "Makefile" do |s|
- s.change_make_var! "SWIG_PL_INCLUDES", "$(SWIG_INCLUDES) #{arches} -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -I/usr/local/include -I/System/Library/Perl/#{perl_version}/darwin-thread-multi-2level/CORE"
+ s.change_make_var! "SWIG_PL_INCLUDES",
+ "$(SWIG_INCLUDES) #{arches} -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -I/usr/local/include -I/System/Library/Perl/#{perl_version}/darwin-thread-multi-2level/CORE"
end
system "make swig-pl"
system "make install-swig-pl"
@@ -131,13 +150,6 @@ class Subversion <Formula
end
end
- def patches
- if with_unicode_path?
- # Patch that modify subversion paths handling to manage unicode paths issues
- "http://gist.github.com/raw/434424/subversion-unicode-path.patch"
- end
- end
-
def caveats
s = ""