ccm: move to Python 3
This commit is contained in:
parent
be527e08c2
commit
44b2e7a7cf
1 changed files with 7 additions and 5 deletions
|
@ -3,6 +3,7 @@ class Ccm < Formula
|
|||
homepage "https://github.com/pcmanus/ccm"
|
||||
url "https://files.pythonhosted.org/packages/fc/ab/b51afd466cc4acf2192e230ddb6fd3adb56066f05c7be1852af7bd655068/ccm-3.1.4.tar.gz"
|
||||
sha256 "a98268c2d8e5534d8d2d94267060e9ee9105b35e43d704bac0fa495a773acf7d"
|
||||
revision 1
|
||||
head "https://github.com/pcmanus/ccm.git"
|
||||
|
||||
bottle do
|
||||
|
@ -13,7 +14,7 @@ class Ccm < Formula
|
|||
sha256 "8a240c8e92a87f5397614f79268c2802f2ddd22413f29213df1ac831a9a936b7" => :sierra
|
||||
end
|
||||
|
||||
depends_on "python@2"
|
||||
depends_on "python"
|
||||
|
||||
resource "PyYAML" do
|
||||
url "https://files.pythonhosted.org/packages/4a/85/db5a2df477072b2902b0eb892feb37d88ac635d36245a72a6a69b23b383a/PyYAML-3.12.tar.gz"
|
||||
|
@ -31,15 +32,16 @@ class Ccm < Formula
|
|||
end
|
||||
|
||||
def install
|
||||
ENV.prepend_create_path "PYTHONPATH", libexec/"vendor/lib/python2.7/site-packages"
|
||||
xy = Language::Python.major_minor_version "python3"
|
||||
ENV.prepend_create_path "PYTHONPATH", libexec/"vendor/lib/python#{xy}/site-packages"
|
||||
%w[PyYAML six cassandra-driver].each do |r|
|
||||
resource(r).stage do
|
||||
system "python", *Language::Python.setup_install_args(libexec/"vendor")
|
||||
system "python3", *Language::Python.setup_install_args(libexec/"vendor")
|
||||
end
|
||||
end
|
||||
|
||||
ENV.prepend_create_path "PYTHONPATH", libexec/"lib/python2.7/site-packages"
|
||||
system "python", *Language::Python.setup_install_args(libexec)
|
||||
ENV.prepend_create_path "PYTHONPATH", libexec/"lib/python#{xy}/site-packages"
|
||||
system "python3", *Language::Python.setup_install_args(libexec)
|
||||
|
||||
bin.install Dir[libexec/"bin/*"]
|
||||
bin.env_script_all_files(libexec/"bin", :PYTHONPATH => ENV["PYTHONPATH"])
|
||||
|
|
Loading…
Reference in a new issue