blob: 58ca58670f8fdea3fe5fc05b1310ae19d5164052 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
require 'requirement'
class PythonDependency < Requirement
fatal true
satisfy :build_env => false do
which 'python'
end
def modify_build_environment
ENV['PYTHONPATH'] = "#{HOMEBREW_PREFIX}/lib/python2.7/site-packages"
end
# Deprecated
def to_s
'python'
end
end
class Python3Dependency < PythonDependency
default_formula 'python3'
satisfy :build_env => false do
which 'python3'
end
end
|