diff options
| author | Misty De Meo | 2014-05-01 09:08:37 -0700 |
|---|---|---|
| committer | Misty De Meo | 2014-05-01 09:08:53 -0700 |
| commit | 23e1c24f6fe3946539907bf985aafc42f45fb10d (patch) | |
| tree | 646d1245eb8a898fbc2bd685203b13c4f1c7108b /Library/Formula | |
| parent | 24eae432aa258729b76e3fdbadfabc57387497e8 (diff) | |
| download | homebrew-23e1c24f6fe3946539907bf985aafc42f45fb10d.tar.bz2 | |
ansible: fix --HEAD install
Diffstat (limited to 'Library/Formula')
| -rw-r--r-- | Library/Formula/ansible.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Library/Formula/ansible.rb b/Library/Formula/ansible.rb index 2839bd35e..75203e18c 100644 --- a/Library/Formula/ansible.rb +++ b/Library/Formula/ansible.rb @@ -46,6 +46,9 @@ class Ansible < Formula def install ENV.prepend_create_path 'PYTHONPATH', libexec+'lib/python2.7/site-packages' + # HEAD additionally requires this to be present in PYTHONPATH, or else + # ansible's own setup.py will fail. + ENV.prepend_create_path 'PYTHONPATH', prefix+'lib/python2.7/site-packages' install_args = [ "setup.py", "install", "--prefix=#{libexec}" ] # pycrypto's C bindings use flags unrecognized by clang, @@ -70,6 +73,13 @@ class Ansible < Formula system "python", "setup.py", "install", "--prefix=#{prefix}" + # HEAD version installs some conflicting extra cruft + if build.head? + rm Dir["#{bin}/easy_install*"] + rm "#{lib}/python2.7/site-packages/site.py" + rm Dir["#{lib}/python2.7/site-packages/*.pth"] + end + man1.install Dir['docs/man/man1/*.1'] bin.env_script_all_files(libexec+'bin', :PYTHONPATH => ENV['PYTHONPATH']) |
