duplicity 0.6.12

Also use a self-contained install method that doesn't require
editing PYTHONPATH.
This commit is contained in:
Adam Vandenberg 2011-03-10 22:13:01 -08:00
parent 90590e5f12
commit 6d2282a02c

View file

@ -1,24 +1,26 @@
require 'formula'
class Duplicity <Formula
url 'http://code.launchpad.net/duplicity/0.6-series/0.6.11/+download/duplicity-0.6.11.tar.gz'
class Duplicity < Formula
url 'http://code.launchpad.net/duplicity/0.6-series/0.6.12/+download/duplicity-0.6.12.tar.gz'
homepage 'http://www.nongnu.org/duplicity/'
md5 '1116be7aababa467336eac2092f66ab7'
md5 '9b84c984054550bbb2ba29b553567b7b'
depends_on 'librsync'
depends_on 'gnupg'
def install
ENV.universal_binary
system "python", "setup.py", "install", "--prefix=#{prefix}"
end
# Install mostly into libexec
system "python", "setup.py", "install",
"--prefix=#{prefix}",
"--install-purelib=#{libexec}",
"--install-platlib=#{libexec}"
def caveats
<<-EOS.undent
If you are using a non-Homebrew-built Python, you may need to add:
#{HOMEBREW_PREFIX}/lib/pythonX.Y/site-packages
to your PYTHONPATH, where "X.Y" was the version of Python this
formula was built against.
EOS
# Shift files around to avoid needing a PYTHONPATH
system "mv #{bin}/duplicity #{bin}/duplicity.py"
system "mv #{bin}/* #{libexec}"
# Symlink the executables
ln_s "#{libexec}/duplicity.py", "#{bin}/duplicity"
ln_s "#{libexec}/rdiffdir", "#{bin}/rdiffdir"
end
end