Updates p4a deps parsing
Now deals with conditional statements introduced in: https://github.com/kivy/python-for-android/pull/1418
This commit is contained in:
parent
5af135fca4
commit
10a3915c67
1 changed files with 2 additions and 2 deletions
|
@ -521,13 +521,13 @@ class TargetAndroid(Target):
|
||||||
try:
|
try:
|
||||||
with open(join(self.pa_dir, "setup.py")) as fd:
|
with open(join(self.pa_dir, "setup.py")) as fd:
|
||||||
setup = fd.read()
|
setup = fd.read()
|
||||||
deps = re.findall("install_reqs = (\[[^\]]*\])", setup, re.DOTALL | re.MULTILINE)[1]
|
deps = re.findall("^install_reqs = (\[[^\]]*\])", setup, re.DOTALL | re.MULTILINE)[0]
|
||||||
deps = ast.literal_eval(deps)
|
deps = ast.literal_eval(deps)
|
||||||
except Exception:
|
except Exception:
|
||||||
deps = []
|
deps = []
|
||||||
pip_deps = []
|
pip_deps = []
|
||||||
for dep in deps:
|
for dep in deps:
|
||||||
pip_deps.append('"{}"'.format(dep))
|
pip_deps.append("'{}'".format(dep))
|
||||||
|
|
||||||
# in virtualenv or conda env
|
# in virtualenv or conda env
|
||||||
options = "--user"
|
options = "--user"
|
||||||
|
|
Loading…
Add table
Reference in a new issue